Ligne 2 : |
Ligne 2 : |
| | | |
| {{traduction}} | | {{traduction}} |
| + | == Qu'est-ce que Node-Red? == |
| + | Node-Red in its simplest form is an open source visual editor for wiring the internet of things produced by IBM. What does this mean? Well for someone lazy like me it means I can spend more time making stuff "talk" to each other than worrying about all of the interfacing code I will need to write. |
| + | |
| + | The system contains "Nodes" which look simply to be icons that you drag and drop on to the canvas and wire together. Each Node offers different functionality which can range from a simple debug node to be able to see what's going on in your flow, through to a Raspberry Pi node which allows you to read and write to the GPIO pins of your Pi. |
| + | |
| + | To give an example of what can be done here is my home twitter account telling me where I'm currently located and whether it is going to rain any time soon. I even have a Google maps link thrown in for good measure. |
| + | |
| + | {{ADFImage|Rasp-Node-Red-00.png}} |
| + | |
| + | The flow to produce something like this within Node-Red is shown below and it took me literally 15 minutes to have everything set up. |
| + | |
| + | {{ADFImage|Rasp-Node-Red-01.png}} |
| + | |
| + | To summarise the flow: |
| + | * An App on my phone called MQTTitude send my location to Node-Red |
| + | * The basic framework of my twitter message is then created in a function node |
| + | * I take my location and query Forecast.io for the weather at that location |
| + | * The returned data is then formatted in to my tweet message using further function nodes |
| + | * The message is then sent to a Tweet node and tweeted for me |
| + | |
| + | Normally this would have taken me a good few hours to complete. But with Node-Red I am able to do it in minutes. I am not worrying about all of the interfacing to MQTT, HTTP or Twitters API. All of that is done for me by Node-Red. |
| + | |
| + | So now I've sold you the idea.. lets get to the installation! |
| | | |
| {{Rasp-Node-Red-TRAILER}} | | {{Rasp-Node-Red-TRAILER}} |