diff --git a/src/peripherals/valve/ValveComponent.hpp b/src/peripherals/valve/ValveComponent.hpp index 869d6b2d..1bbf11e5 100644 --- a/src/peripherals/valve/ValveComponent.hpp +++ b/src/peripherals/valve/ValveComponent.hpp @@ -266,7 +266,9 @@ class ValveComponent : public Component { // Ignore break; } - // TODO Publish event + mqttRoot->publish("events/state", [=](JsonObject& json) { + json["state"] = state; + }); } PwmMotorDriver& controller;