[APP][2.2+] Smart WiFi Toggler

Search This thread

sebouh00

Senior Member
Apr 26, 2011
156
170
Beirut
25qey2u.png


Description:
Smart WiFi Toggler is an application designed to control your phone's WiFi using location based rules. Its aim is to conserve battery and minimize data charges by turning WiFi off when not connected to a network, and turning it on when a known hotspot is present. It constantly learns where your hotspots are located to make its decisions.
It's a very useful application if you frequently forget to turn WiFi off when leaving a hotspot, or if you want to automatically switch from mobile data to WiFi to conserve battery whenever you're back into a hotspot.

Hope you enjoy using Smart WiFi Toggler as much as I enjoyed building it!

*** I am happy to add support for more languages. If you are willing to help with the translation, please drop me an email. Thanks. ***


Features:
- Automatically learns your WiFi hotspot locations.
- Turns WiFi off when disconnected from WiFi network.
- Automatically turns WiFi on when near a known hotspot.
- Uses your network location. No GPS battery drain.
- Provides the ability to control "auto-connect" behavior for each hotspot.
- Ability to lock WiFi to a disabled state.
- Warning notification and auto-locking WiFi when a hotspot is down.
- History and logging, in addition to a view of what is going on under the hood.

Market Link (Still on 2.2.10): Click here

Bug report & Questions:
Any questions you have or bugs you would like to report, you may post it here or contact me on the app's developer email. I will try to get back to you as soon as I can.

Changelog
v2.3
- Brand new UI.
- Performance tweaks.
- Bug fixes.
- Added Spanish, Hungarian, Hebrew, Japanese, and Turkish languages. Thanks to Carlos Filoteo, Laszlo Horvath, Yev Gavrikov, Kayoko Sawada, and Fikret Sadak!

v2.2.10
- Added a new statistics screen.
- Better toggler accuracy for devices with a barometer.
- Added Danish, Traditional and Simplified Chinese language support. (Thanks to nodjack (xda), Bryan Yang and Eclipse!)
- Ability to change the app's language from the settings.
- Replaced Tips with an online FAQ.
- Google Analytics to help improve the app.
- Bug fixes.
 

Attachments

  • SmartWifiToggler2.3.apk
    1.4 MB · Views: 2,549
Last edited:

mikpel

Senior Member
May 29, 2012
105
47
androidwallz.blogspot.com
Great idea!

If I understood correctly from the screenshots, the app will shut down wifi when the connection is lost. How does it know when the device is back to hotspot area? By using gps locations?
 

sebouh00

Senior Member
Apr 26, 2011
156
170
Beirut
Great idea!

If I understood correctly from the screenshots, the app will shut down wifi when the connection is lost. How does it know when the device is back to hotspot area? By using gps locations?

GPS is not used. It uses your network location. It's not 100% accurate, but the aim was to use as little battery as possible. GPS would not have fit that criteria.
 

sevag00

Senior Member
Apr 23, 2010
155
8
Beirut
Cool app bro. You finally released it to the public. I will definitely check it out. You guys should probably try it. There is very hard work in it. Keep up the good work.
 

sebouh00

Senior Member
Apr 26, 2011
156
170
Beirut
Finally got it working. It was my fault. :p

Now it's crashing on me when I select the start button. On an evo 3d running cm9.

Well that's no good. Please send me your logcat trace. I'll try to find out why that's happening.

Edit: I just saw the crash report. Do you have a CDMA phone? If so, it won't work. Currently, it only works on GSM. I should have mentioned that, sorry.
 
Last edited:

lexluthor

Senior Member
Feb 7, 2007
1,927
204
Any reason that I'd want to replace Y5 with this? Does this do anything different or better?
 

sebouh00

Senior Member
Apr 26, 2011
156
170
Beirut
Any reason that I'd want to replace Y5 with this? Does this do anything different or better?

I don't know really. I've never tried Y5.

After checking it out, it looks outdated (kidding...). Smart WiFi Toggler has more options i guess. Timer control, per-wifi settings, etc.

Try it, see if you like it. If not, I'm happy you tried anyway. :)
 

lexluthor

Senior Member
Feb 7, 2007
1,927
204
Yes, Y5 is very outdated at this point and is probably abandonware, but it does still work.

