Skip to main content

The Keypad library is designed to simplify keypad interfacing in Micropython-based hardware projects.

Project description

micropython-keypad

The Keypad library is designed to simplify keypad interfacing in Micropython-based hardware projects. Whether you’re working on a Raspberry Pi, ESP32, or any other Micropython-compatible board, this library provides an intuitive API for handling button presses and releases.

Example usage

from keypad import Keypad

keypad_rows = [9, 8, 7, 6]
keypad_columns = [5, 4, 3, 2]


def main():
    keypad = Keypad(keypad_rows, keypad_columns)
    print("Please enter a key from the keypad")
    key = None
    while key != "*":
        if key := keypad.scankeys:
            print(f"You have pressed: {key}")


if __name__ == "__main__":
    main()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

micro_keypad-0.0.1.tar.gz (2.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

micro_keypad-0.0.1-py3-none-any.whl (3.4 kB view details)

Uploaded Python 3

File details

Details for the file micro_keypad-0.0.1.tar.gz.

File metadata

  • Download URL: micro_keypad-0.0.1.tar.gz
  • Upload date:
  • Size: 2.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.0

File hashes

Hashes for micro_keypad-0.0.1.tar.gz
Algorithm Hash digest
SHA256 ede85b9f038b360675d56a305516c5da8899aa9100e3f835d2ae9d7e389d6f35
MD5 5dfe2cd5f7c758ba9ba893d11b43505a
BLAKE2b-256 1874d4ac07a9c36a30fabf34cdcdd7ebfaeaf6066039d484d6fdf7009c457558

See more details on using hashes here.

File details

Details for the file micro_keypad-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: micro_keypad-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 3.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.0

File hashes

Hashes for micro_keypad-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 1969b2c949e33447fc6d75889e36f86c033de9ff9d34dfe4b7db792b4d7cbc97
MD5 f4388e171cac69cb389cb3539d36f1b1
BLAKE2b-256 72bdea240727482f695bcde56e58e71a759426573880caeb320c8e95bf5b7cd6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page