diff --git a/esphome/fdm-exhaust-fan-control.yaml b/esphome/fdm-exhaust-fan-control.yaml index 2b6adc1..6b22d22 100644 --- a/esphome/fdm-exhaust-fan-control.yaml +++ b/esphome/fdm-exhaust-fan-control.yaml @@ -36,13 +36,20 @@ web_server: port: 80 # GPIO Outputs for fan control +# IMPORTANT: inverted: true because NPN transistor driver inverts the logic +# GPIO HIGH -> NPN ON -> Gate LOW -> Fan OFF +# GPIO LOW -> NPN OFF -> Gate HIGH (5V via pull-up) -> Fan ON output: - platform: gpio - pin: GPIO3 # D1 on XIAO + pin: + number: GPIO3 # D1 on XIAO + inverted: true id: fan_80mm_output - platform: gpio - pin: GPIO4 # D2 on XIAO + pin: + number: GPIO4 # D2 on XIAO + inverted: true id: fan_120mm_output # Fan entities for Home Assistant