JSON ("let it be" ;)

I just reflashed a IR-Blaster with Tasmota. So I am using MQTT as protocoll.

Playing with some IR-Remotes I got following entries:

15:00:23.480 MQT: Infrared/IR80/tele/RESULT = {"IrReceived":{"Protocol":"SONY","Bits":12,"Data":"0x11","DataLSB":"0x88","Repeat":0}}
15:00:25.333 MQT: Infrared/IR80/tele/RESULT = {"IrReceived":{"Protocol":"SONY","Bits":12,"Data":"0x811","DataLSB":"0x1088","Repeat":0}}
15:00:27.288 MQT: Infrared/IR80/tele/RESULT = {"IrReceived":{"Protocol":"SONY","Bits":12,"Data":"0x411","DataLSB":"0x2088","Repeat":0}}
15:00:30.891 MQT: Infrared/IR80/tele/RESULT = {"IrReceived":{"Protocol":"SONY","Bits":12,"Data":"0xC11","DataLSB":"0x3088","Repeat":0}}

Doing a sen (inside Tasmota is working like a charme (stripped JSON with the optional parameter)


As You can see, I have so send exactly what I have received.
But with a String/Item and “STANDARD” transformation (JSONPATH:$.IrReceived) the incomming String looks like this:

{Protocol=SONY, Bits=12, Data=0x11, DataLSB=0x88, Repeat=0}

So I can not save and reuse it later for irsend :frowning:
Infrared/IR80/stat/RESULT = {“IRSend”:“Invalid JSON”}

How can I disable this transforation OR retransform it back to a valid JSON I can simply use within a Script → sendCommand: “”

Gratings David

In stead of JSONPATH transformation, why not strip the incoming message using REGEX.

Sorry I did not see:
(I guess I can do it by myself)

Can you give an example how (and where) to insert REGEX Expression?


in stead of


Of course install the REGEX transformation (but I can see you figured that out already) :slight_smile: