diff --git a/main.py b/main.py index c61c1da..9c4c67d 100644 --- a/main.py +++ b/main.py @@ -134,12 +134,14 @@ if __name__ == '__main__': topic = str(msg.topic) payload = str(msg.payload.decode("utf-8")) if topic == "server-rack-led/power": + client.publish("server-rack-led/power/status", str(payload)) global power power = payload global singleExecute singleExecute = True elif topic == "server-rack-led/rgb": + client.publish("server-rack-led/rgb/status", str(payload)) splitted_payload = payload.split(",") global r r = str(splitted_payload[0]) @@ -149,6 +151,7 @@ if __name__ == '__main__': b = str(splitted_payload[2]) elif topic == "server-rack-led/mode": + client.publish("server-rack-led/mode/status", str(payload)) if payload == "Rainbow": global mode mode = 0