Monday 17 June 2019

power - Measuring total energy used by a project


Is there a cheap/simple way I can empirically measure the total energy used by my project over a sample time of several minutes?


It's a microcontroller based system which repeatedly wakes up, does some work then sleeps. Typically it will be awake for < 10ms. Looking at the voltage drop across a 1Ω shunt resistor with an oscilloscope, I've measured the energy consumption of each work period by calculating the area under the curve. Using an ammeter I've found the quiescent current during sleep.


In theory, knowing the sleep period I could calculate an energy estimate. But, I'd like to test the system as a black-box without making assumptions about the firmware.


Is there a device or method for accurately measuring the total energy usage of a device over a long period? (preferably something cheap).



Answer




Charge up a cap to a known voltage. Then power this circuit from the cap for whatever time period. When done, measure the voltage left in the cap. Change the size of the cap to whatever is appropriate for the power draw and length of the test. Here's the formula:


\$Amps = Farads * \frac{(V_{start} - V_{End})}{Seconds} \$


The result, amps, will be the average amps for the duration of the test. Remember that the cap is measured in Farads, so don't use microfarads instead.


The cap voltage drop during the test should be fairly small, maybe 0.1 or 0.2 volts. Any larger and you get other weird effects influencing your measurements.


And another note: Most caps have terrible tolerances on their capacity. Calibrate first using a 1% or 0.1% resistor load instead of your micro-controller circuit. Try to have your V_Start and V_End approximately close to what you'd have for the real test to maximize accuracy. Oh, if you can avoid it, don't leave your multimeter attached for the duration of the test, only for measuring the start and end voltages.


That's the best thing I could think of for measuring very low power stuff over seconds or minutes. If properly calibrated it should also be quite accurate.


No comments:

Post a Comment

arduino - Can I use TI&#39;s cc2541 BLE as micro controller to perform operations/ processing instead of ATmega328P AU to save cost?

I am using arduino pro mini (which contains Atmega328p AU ) along with cc2541(HM-10) to process and transfer data over BLE to smartphone. I...