Open GoogleCodeExporter opened 8 years ago
When the phone goes to sleep the wireless chip gets turned off. This is
obviously bad if pirni is running, since libnet_init puts the chip in monitor
mode (not working on the iphone, but it returns ok)
To avoid this, either turn off pirni when the phone is going to sleep, or use
Insomnia to prevent it from shutting down wifi. There is some code in the
trunk, for my gps daemon that wakes up a device from sleep. Also check out
http://code.google.com/p/iphone-insomnia/
Original comment by axelmoll...@gmail.com
on 10 Jul 2010 at 8:02
Thank you for the quick response.
I used http://blogs.oreilly.com/iphone/2008/08/iphone-notifications.html and
started catching network changes (re-compiled to launch a script on network
change) in order to turn pirni off when WiFi turned off, and back on when WiFi
turned back on.
Unfortunately this didn't fix the issue, since the WiFi is already off by the
time we turn off pirni. I couldn't figure out how to catch a notification that
WiFi was about to turn off (reliably at least), only that it was already off.
Also, preventing the phone from going to sleep/shutting off wifi is infeasible,
as the goal is long term data collection, and that would ruin battery life.
Is there a way to reset the WiFi (ie reverse libnet_init) once it is broken?
Thus I could just reset WiFi whenever it turns back on in order to resolve the
issue.
Thanks!
Original comment by cws...@gmail.com
on 26 Jul 2010 at 3:28
Original issue reported on code.google.com by
cws...@gmail.com
on 9 Jul 2010 at 6:31