DisclaimerPlease, proceed carefully following the tips published in this blog, specially when Main Power is involved. I'm not responsible for any damages caused by what is written in this blog.
Home Automation System - MQTT and RF433 to monitor photovoltaic production
by Marco Lamanna
Now I will try to integrate my RF433 Wireless Receiver (built on Arduino with Ethernet Shield) with MQTT, just to acquire my photovoltaic production data in my future Home Automation System
I don't write nothing more about my acquisition system; this is my old post about that:
Now I would like to transmit data to my MQTT broker, for the future integration with OpenHAB
So, I have to edit the code of the Arduino sketch and let it to publish messages to the MQTT broker. In this time, the receiver publishes data to a HTTP REST Web Service
Well, using Arduino IDE (the same thing used for the SONOFF firmware upload), I open the sketch and edit the code.
I omit the technical details about the code because it's not the purpose of this post, but if you are interested in it, write me an email; I will be happy to share my code with you.
I chose the following MQTT topic:
I followed the same naming convention as the SONOFF :
The content of the message is simply the value of the production in Watt.
Here are the published messages, through mqtt-spy:
And here is the receiver:
Currently it's "mute", but the next step would be adding a led to monitor its status and eventually some environmental sensor...