I found that my weather station only lasted for about 7 hours on 2xAA batteries last night. The culprit could be the boost regulator, but before I investigate that I’ve reworked my Arduino code and moved away from manually tinkering with the avr/power.h stuff to using JeeLib. Its greatly simplified my code too. I removed the code that was measuring the voltage as that always returned 3.37v from the boost, so a bit pointless, plus it kept the ADC awake draining power.
The reduction in packet size meant I could move the dewpoint calculation back to the Arduino side, so all my data was being transmitted to and stored on the Pi via the C++ rather than it being calculated in the Python code temporarily before being Tweeted.
I’ve also made the Arduino and radio sleep for 30mins to reduce power consumption, then it wakes and transmits for about 5secs and then goes back to sleep. Plus the Pi process sleeps for 10mins to reduce the number of disk writes it makes (and CPU time) without missing the transmissions. So hopefully I’ll achieve the months/years of battery life that I keep hearing about.
All the sourcecode including the Pi stuff is here.
Update: I take it back, the culprit is shitty NiMH batteries. I’ve been running for 22 hours on a pair of Alkalines and still have 2.79v coming out of them! So I’m discharging and fully recharging a pair of 2900mAh NiMH’s to see how they go. I’ve also ordered some brand new 1900mAh Sanyo Eneloop 3rd generation NiMH batteries that apparently store their charge very well.