Skip to content

Commit

Permalink
batterycheck.py: Charging indicator
Browse files Browse the repository at this point in the history
  • Loading branch information
thp committed Feb 26, 2020
1 parent e0ba807 commit 8bcc80d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions examples/python/batterycheck.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@
move.set_leds(128, 200, 0)
elif battery == 3: # 60% - yellow
move.set_leds(255, 255, 0)
elif battery > 5: # charging
move.set_leds(0, 0, 255)
else: # <= 40% - red
move.set_leds(255, 0, 0)
move.update_leds()
Expand Down

0 comments on commit 8bcc80d

Please sign in to comment.