carrotIndustries / energytrace-util

Utility for reading EnergyTrace data from TI debug hardware
GNU General Public License v3.0
37 stars 9 forks source link

Measurement update frequency with very low power systems #6

Open osresearch opened 2 months ago

osresearch commented 2 months ago

load

While trying to optimize the power draw on very low power devices, energytrace seems to end up producing far less frequent measurements. With the msp430 removed from the loop and just testing 1k, 2.2k, 5.6k, 10k and 47k load resisters, you can see how the frequency of new measurements drops significantly. By the time the power draw is 50uA or less, it seems that the measurements change at around 2-4 Hz, no matter what the setting is for the update frequency.

Is this a fundamental issue with the way the charge pump measurements work? That is what is suggested in this ti forum post:

EnergyTrace just measures the energy pumped into the target board. However, the measurement is quantized by the amount of energy pumped on each regulator cycle. If the regulator runs with 1MHz maximum switching frequency (usually less), and you sample with 1kHz, you have a resolution of 0.1% only. With 100mA full output, you cannot have les than 100µA or else the output will pump between 0 and 100µA,as you have less than one switching pulse per measurement cycle. Increasing the sampling frequency makes the result worse. But if you increase the sampling time to 10ms (100Hz sampling frequency), you can visualize an average current as low as 10µA.

For the graph above, I've modified energytrace to use a 100 Hz update and still see the very low temporal resolution.

osresearch commented 2 months ago

graph

Looking at the energytrace graphs on Travis' goodwatch wiki, it seems that he was also measuring only a few Hz of updates when the watch was drawing a small number of microamp.

osresearch commented 2 months ago

watch-load

Here is my watch measured by energytrace with a 5.6k load in parallel (which adds about a 600uA offset) and just the watch by itself. The length of the 1 Hz wakeups is clearly visible in the loaded line, while the unloaded current measurements are so low frequency that they almost blend together.

carrotIndustries commented 2 months ago

Maybe add this to the README in a PR?