I did another battery test using a modified version of Ted’s code which makes the pagers broadcast their battery readings, and turn off automatically at a reading of 1600. The modified versions of sampADcC.nc and sampADcP.nc can be found here:
http://docs.google.com/Doc?docid=0AWGN0bxAc29yZDdqZG5zd183aGI4bWgyZjk&hl=en
http://docs.google.com/Doc?docid=0AWGN0bxAc29yZDdqZG5zd182ZnZ2cXpnZzU&hl=en
The following table and graph summarize the data

The motes exhibited some strange behavior after the test. mote 244 ended at a reading of 1607, which should correspond to a voltage of about 2.5v. When I measured the battery voltage, however, it read 3.2v. I turned it on again after the test, and it broadcast a reading of around 1980, which sure enough corresponds to 3.2v. I’m certain it was not plugged in between the time the test ended and I read this voltage. In the last test, both motes exhibited the same behavior, but I let it slide since they had been plugged in for some time (1-2 minutes) before I checked their voltages.
Both of the other pagers in this test had a battery reading of 0v, suggesting the automatic shut down didn’t work for them, and they drained their batteries overnight. The test results seem to suggest they turned off at the right time, however, and I don’t know why the automatic shut down would work for one pager but not the others.













As the trendline indicates, the battery reading is about 600 times the battery voltage. The voltage that is acutally being measured is 10/26 of the battery voltage (not 1/2, as it used to be). The code should probably be modified so that the motes shut off when their batteries are around 2.7v, or a battery reading of about 1700.