Hi.
I made a fresh install of Raspbian Jessy in my Raspberry Pi 2.
Then I installed Openhab2 and Mosquitto server.
I have one NodeMCU module with an LED in gpio 2. The NodeMCU was flashed first with Espeasy firmware and later with another piece of code and the Arduino IDE. Both firmwares worked.
Opening 2 terminals I can send mqtt messages to the NodeMCU, turn on or off the LED and receive feedback.
Now the problem. It seems that Openhab2 can’t connect to mqtt.
-
The Mqtt binding and the JsonPath transformationaddon addons are installed.
-
This is my mqtt.cfg file in etc/openhab2/services/mqtt.cfg
mosquitto.url=//192.168.1.250:1883
mosquitto.clientID: openhab
mosquitto.retain=true
mosquitto.async=false -
This is my default.items file in /etc/openhab2/items
Switch light1 { mqtt=">[mosquitto:/house/light1:command:on:1],>[mosquitto:/house/light1:command:off:0],<[mosquitto:/house/light1:command:on:1], <[mosquitto:/house/light1:command:off:0]"}
- And this is my default.sitemap file in /etc/openhab2/sitemaps
sitemap default label=“Domotica Villa Alamo” {
Frame label=“Piscina” {
Group item=Piscina
Switch item=light1 label=“Luz piscina”
}
}
}
I can see the Switch in Basic UI, but it doesn’t work. Am I missing something?
Thanks