changed mothode to get colors for mode 2 with new topic

Signed-off-by: Ebbe Baß <ebbe@ping-mee.de>
master
Ebbe Baß 2022-07-01 23:22:50 +02:00
parent a43c5a36fc
commit 5ba4ca8d8e
1 changed files with 6 additions and 1 deletions

View File

@ -169,8 +169,13 @@ if __name__ == '__main__':
power = payload
elif topic == "server-rack-led/rgb":
json_payload = json.loads(dict(payload))
global r
r = payload
r = str(json_payload["r"])
global g
g = str(json_payload["g"])
global b
b = str(json_payload["b"])
elif topic == "server-rack-led/mode":
if payload == "0":