From 323c942337362cf33e02b7ff4cc29b747df3c9bd Mon Sep 17 00:00:00 2001 From: Theo Arends <11044339+arendst@users.noreply.github.com> Date: Sat, 26 Jul 2025 16:54:56 +0200 Subject: [PATCH] Add SO89 to LwDecode.be --- tasmota/berry/lorawan/decoders/LwDecode.be | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tasmota/berry/lorawan/decoders/LwDecode.be b/tasmota/berry/lorawan/decoders/LwDecode.be index e692de5de..3dc7b91ad 100644 --- a/tasmota/berry/lorawan/decoders/LwDecode.be +++ b/tasmota/berry/lorawan/decoders/LwDecode.be @@ -58,7 +58,11 @@ class lwdecode_cls if tasmota.get_option(83) == 0 # SetOption83 - Remove LwDecoded form JSON message (1) mqttData = {"LwDecoded":{deviceName:decoded}} end - mqtt.publish(self.topic, json.dump(mqttData)) + var topic = self.topic + if tasmota.get_option(89) == 1 # SetOption89 - Distinct MQTT topics per device (1) + topic = self.topic + "/" + deviceData[deviceName]['DevEUIh'] + deviceData[deviceName]['DevEUIl'] + end + mqtt.publish(topic, json.dump(mqttData)) tasmota.global.restart_flag = 0 # Signal LwDecoded successful (default state) end