I'm trying to test mqtt protocol with Domoticz. For that I'm using a BeagleBone Black with mosquitto that takes a value from a existing sensor in Domoticz with JSON, and send this value over MQTT to Domoticz to a virtual sensor. the problem is that I'm not getting any value on the virtual sensor. I'm using a shell script
Code: Select all
#!/bin/bash
while true
do
value=$(python -c 'import sensorValue; print sensorValue.sensor_value(8)')
mosquitto_pub -h 192.168.1.13 -m '{ "idx" : 13, "nvalue" : 0, "svalue" : "$value" }' -t 'domoticz/$
sleep 1
done
Regards,
Marcelo
ps: sensorValue is a function that takes the value of an specific sensor on Domoticz. In this case idx=8