Gaijin66 wrote: ↑Thursday 20 December 2018 23:28
Why did
Code: Select all
mosquitto_pub -h localhost -m '{ "idx" : 3, "nvalue" : 1 }' -t 'domoticz/in'
turned the light only on the dashboard on?
I think this works as designed to enable two way communication without causing an infinite loop. There are some quite old discussions here on the forum about this subject but I have not found a clear and definite answer.
What I see when sniffing mqtt with
Code: Select all
mosquitto_sub -F "%U - %t - %p" -v -t '#'
sending the command
Code: Select all
mosquitto_pub -t domoticz/in -m '{ "idx" : 249, "nvalue" : 1 }'
Code: Select all
1545380550.427604212 - domoticz/in - { "idx" : 249, "nvalue" : 0 }
1545380550.552579044 - domoticz/out - {
"Battery" : 255,
"RSSI" : 12,
"description" : "",
"dtype" : "Light/Switch",
"id" : "00EC0A7A",
"idx" : 249,
"name" : "testLight",
"nvalue" : 0,
"stype" : "AC",
"switchType" : "On/Off",
"unit" : 11
}
switching the light in domoticz GUI
Code: Select all
1545380976.211775471 - domoticz/out - {
"Battery" : 255,
"RSSI" : 12,
"description" : "",
"dtype" : "Light/Switch",
"id" : "00EC0A7A",
"idx" : 249,
"name" : "testLight",
"nvalue" : 1,
"stype" : "AC",
"svalue1" : "99", <<<<==== different then via the nvalue command
"switchType" : "On/Off",
"unit" : 11
}
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>>
dzVents wiki