View Single Post
Old 12-20-2016, 07:45 PM   #18
trap000d
Member
trap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipsetrap000d can illuminate an eclipse
 
Posts: 23
Karma: 8028
Join Date: Sep 2016
Device: Kindle PW1
Hi Notimp,

I've added WiFi automatic on/off commands to the code. Available at master in repository https://github.com/trap000d/dropbox-...ive/master.zip

It has not tested yet (no Kindle on hand) so the code might work or not.
Also this hardcoded solution might break someone's preferences: what if somebody would like to keep their WiFi connection active all the time ?
I could add another key into config, e.g. "autowifi=1" will activate wireless

OR. (what looks even better) I can check if connection is active, remember the state, enable it if not active, and restore the original state at the end. Something like 'host dropbox.com' or 'ping -c 1 dropbox.com' should work, thought.

P.S. Unfortunately, for several next days I'll have no time for this (come back home only after Xmas)

Regards,
Quote:
Originally Posted by notimp View Post
Commands are:

Code:
disable WiFi: lipc-set-prop com.lab126.cmd wirelessEnable 0
enable WiFi: lipc-set-prop com.lab126.cmd wirelessEnable 1
src: https://wiki.mobileread.com/wiki/Kind..._like_the_menu

I'll see if I can get it hacked together.
trap000d is offline   Reply With Quote