Skip to content

Commit

Permalink
fix current sign
Browse files Browse the repository at this point in the history
  • Loading branch information
msh committed Aug 17, 2016
1 parent 2bd182b commit 1a6b816
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion cob_phidget_power_state/scripts/power_state_phidget.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ def phidget_cb(self, msg):
if current_raw != None:
#Calculation of real current
self.current = self.current_min+(self.current_max - self.current_min)*(current_raw - self.PHIDGET_MIN_VALUE) / (self.PHIDGET_MAX_VALUE - self.PHIDGET_MIN_VALUE)
self.current = -self.current
self.current = round(self.current, 3)

if self.current > 0:
Expand Down

0 comments on commit 1a6b816

Please sign in to comment.