Skip to content

Commit

Permalink
fix fan speed in argon-status
Browse files Browse the repository at this point in the history
OptimusGREEN authored Dec 30, 2022
1 parent d78f5a7 commit f813db1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions argononed.py
Original file line number Diff line number Diff line change
@@ -194,7 +194,7 @@ def load_unitconfig(fname):

def getCurrentFanSpeed():
try:
return int(speed.read_text())
return int(float(speed.read_text()))
except FileNotFoundError:
return None

@@ -241,7 +241,7 @@ def writeSpeed(theSpeed):
# Spin up to prevent issues on older units
bus.write_byte(ADDR_FAN,100)
time.sleep(1)
bus.write_byte(ADDR_FAN,newspeed)
bus.write_byte(ADDR_FAN,int(newspeed))
except IOError:
return prevspeed
writeSpeed (newspeed)

0 comments on commit f813db1

Please sign in to comment.