Noob alert
I’ve got Mosquitto server seemingly running fine on my Rpi zero. I can pub and sub from MQTT fx app on my mac and all seems to be working there.
I’ve got openhab + demo installed on same Rpi zero and demo loads in browser just fine. I altered the .items file to try to get one of the demo switches to communicate with the MQTT, but seems a no go. Here’s what I’ve got:
openhab.cfg: file
################################# MQTT Transport ######################################
mqtt:mymosquitto.url=tcp://192.168.0.17:1883
addons folder
pi@raspberrypi:/usr/share/openhab/addons $ ls
org.openhab.action.mqtt-1.8.1.jar org.openhab.binding.mqtt-1.8.1.jar org.openhab.persistence.exec-1.8.1.jar org.openhab.persistence.mqtt-1.8.1.jar README
org.openhab.binding.http-1.8.1.jar org.openhab.binding.ntp-1.8.1.jar org.openhab.persistence.logging-1.8.1.jar org.openhab.persistence.rrd4j-1.8.1.jar
demo.items file
Switch Light_C_Corridor_Ceiling “Ceiling” (gC, Lights) {mqtt="<[mymosquitto:openhab/garage/relay1:command:ON],>[mymosquitto:openhab/garage/relay1:command:OFF]"}
openhab log when use switch in demo
2016-02-26 20:52:25.455 [INFO ] [runtime.busevents ] - Light_C_Corridor_Ceiling received command ON
2016-02-26 20:52:27.801 [INFO ] [runtime.busevents ] - Light_C_Corridor_Ceiling received command OFF
mosquitto log when I publish from the MQTT fx app from my mac
1456548779: Received PUBLISH from 41ce2c94f49e4af1a6e8ce95d88b06e3 (d0, q0, r0, m0, ‘openhab/garage/relay1’, … (2 bytes))
1456548779: Sending PUBLISH to 41ce2c94f49e4af1a6e8ce95d88b06e3 (d0, q0, r0, m0, ‘openhab/garage/relay1’, … (2 bytes))
1456548819: Received PINGREQ from root.1456546975763
1456548819: Sending PINGRESP to root.1456546975763
1456548839: Received PINGREQ from 41ce2c94f49e4af1a6e8ce95d88b06e3
1456548839: Sending PINGRESP to 41ce2c94f49e4af1a6e8ce95d88b06e3
What am I missing to get openhab demo communicating with mosquitto? Can anyone help?