Rasp-Node-Red-Installer
Now that we have node we can then jump in to downloading Node-Red. There is a tutorial on their git for the Pi which can be found here. But as always I want to take a different route as I want to use git to ensure that we always stay up to date with any new commits to the node-red repository.
We will now install Git. This allows us to clone git hub repositories. If you have never heard of git hub it is definitely something you should look into. In essence though it is a good way of adding some version control and open source collaboration to your projects.
To install Git carry out the following command.
sudo apt-get install git-core
Once Git has installed along with all of its dependencies we want to navigate to our home directory where we will install Node-Red.
cd ~
We will then clone in our Node-Red repository (repo) to the directory with the following command.
git clone https://github.com/node-red/node-red.git
You will then find that you have a folder cloned into the directory called “node-red”. We will now install everything using “npm” which is known as the Node Package Manager.
cd node-red
sudo npm install
After a while everything should run through and install for you. Next we can get Node-Red running, we still have some bits to do but its worth testing first. Make sure you are still in the /home/pi/node-red directory for this one.
sudo node red.js
You will see a lot of information print out on to the screen, errors about missing packages and all of the good stuff. However the one line you are looking for is related to Node-Red being available on the default 1880 port.
So next you need to navigate to your Pi’s IP address and port to see Node-Red in all of its glory.
http://Pi-IP-Address:1880
You should be welcomed to a blank canvas with all of the “nodes” available on the left hand of the screen. You can drag and drop these to start wiring things together. We will next be discussing how to create your first "flow" using these nodes.
Source: Raspberry Pi Hosting Node-Red
Créé par C. Mobberley pour AdaFruit Industries.
Traduction réalisée et augmentée par Meurisse D. pour MCHobby.be.
Toute référence, mention ou extrait de cette traduction doit être explicitement accompagné du texte suivant : « Traduction par MCHobby (www.MCHobby.be) - Vente de kit et composants » avec un lien vers la source (donc cette page) et ce quelque soit le média utilisé.
L'utilisation commercial de la traduction (texte) et/ou réalisation, même partielle, pourrait être soumis à redevance. Dans tous les cas de figures, vous devez également obtenir l'accord du(des) détenteur initial des droits. Celui de MC Hobby s'arrêtant au travail de traduction proprement dit.
Traduit avec l'autorisation d'AdaFruit Industries - Translated with the permission from Adafruit Industries - www.adafruit.com