Always looking to replace abandoned apps with apps still supported though, so I'll give this a try.

I have an issue/bug? and a couple of questions so I can understand how it works.

First, in the initial startup settings pages, I chose to not run service in foreground, but if I did, I couldn't uncheck show notification icon. After initial setup, when I go into settings, run service in foreground was checked. But, over in those settings, I can disable the show notification icon. Seems like run service in foreground and no notification icon is my preferred solution, so I'll use that. Hopefully, that will keep the program from getting killed.

So, is this using cell tower information to determine that I'm near a known wifi hotspot?

What happens if I walk out of my house and lose the wifi connection for a couple of minutes and then I come back in and want to connect back to wifi. It seems like it will turn wifi off after 30 seconds because I was disconnected from my wifi hotstop. Will it turn wifi back on by itself again?

EDIT: Tested it and wifi does not come back on. So, then what logic makes it ever come back in? Do I have to go far enough away that smart wifi toggler thinks I'm out of range of my wifi and then come back in range?

Hopefully, there's a way to make that work better or that's probably a deal breaker for me.

The thing I don't like about Y5, which I think this fixes is if I turn off wifi while Y5 is running, it turns it right back on immediately. The only way to actually make wifi stay off if I'm in a known wifi hotspot is to disable Y5.

It'd be nice if there was a way that if I manually turn off wifi, it stays off, but if wifi just gets disconnected, it comes back on automatically.

What happens if I set wifi disconnection to 0? Will wifi still go off when I'm out of range (based on your cell tower information) of a known wifi hotspot?
 
Last edited:

sebouh00

Senior Member
Apr 26, 2011
156
170
Beirut
Hi lexluthor. Thanks for trying out the app. Let me see if my answers can be useful:

First, in the initial startup settings pages, I chose to not run service in foreground, but if I did, I couldn't uncheck show notification icon. After initial setup, when I go into settings, run service in foreground was checked. But, over in those settings, I can disable the show notification icon. Seems like run service in foreground and no notification icon is my preferred solution, so I'll use that. Hopefully, that will keep the program from getting killed.
As far as I know, android does not permit running in foreground mode without showing a notification. If I'm wrong here, I'd appreciate an example where this is not the case. If you choose to not run in foreground mode to avoid the icon, android will keep killing and restarting the service because of inactivity.
Do I understand correctly that you could disable the icon in foreground mode? If so, please make sure that whenever you check foreground mode, you have to restart the service so it can take effect. (It should show you a "service restart required" toast message).


So, is this using cell tower information to determine that I'm near a known wifi hotspot?

What happens if I walk out of my house and lose the wifi connection for a couple of minutes and then I come back in and want to connect back to wifi. It seems like it will turn wifi off after 30 seconds because I was disconnected from my wifi hotstop. Will it turn wifi back on by itself again?
You are correct. It is using your cell location info. Just like you've observed, when wifi gets disconnected, the timer will start counting. On timeout, it will turn wifi off. Logically, there is no way the app can know if you are inside or outside. What it does do however, is the next time you wake the phone up from sleep (screen off then back on) it will enable wifi and wait for a connection. (I'm assuming here that you are connected to the same cell inside and outside of your house).

The only difference I can think of inside and outside your house is the signal strength. This is something I plan to experiment with to see how useful in can be to get even more accuracy.

The thing I don't like about Y5, which I think this fixes is if I turn off wifi while Y5 is running, it turns it right back on immediately. The only way to actually make wifi stay off if I'm in a known wifi hotspot is to disable Y5.

It'd be nice if there was a way that if I manually turn off wifi, it stays off, but if wifi just gets disconnected, it comes back on automatically.
This is something I was experimenting with, but it made things complicated. How would the app know when to turn it on again automatically at a later time? Would you have to leave that location then come back? I guess this is something worth trying in future releases.

What happens if I set wifi disconnection to 0? Will wifi still go off when I'm out of range (based on your cell tower information) of a known wifi hotspot?
Setting the disconnection timer to zero will disable auto-wifi-off. This means WiFi will be kept on.
 

lexluthor

Senior Member
Feb 7, 2007
1,927
204
Hi lexluthor. Thanks for trying out the app. Let me see if my answers can be useful:


