1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-01 19:02:18 +01:00

[sx1509] add support for keys (#8413)

Co-authored-by: Samuel Sieb <samuel@sieb.net>
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
This commit is contained in:
Samuel Sieb
2025-05-26 22:16:27 -07:00
committed by GitHub
parent 95a17387a8
commit 361de22370
4 changed files with 100 additions and 24 deletions

View File

@@ -6,6 +6,12 @@ i2c:
sx1509:
- id: sx1509_hub
address: 0x3E
keypad:
key_rows: 2
key_columns: 2
keys: abcd
on_key:
- lambda: ESP_LOGD("test", "got key '%c'", x);
binary_sensor:
- platform: gpio
@@ -13,6 +19,11 @@ binary_sensor:
pin:
sx1509: sx1509_hub
number: 3
- platform: sx1509
sx1509_id: sx1509_hub
name: "keypadkey_0"
row: 0
col: 0
switch:
- platform: gpio