mirror of
https://github.com/gunu3371/m1s_ups_control.git
synced 2024-09-25 05:35:40 +00:00
Update service.py
This commit is contained in:
parent
7855f04eed
commit
7a5a74fe33
@ -119,9 +119,9 @@ while not killer.kill_now:
|
|||||||
log.warn('AC power loss')
|
log.warn('AC power loss')
|
||||||
pw = int(ups.get_curvol())
|
pw = int(ups.get_curvol())
|
||||||
if pw <= 3500:
|
if pw <= 3500:
|
||||||
|
log.crit('battery is too low Shut down system')
|
||||||
ups.shutdown()
|
ups.shutdown()
|
||||||
os.system("shutdown now")
|
os.system("shutdown now")
|
||||||
log.crit('battery is too low Shut down system')
|
|
||||||
elif pw <= 3650:
|
elif pw <= 3650:
|
||||||
log.crit('battery is too low')
|
log.crit('battery is too low')
|
||||||
elif pw <= 3800:
|
elif pw <= 3800:
|
||||||
|
Loading…
Reference in New Issue
Block a user