As far as I know, android does not permit running in foreground mode without showing a notification. If I'm wrong here, I'd appreciate an example where this is not the case. If you choose to not run in foreground mode to avoid the icon, android will keep killing and restarting the service because of inactivity.
Do I understand correctly that you could disable the icon in foreground mode? If so, please make sure that whenever you check foreground mode, you have to restart the service so it can take effect. (It should show you a "service restart required" toast message).


You are correct. It is using your cell location info. Just like you've observed, when wifi gets disconnected, the timer will start counting. On timeout, it will turn wifi off. Logically, there is no way the app can know if you are inside or outside. What it does do however, is the next time you wake the phone up from sleep (screen off then back on) it will enable wifi and wait for a connection. (I'm assuming here that you are connected to the same cell inside and outside of your house).
.
I'll double check the service a little later. Right now, foreground mode is on, but I have no icon. I'll reboot and see if it remains that way. I'm probably wrong, but I thought you could have a foreground service in ICS with no icon.

Anyhow, no, wifi didn't come back on for me even after I turned the screen off/on. Your assumption that I'm connected to the same cell is probably wrong. In areas with a lot of cell towers, couldn't my phone connect to many different towers, even within my own house? Y5 says it has something like 30 towers remembered for me. Also, I know if I reset my Y5 data, even after a few days, there are times when I'm connected to wifi and connected to a cell tower that Y5 hasn't learned yet.

If your logic is that a wifi hotspot is associated with the cell tower that I'm connected to when I first connect to the wifi hotspot, that's going to be a problem if I can connect to many different towers while at that wifi hotstop.

Appreciate your responses so far. I'm just trying to help improve your program, not being critical in any way.
 

sebouh00

Senior Member
Apr 26, 2011
156
170
Beirut
I'll double check the service a little later. Right now, foreground mode is on, but I have no icon. I'll reboot and see if it remains that way. I'm probably wrong, but I thought you could have a foreground service in ICS with no icon.

Anyhow, no, wifi didn't come back on for me even after I turned the screen off/on. Your assumption that I'm connected to the same cell is probably wrong. In areas with a lot of cell towers, couldn't my phone connect to many different towers, even within my own house? Y5 says it has something like 30 towers remembered for me. Also, I know if I reset my Y5 data, even after a few days, there are times when I'm connected to wifi and connected to a cell tower that Y5 hasn't learned yet.

If your logic is that a wifi hotspot is associated with the cell tower that I'm connected to when I first connect to the wifi hotspot, that's going to be a problem if I can connect to many different towers while at that wifi hotstop.

Appreciate your responses so far. I'm just trying to help improve your program, not being critical in any way.
If it didn't come back on, then you must have camped onto another cell. As I mention in the help section, if you're house is located in an area that keeps your phone hopping between cells, then Smart WiFi Toggler has to save all of them. It does in fact do that on every cell update whilst you're connected to a WiFi. This is the "learning curve" I mention in there. Once it has associated these cells with the hotspot, then you're good to go.

The thing I noticed about Y5 when I tried it today is that while I was standing in one location (inside an office -- with an inbuilding antenna system), it saved more than one cell for the hotspot. I felt this was excessive as it will make the auto-wifi-on window larger. Smart WiFi Toggler only saves the cell you are connected to. Not the neighbors. This has an initial disadvantage, but after that it's more efficient.

Anyway, I understand your concerns and your questions are all valid. I'm happy to answer all of them. In the end, you just have to try it and see if it works for you or not. I didn't have much audience to test the app with, but I'm fairly confident that 5 months of first hand testing and refining should make it a decent app. :)
 

lexluthor

Senior Member
Feb 7, 2007
1,927
204
Great. Your responses are helping me understand the app better note and i should be able to help test better.

Will give it a learning curve and keep an eye on it and will post later.
 

lexluthor

Senior Member
Feb 7, 2007
1,927
204
Ok. Looks like run in foreground and notification icon are now linked together. I turned run in foreground off as I don't like notification icons. I run that way with tasker and my phone has never closed out that service.

I'm still not seeing wifi ever come back on on it's own. I've turned wifi on and off a a few times in the hopes of it trying to remember more cells.

I see may cell location update received notices in the logs. When I toggle wifi on and off, I seem to always get cell already exists for this wifi entry in the log.

