Skip to content

Commit

Permalink
rounded voltage values to 3 dec points.
Browse files Browse the repository at this point in the history
  • Loading branch information
tjohn327 committed Jun 9, 2020
1 parent b3c8b0b commit fe2d933
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/powerpi.py
Original file line number Diff line number Diff line change
Expand Up @@ -160,9 +160,9 @@ def read_status(self, clear_fault=False):

data = {
'PowerInputStatus': power_status,
'InputVoltage' : vbus,
'InputVoltage' : round(vbus,3),
'ChargeStatus' : charge_status,
'BatteryVoltage' : vbat,
'BatteryVoltage' : round(vbat,3),
"BatteryPercentage" : int(self._calc_bat_charge_percent(vbat)*100),
'ChargeCurrent' : ibat,
'TimeRemaining' : int(time_left)
Expand Down

0 comments on commit fe2d933

Please sign in to comment.