Carl is sporting an INA219 current sensor - results

My doctor tells me I should just run and forget the heart monitor, but I feel compelled to measure everything I do. Likewise I want to measure everything about Carl - how fast he can go, how long can he make a battery charge last, how many charge cycles before I need to change his batteries.

Most of these collected measurements are not used by him or by me, but they answer questions that come into my head when I think about Carl.

For example, when I purchase a new set of NiMH batteries I first put them into a BC-3000 charger in “Refresh” mode, which repeatedly charges and discharges them till a max capacity at 500mA discharge rate is determined. The batteries promise 2000mAh and so far all sets of the Eneloop batteries have delivered on the promise.

Today, sporting his new INA219 I2C current sensor and a logging program I threw together, Carl measured his “playtime”. Playtime for Carl begins when he detects his smart charger has begun to trickle the batteries, and he leaves the charging dock. Playtime ends when Carl detects the eight AA NiMH cell battery repeatedly registers 8.1v. That voltage was chosen to leave about 5% capacity in the cells which is 15-20 minutes of thinking and provides reserve power in case Carl’s first attempt at docking is unsuccessful, he can try a second time.

So, drum roll …

Playtime #3069  1905mAh  19.19Wh  7.8 hours 

which means Carl’s Pi3B, GoPiGo3 red board (with Blue status LED and green power LED), speaker, distance sensor, and USB sound adapter, (and INA219 current sensor) were drawing an

average of 244mA  at 10v  - 2.46W 

1905 mAh at 244mA rate is a little higher than I expected, but not unreasonable given that the battery set has not shown any diminished capacity yet even though they have powered 238 discharge/recharge cycles since being installed into Carl.

This is interesting and fun, but actually useless info for Carl and for me - worth the $5 invested.


Testing a second and third playtime against a trustworthy digital voltage-current-power meter resulted in:

  • mAh measurements matching within 1%
  • Wh measurements matching within 0.01%

Considering that my logging is using the INA219 's internal 128-samples-over-68ms result for integration at 1 second intervals, this level of agreement is also better than I expected.

Proving Carl can be accurately aware of how much effort he is using, if he ever finds himself needing such precision in his digital existence.


$5 for several hours of fun is a way better ROI than going to the movie theater. And you still have the INA219 if you think of other things to try.



Just like Charlie; if he ever needs to run a half-dozen operating systems, in both bitnesses, with 1T of data space. . . .


“. . . better than I expected”?  Are you kidding?!

IMHO, that is jaw-droppingly excellent - and for only five smackers - you struck gold!


I was expecting it would measure current and voltage and I would have to integrate those to get mAh an Wh, so just the fact it reports those with the multi-sample average option is really “struck gold” in itself. Add to that, that the measurements are less than my expected 5%, the results really are totally beyond my expectations.