So, after I toggle wifi off and get that entry in the log, I put the phone to sleep, wait a few minutes, turn it back on and wifi still doesn't ever turn on.

Any idea what's going on?

I have a Verizon CDMA Samsung Galaxy S III running stock/rooted.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 114
    25qey2u.png


    Description:
    Smart WiFi Toggler is an application designed to control your phone's WiFi using location based rules. Its aim is to conserve battery and minimize data charges by turning WiFi off when not connected to a network, and turning it on when a known hotspot is present. It constantly learns where your hotspots are located to make its decisions.
    It's a very useful application if you frequently forget to turn WiFi off when leaving a hotspot, or if you want to automatically switch from mobile data to WiFi to conserve battery whenever you're back into a hotspot.

    Hope you enjoy using Smart WiFi Toggler as much as I enjoyed building it!

    *** I am happy to add support for more languages. If you are willing to help with the translation, please drop me an email. Thanks. ***


    Features:
    - Automatically learns your WiFi hotspot locations.
    - Turns WiFi off when disconnected from WiFi network.
    - Automatically turns WiFi on when near a known hotspot.
    - Uses your network location. No GPS battery drain.
    - Provides the ability to control "auto-connect" behavior for each hotspot.
    - Ability to lock WiFi to a disabled state.
    - Warning notification and auto-locking WiFi when a hotspot is down.
    - History and logging, in addition to a view of what is going on under the hood.

    Market Link (Still on 2.2.10): Click here

    Bug report & Questions:
    Any questions you have or bugs you would like to report, you may post it here or contact me on the app's developer email. I will try to get back to you as soon as I can.

    Changelog
    v2.3
    - Brand new UI.
    - Performance tweaks.
    - Bug fixes.
    - Added Spanish, Hungarian, Hebrew, Japanese, and Turkish languages. Thanks to Carlos Filoteo, Laszlo Horvath, Yev Gavrikov, Kayoko Sawada, and Fikret Sadak!

    v2.2.10
    - Added a new statistics screen.
    - Better toggler accuracy for devices with a barometer.
    - Added Danish, Traditional and Simplified Chinese language support. (Thanks to nodjack (xda), Bryan Yang and Eclipse!)
    - Ability to change the app's language from the settings.
    - Replaced Tips with an online FAQ.
    - Google Analytics to help improve the app.
    - Bug fixes.
    5
    Great idea!

    If I understood correctly from the screenshots, the app will shut down wifi when the connection is lost. How does it know when the device is back to hotspot area? By using gps locations?

    GPS is not used. It uses your network location. It's not 100% accurate, but the aim was to use as little battery as possible. GPS would not have fit that criteria.
    3
    Please point out the differents?:confused:

    Difference is.. that is a Mega functions app...

    This one is totally dedicated app related to Wi-Fi... so if you have problem with this app.. then no one is forcing you to use this app...

    You can choose whatever app you want to use..
    Don't post other apps claiming they do way more than this app in an app development thread and discourage devs...

    Every person has their own preference for apps... for ex for me.. I would like to have app which just handles my wifi instead of the app you told which will take more resources and battery as it needs to monitor more aspects of phone..

    Let the op do his work... if you want use the app and be thankful... if not just G....

    I seriously can't understand why people do this...:mad:


    If I hurt your feelings.. sorry mate... its just not nice and very rude to mention other app in an app development thread claiming it does this... this app is still in development.. let the op do his magic... this app might become better than that app...

    **Nothing is True... Everything is Permitted**
    Muffins.. muffins everywhere!


    PS: op... sorry for my rant.. I just felt bad... if my post was wrong.. please report it and I'm sorry..
    3
    Well,WiFi toggling works OK. But I really used to loved mobile data toggling. Any chance we'll get this feature back on Lollipop even on rooted phones only?

    BTW what screenshot do you need? Happy to help you.
    Not sent by me.
    I think so. It may take some time though. I plan to update the interface and features but there's a lot to do and not enough time. :(

    In the app, there's an "advanced" menu option. It starts a new activity that details the network info and wifi status. That activity will tell you if the app thinks there's a hot spot nearby based on the network location values.
    3
    Tasker and automateit can do the same action

    Get out.

    Sent from my EVO using Tapatalk 2