From 28475fa563a84edb66ca5fbeb40e8fd9971c64deedc232ee0df2c786ceb8fe19 Mon Sep 17 00:00:00 2001 From: localhorst Date: Sat, 21 Dec 2024 21:21:12 +0100 Subject: [PATCH] invert Circulation Pump GPIO --- README.md | 2 +- main/outputs.c | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index f7e0475..e583a8f 100644 --- a/README.md +++ b/README.md @@ -75,7 +75,7 @@ Sntp <|-- Metrics | Function | ESP32 | PLC ES32C14 | |---------------------------------------|-------|---------------------------| -| Output CirculationPump | IO27 | Relay 1 NO1 | +| Output CirculationPump | IO27 | Relay 1 NC1 | | Output Burner Fire Signal | IO14 | Relay 2 NC2 | | Output Safety Contact (powers Burner) | IO12 | Relay 3 NC2 | | Input Burner Fault | IO19 | Digital Input IN1 | diff --git a/main/outputs.c b/main/outputs.c index 3309ce2..7536e76 100644 --- a/main/outputs.c +++ b/main/outputs.c @@ -66,10 +66,10 @@ void setCirculationPumpState(eOutput in) switch (sCirculationPumpState) { case ENABLED: - gpio_set_level(uCirculationPumpGpioPin, 1U); // Switch on Circulation Pump + gpio_set_level(uCirculationPumpGpioPin, 0U); // Switch on Circulation Pump break; case DISABLED: - gpio_set_level(uCirculationPumpGpioPin, 0U); // Switch off Circulation Pump + gpio_set_level(uCirculationPumpGpioPin, 1U); // Switch off Circulation Pump default: break; } @@ -133,6 +133,7 @@ eOutput getSafetyControlState(void) } return ret; } + void setSafetyControlState(eOutput in) { if (xSemaphoreTakeRecursive(xMutexAccessOutputs, pdMS_TO_TICKS(5000)) == pdTRUE)