N00b + MQTT gw + openHAB2
-
If you want to play with node red, at the moment it is not supporting mysensors over mqtt but only serial and ethernet. Then depending on the level of integration and automation you want to have, there are different solutions: if you want some basic control of Arduino IO ports over Internet with a nice app, you could use cayenne, but if you want to have multiple wireless sensors and automation you'd better stay with mysensors and domoticz and start getting some experience; later on you can start looking at more complex scenarios.
@gohan Totally agree.
I'll push forward with your recommendations: ethernet+domoticz. After looking into Domo, I think it could serve me well for my purposes as a whole.
Any ideas about the code for the gateway: udp? controller ip? relays?
I will build one more Mysensors relay so I can verify radio working etc. -
I use MQTT and Openhab2 - I find it more flexible then the Ethernet GW but yes you need to have a good understanding on all systems I suppose.
Somethings to note
- MySensors binding doesn't support MQTT gateway as far as I know, you need to use the MQTT binding and configure your OH items accordingly.
- MySensors binding is in the IOT market place and not openhab-addons
- You'll need to assign node ID to your nodes manually.
Not entirely sure what your problem is here but don't think you've got all the right pieces for the puzzle yet.
-
I use MQTT and Openhab2 - I find it more flexible then the Ethernet GW but yes you need to have a good understanding on all systems I suppose.
Somethings to note
- MySensors binding doesn't support MQTT gateway as far as I know, you need to use the MQTT binding and configure your OH items accordingly.
- MySensors binding is in the IOT market place and not openhab-addons
- You'll need to assign node ID to your nodes manually.
Not entirely sure what your problem is here but don't think you've got all the right pieces for the puzzle yet.
-
@Qu3Uk I remember that Mysensors binding works both ethernet and MQTT, but anyway ethernet is the best solution for beginners because you can use myscontroller to debug messages while connected to controller.
-
@Qu3Uk I remember that Mysensors binding works both ethernet and MQTT, but anyway ethernet is the best solution for beginners because you can use myscontroller to debug messages while connected to controller.
@gohan said in N00b + MQTT gw + openHAB2:
but anyway ethernet is the best solution for beginners because you can use myscontroller to debug messages while connected to controller.
With MQTT you can also debug using MQTT-Spy or MQTTLens or various other MQTT apps.
MQTT is easy in interconnecting various systems without they have to know about each-other.
As long as you have a MQTT broker (RabbitMQ, Mosquitto, ActiveMQ, ...) you're all set.
In OpenHab in conf/services create a file called mqtt.cfg, and past the following:
mqtt:broker.url=tcp://ip-address-of-mqttbroker:1883 mqtt:broker.clientId=openhab mqtt:broker.retain=true mqtt:broker.async=falseThen in your items file you can do:
Switch Light_GV_Hall "Ceiling" (GV_Hall, Lights) {mqtt=">[broker:myhome/room/switch1:command:ON:1],>[broker:myhome/room/switch1:command:OFF:0],<[broker:myhome/room/switch1:state:ON:1],<[broker:myhome/room/switch1:state:OFF:0"}And now you can turn on/off the light from OpenHab as wel as from any other device that publishes to the same toppic (yes, even from MQTT-Spy and MQTTLens)
-
@gohan said in N00b + MQTT gw + openHAB2:
but anyway ethernet is the best solution for beginners because you can use myscontroller to debug messages while connected to controller.
With MQTT you can also debug using MQTT-Spy or MQTTLens or various other MQTT apps.
MQTT is easy in interconnecting various systems without they have to know about each-other.
As long as you have a MQTT broker (RabbitMQ, Mosquitto, ActiveMQ, ...) you're all set.
In OpenHab in conf/services create a file called mqtt.cfg, and past the following:
mqtt:broker.url=tcp://ip-address-of-mqttbroker:1883 mqtt:broker.clientId=openhab mqtt:broker.retain=true mqtt:broker.async=falseThen in your items file you can do:
Switch Light_GV_Hall "Ceiling" (GV_Hall, Lights) {mqtt=">[broker:myhome/room/switch1:command:ON:1],>[broker:myhome/room/switch1:command:OFF:0],<[broker:myhome/room/switch1:state:ON:1],<[broker:myhome/room/switch1:state:OFF:0"}And now you can turn on/off the light from OpenHab as wel as from any other device that publishes to the same toppic (yes, even from MQTT-Spy and MQTTLens)
-
Update.
After much trying the Ethernet gw would not connect to Domoticz.
Then, tried my mqtt sketch again and presto! I have connection AND I can control the two relays on board the mqtt-gw.
Had a cold one...or four!
Thanks for the recommendations and help. I'm sure I will need more later on. Now I'm going to explore the Domoticz forum for answers.
Unless someone with the same setup can tell me why the lights are crossed (on = off in reality and off=light on)?