Coder Social home page Coder Social logo

wifiautoff's Introduction

User notes

Accidentally enabled WIFI eats battery. It also facilitates tracking. This app helps to reduce this by turning off WIFI.

By default the app only listen to WIFI changes. You need to enable the app (checkbox) to activate the turn off WIFI feature. If want to connect to a new (not whitelisted) network, you need to disable the app, scan or connect to whitelist the SSID/BSSID, then enable the app again. (Otherwise it would just instantly turn off the WIFI.)

The app only cares whether the SSID/BSSID is among the WIFI scan results, so connection errors does not turn off the WIFI.

The whitelist, currently connected networks, available networks are color coded (red, green, and gray respectively).

A notification is shown if the app is enabled.

Architecture overview

It subscribes to android.net.wifi.SCAN_RESULTS, etc receivers, and checks the WIFI connection and WIFI scan result. It never uses another data source (i.e., cell or GPS), and never starts scanning. The only setting change is when it turns the WIFI off.

The build process and repo structure is opinionated: I want to keep the source files and resulting apk minimal. See Makefile

Permissions used

  • CHANGE_WIFI_STATE and ACCESS_WIFI_STATE should be obvious
  • ACCESS_FINE_LOCATION WIFI scan result usually pinpoints your location, see in the api as well
  • WAKE_LOCK not sure if needed, but should not hurt; the service holds it

License

Code is under MIT license. Icon is adapted from this

wifiautoff's People

Contributors

csmarosi avatar

Stargazers

lucky avatar -.- avatar  avatar  avatar  avatar

Watchers

James Cloos avatar  avatar  avatar OpenApk avatar

Forkers

atrate

wifiautoff's Issues

Pre-release

Please provide an apk for testing the app.

Low priority notification

It would be nice to have an option to have lower priority notification so that it can be grouped with other low priority notifications ๐Ÿ˜€

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.