Skip to content

Commit 4a23749

Browse files
committed
fix activity() to immediately un-dim screen
1 parent e1f96af commit 4a23749

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

adafruit_pybadger/pybadger_base.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,6 +430,10 @@ def auto_dim_display(self, delay: float = 5.0, movement_threshold: int = 10):
430430
self.display.brightness = self._display_brightness
431431

432432
def activity(self, current_time=None):
433+
"""Turn postpone dimming of the screen"""
434+
if not hasattr(self.display, "brightness"):
435+
return
436+
self.display.brightness = self._display_brightness
433437
self._start_time = current_time or time.monotonic()
434438

435439
@property

0 commit comments

Comments
 (0)