- Platform information:
- Hardware: Raspi 4, ConBee II
- OS: Raspbian
- Java Runtime Environment: openjdk11
- openHAB version: openHAB 3.0.2 Release Build
Hey there,
I use the MQTT-Binding together with zigbee2mqtt (which shouldn’t matter, just for completion) and a mosquitto broker.
First I created a MQTT Broker Thing and set up the connection.
To then add a device I configured a Generic MQTT Thing, and add a channel (as well as an Item to hold the value):
UID: mqtt:topic:8e28935d28:e00b881b84
label: TRADFRI Remote Control
thingTypeUID: mqtt:topic
configuration: {}
bridgeUID: mqtt:broker:8e28935d28
channels:
- id: zGfEOsP7J6
channelTypeUID: mqtt:string
label: Action
description: ""
configuration:
stateTopic: zigbee2mqtt/0x588e81fffe032c3c
I now can receive the payload of the added device (a remote control):
{
"action": "toggle",
"battery": 87,
"linkquality": 255,
"update": {
"state": "idle"
},
"update_available": false
}
However, if I try to use the transformationPattern
property, it doesn’t work.
I try to set transformationPattern: JSONPATH:$.action
but it is just ignored and the Item just holds the entire payload instead of just the value of action.
best regards gkhaos