I like tinkering with Arduino and similar prototyping platforms for IOT applications. Often I want to read a sensor value and send it to some cloud service and repeat this, say, once every hour.
Today I realised that my old Android phone that currently lies unused in my underwear drawer has huge potential for being a powerful sensor platform.
Let's say I only want to run a single app on the phone that does the following:
1. Read sensor value (accelerometer/temperature/light/...) 2. Send value via http 3. Sleep for one hour 4. Goto 1
Would it be possible to get one month of battery time on an Android phone running this program?
My first test would probably be to enable flight mode and uninstall as many apps as possible. Is there a better way? Maybe there is a custom ROM or similar that is specially made for this?