pacman: Fix bipolar single measurements
Currently single shot measurements assume that the values read from the
pac sensors are unsigned integers. However, in bipolar modes these
values are signed integers which results in incorrect values reported.
This commit updates the functions used to measure voltage, power, and
current in single shot to work with signed integers in bipolar mode.
BUG=b:244319844
TEST=Ran on skyrim device, verified that bipolar single shot
measurements report correct values
Change-Id: I301b57a69a76b57fa4cbb76e7f0298a20729a2bc
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/dev-util/+/3896160
Commit-Queue: Parker Holloway <jparkerh@google.com>
Auto-Submit: Robert Zieba <robertzieba@google.com>
Tested-by: Robert Zieba <robertzieba@google.com>
Reviewed-by: Parker Holloway <jparkerh@google.com>
1 file changed