Hi
I have a beginners understanding problem:
Situation:
Setup on a raspberry pi OH3 and MQTT. Everything works fine in a terminal eg:
mosquitto_pub -h “MyIP” -p “MyPort” -t “myTopic” -m {on | off } -u “uname” -P “pwd”
Switch is turned on and off.
In OH3
Installed the binding
Created a MQTT Bridge. Added uname and pwd in the configuration
Created a Thing Generic MQTT Thing
Add a channel
MQTT Command Topic: “myTopic”
Custom On/Open Value: on
Custom Off/Closed Value: off
Add in a page a switch
Configured widget: With the item created.
Test the switch in the page: Nothing happens.
openhab-cli showlogs:
MqttSwitch01_MqttSwitchChannel01’ received command OFF or ON
Things are always Online
But the link I created was invalid.
Dropped and recreated the link. Specified the corresponding item.
Now it works.
Thanks for your feedback.