Skip to content

Conversation

@dhalbert
Copy link
Collaborator

Tested on a CPB:

import keypad
import board
import time

keys = keypad.Keys((board.BUTTON_A,), value_when_pressed=True, pull=True)

while True:
    print("wait 5 seconds")
    time.sleep(5)
    print(f"{len(keys.events)=}")
    count = 0
    while (keys.events.get()):
        count+= 1
    print(f"{count=}")

Copy link

@Neradoc Neradoc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All good, thanks 👍

@dhalbert dhalbert merged commit c27e0da into adafruit:9.2.x Mar 26, 2025
519 checks passed
@dhalbert dhalbert deleted the keypad-length-fix branch March 26, 2025 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants