Skip to content

Commit

Permalink
Expose debounce_threshold in keypad.py
Browse files Browse the repository at this point in the history
This is needed for proper debouncing
  • Loading branch information
regicidalplutophage authored Nov 7, 2024
1 parent 9ecce75 commit 4d684a5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions kmk/scanners/keypad.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,15 @@ def __init__(
columns_to_anodes=DiodeOrientation.COL2ROW,
interval=0.02,
max_events=64,
debounce_threshold=1,
):
self.keypad = keypad.KeyMatrix(
row_pins,
column_pins,
columns_to_anodes=(columns_to_anodes == DiodeOrientation.COL2ROW),
interval=interval,
max_events=max_events,
debounce_threshold=debounce_threshold,
)
super().__init__()

Expand Down

0 comments on commit 4d684a5

Please sign in to comment.