I'm using the nRF-PPK2 in ampere mode to measure power utilization in a battery powered device over a long period of time (about 16 hours). However, the PPK2 is giving unreliable measurements, as if it is not always sure exactly which measurement resolution it's using. Note, I am using the IRNAS python library for this extended duration (due to PPK2 lag mentioned in another ticket) but I saw similar behavior using the Power Profiler software, so it's either a firmware issue or the two fall prey to the same improper decoding bug.
Anyway, what I expect to see is utilization the starts at around 3.8mA (average) and slowly increases until the thing dies (I'm directly in the battery path, so the battery voltage is not constant). What I see instead is a couple of small discrete jumps (which may or may not be real), a really excessive jump to ~9.5A for an hour (which would probably make my device explode) then a sustained load from 15-18mA for four hours or so (unrealistic utilization given the hardware and battery capacity). Sometimes it's correctable (when it was reading >9A I stopped and started the PPK2 collection and it went back to normal) but other times it's not (resetting during the 15-18mA draw period did not change the return).
I provide two plots below of the observed behavior (Fig 1 includes the crazy 9.5A jump, Fig 2 includes the unrealistic average 15-18mA draw. Note, there's less than the 16 hours I mentioned because I overwrote some data when I restarted the PPK2 collection. Whoops...)
Now, the 15-18mA draw could be accurate, I'm not completely convinced that it was just a resolution issue since the jump didn't come with a factor of 10 increase over what I expected (moving from 5 to 50 µA resolution). That would be very concerning. However, it is completely unrealistic. The device only has a 90mAh battery, which would barely maybe be able to run through the 8 hours in the figures below, let alone the other 8 hours it was running! So something is very much off with the measurement.
How can I debug this? Is it possible my device is defective, or has an old / buggy firmware? Is it possible to output additional data points like the measured voltage and which measurement resolution is in use?
Figure 1: Average current. Drawing "9.5A" for almost 1 hour.
Figure 2: Average current, clipped to [0,20]mA. Likely incorrect > 3.5 hours.