[core] Select I/O expander pin providers by I2C address (#18939)

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
Clyde Stubbs
2026-10-07 09:18:40 -10:00
committed by GitHub
co-authored by Claude Sonnet 5
parent 1c0d406cbb
commit 6dec759261
23 changed files with 476 additions and 19 deletions
@@ -0,0 +1,23 @@
packages:
i2c: !include ../../test_build_components/common/i2c/esp32-p4-idf.yaml
esp_ldo:
- id: ldo_id
channel: 3
voltage: 2.5V
psram:
pi4ioe5v6408:
# A second, decoy hub at a different address, so this test only passes if
# the model's reset_pin default actually resolves pi4ioe1 by its address
# (0x43) -- with only one hub declared, the single-instance auto-pick
# fallback would resolve it too, even if address matching regressed.
- id: pi4ioe1
address: 0x43
- id: pi4ioe2
address: 0x44
display:
- platform: mipi_dsi
model: M5STACK-TAB5
+12
View File
@@ -2,6 +2,9 @@ xl9535:
- id: xl9535_hub
i2c_id: i2c_bus
address: 0x20
- id: xl9535_hub_2
i2c_id: i2c_bus
address: 0x21
binary_sensor:
- platform: gpio
@@ -20,3 +23,12 @@ binary_sensor:
mode:
input: true
inverted: false
- platform: gpio
name: XL9535 Pin 1 By Address
pin:
xl9535:
address: 0x21
number: 1
mode:
input: true
inverted: false