Hello,
i try to control a pump with two switches.
if the box become full level (water max is State On) the pump should start and if the water level becomes low (water min State ist OFF) the pump should switch off
Who can help me to realize it in esphome .
I tried
binary_sensor:
- platform: status
name: "ESP-Keller-02 System Status"
- platform: gpio
name: "water_min"
id: "water_min"
pin:
pcf8574: pcf8574_hub
# Use pin number 0
number: 4
# One of INPUT, INPUT_PULLUP or OUTPUT
mode: INPUT
inverted: true
on_turn_off:
- switch.turn_off:pump
- platform: gpio
name: "water_max"
id: "water_max"
pin:
pcf8574: pcf8574_hub
# Use pin number 0
number: 5
# One of INPUT, INPUT_PULLUP or OUTPUT
mode: INPUT
inverted: true
on_turn_on:
- switch.turn_on:pump
switch:
- platform: gpio
pin: D7
id: pump
name: "pump"
inverted: true