added mqtt subscribe to universe

Signed-off-by: Ebbe Baß <ebbe.bass>
main
Ebbe Baß 2024-02-17 00:31:16 +01:00
parent 697774c537
commit 0649f4fd97
1 changed files with 1 additions and 2 deletions

View File

@ -116,8 +116,7 @@ if __name__ == "__main__":
mqttc = mqtt.Client(mqtt.CallbackAPIVersion.VERSION2)
mqttc.connect("192.168.0.1", 1883, 60)
mqttc.on_message = on_message
for address in range(dmx_address, dmx_address + 18):
mqttc.subscribe(str(universe)+"/"+str(address), 0)
mqttc.subscribe("PiXelTubes/"+str(universe), 0)
settingsUpdateThread = Thread(target=loopCheckSettingUpdates, args=())
pixelUpdateThread = Thread(target=mqtt_listner, args=(universe, dmx_address, strip, LEDS_PER_PIXEL))