Node-RED is a tool for wiring together hardware devices, APIs and online services in new and interesting ways. Using NodeRED the emonPi can become a central hub for home automation, control and notification.
At the heart of Node-RED is a visual editor allowing complex data flows to be wired together with little coding.
Node-RED is pre-installed and set up on the latest emonSD Raspberry Pi images, see emonSD repository and change log. If you are running an emonSD image that includes Node-RED browse to:
Username: "emonpi" Password: "emonpi2016"
emonpi for your local emonpi’s IP address if hostname lookup does not work
The Node-RED visual editor should load in the web browser with an example flow. The example flow subscribes to the emonPi MQTT (see MQTT docs) and extracts real-time values.
Make changes to the Node-RED flow by dragging-and-dropping nodes and connecting flows. Hit deploy to save and execute the configuration.
On the emonPi the node-RED data folder /home/pi/.node-red is soft-linked to the read-write folder
/home/pi/data/node-red so modifications to the flows can be saved.
For inspiration on what can be achieved with nodeRED and MQTT check out Martin Harizanov’s IoT Google hangout.