Hi guys, sorry if this have already been discussed but I did not find a thread about that…
TL;DR;
It seems that openHAB let you define items without specifying a format and this works perfectly if it’s populated by a binding.
Exemple :
item : String CPU_Name "Name" <none> (SystemInfo) { channel="systeminfo:computer:work:cpu#name"}
sitemap : Default item=RpiOHvmc_CPU_Name
But this won’t work if the value is updated by a event bus synchronization via MQTT.
Explanation :
I have server running OH2 as master and an rpi running OH2 as slave. They are event and command synchronized using MQTT with MQTT v1 binding. Everything is perfectly working for this and I can see states coming from slave and commands going to slave.
What I don’t understand is why sitemap is working when you define an item (on the slave) :
String CPU_Name "Name" <none> (SystemInfo) { channel="systeminfo:computer:work:cpu#name"}
And in the sitemap :
Default item=RpiOHvmc_CPU_Name
But not if you define the item without the binding channel (on the master, updated by mqtt event) :
String CPU_Name "Name" <none> (SystemInfo)
And in the sitemap :
Default item=RpiOHvmc_CPU_Name
By the way, if I define the same item on the master like this :
String CPU_Name "Name [%s]" <none> (SystemInfo)
It’s perfectly working again
I don’t know if this can be considered as a bug or not…