Closed Erestes closed 1 year ago
binary_sensor:
- platform: gpio
id: button
pin:
number: GPIO14
mode: INPUT_PULLUP
inverted: true
on_press:
- switch.toggle: relay
this part is to have the switch working. in your Case the pin is GIPO14 (CF image)
This adds a switch in the interface that react base on the binary_sensor
switch:
- platform: gpio
name: ${plug_name}_relay
id: relay
pin: GPIO12
I would like to add a piece of config that would allow connecting a switch to pin:5 but I keep failing... I've added the following into the switch section: `# Define the switch
What am I doing wrong?