Skip to content

Commit 0287117

Browse files
committed
turn off the backlight when setting the screen to blank
1 parent 3fff6ff commit 0287117

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

examples/monitor.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1135,9 +1135,10 @@ def handle_button(pin):
11351135
viewcontroller.update()
11361136

11371137
if light_level_low and config.get_general().get("black_screen_when_light_low"):
1138+
display.set_backlight(GPIO.LOW)
11381139
display.display(image_blank.convert("RGB"))
1139-
11401140
else:
1141+
display.set_backlight(GPIO.HIGH)
11411142
viewcontroller.render()
11421143
display.display(image.convert("RGB"))
11431144

0 commit comments

Comments
 (0)