It is not possible to use transformations with the command (outbound) topic yet…
You will need to use a proxy item and a rule:
and change your thing:
Thing mqtt:topic:irremote {
Channels:
// Type number : uptime "LED Stripe uptime" [ stateTopic="MyS-Node/5/255/3/0/22" ]
// String ZmoteString "Zmote IR [%s]" (IRGroup) {mqtt=">[broker:cmnd/zmote-01/IRSEND:command:*:default]", "<[broker:stat/zmote-01/RESULT:state:default]"}
Type string : ir_code "IR Code" [ commandTopic="cmnd/ZMOTE-01/IRSEND"]
Type number : ir_wifi "IR Wifi Signal" [ stateTopic="tele/ZMOTE-01/STATE", transformationPattern="JSONPATH:$.Wifi.RSSI" ]
}
item:
String proxyItem
rule:
rule "proxy IR mqtt"
when
Item proxyItem received command
then
IRCode_01.sendCommand(transform("MAP", "iridual.map", receivedCommand.toString))
end
Sitemap:
Frame label="IR Remote" {
Selection item=proxyItem mappings=['AUS'='AUS', 'R2-1'='Kerze', 'R4-3'='Herz']
}
Your map file seems strange, are you sure that’s it? Maybe it should be:
R1-1={"Protocol":"NEC","Bits":32,"Data":"0x407F8877"}
R1-2={"Protocol":"NEC","Bits":32,"Data":"0x407F6897"}
R1-3={"Protocol":"NEC","Bits":32,"Data":"0x407F50AF"}
R1-4={"Protocol":"NEC","Bits":32,"Data":"0x407FC03F"}
AUS=???
R2-1=???
R4-3=???