HomeAssistant: Node Red and Nora Installation.

Home Automation is a lot like lego for grown ups. You can put things together in all manner of ways that make sense to you.  Trouble is most devices have an app that usually runs on your phone that tends to be brand or even product specific.  Which tends to make it harder than it needs to be to use input a with output b. 

IFTTT or If this then that, was a handy service that connected A to B for you but then they decided just getting paid by manufacturers wasn’t enough and they wanted users to pay too.  So use home assistant instead.  The ideal home system uses the ‘cloud’ as little as possible but then there are some cloud services you may want to use… 

Lets give an example Tuya is a big chinese company that makes bulbs switches doorbells ect which are rebranded by various companies.  they have an app that lets you operate these devices.  You can link your tuya account to say google home assistant and then you can say ok google turn on the kitchen lamp and then the google home app says to the tuya clould turn on the lamp and then an instruction comes back to your lamp saying turn on.  Now if you cut out tuya by flashing the lamp with Tasmota then you get a lamp that can be locally controlled via home assistant, no internet needed but now google home can’t control the lamp any more for you.

OK so getting back that functionality you need nora and node red and a package for home assistant.  So now you can expand what Google home can do with your own commands. So you say to google do X this connects to nora which provides inputs to your devices via node red and things happen. 

Node Red makes connecting things almost code free by giving you a graphical interface to wire things together. Its a kind of visual programming language which creates the configuration and code needed to make things work, without making you learn programing. 

Ok so here is the point of this post installing node red and nora to work with home assistant. 

Installing node red is here https://nodered.org/docs/getting-started/raspberrypi 

bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)

This script will work on any Debian-based operating system, including Ubuntu and Diet-Pi. You may need to run sudo apt install build-essential git first to ensure npm is able to build any binary modules it needs to install.

That should install without too many problems  you may want to run 

node-red-pi --max-old-space-size=256

lets start node red with

node-red-start

https://zachowj.github.io/node-red-contrib-home-assistant-websocket/guide/#using-npm-from-the-command-line 

Ok So next you need to use the palette manager  in node red and search for 

node-red-contrib-home-assistant-websocket

and install it.


You now just need to link to your home assistant instance add an event node and create new server using the address of your home assistant. You need along lived access token which you generate as your user in homeassistant. 

https://node-red-google-home.herokuapp.com/login

Next is nora you need a github account or google account to login with and this will give you an access key. 

Basically search for nora in the palette manager and install it use the key to authenticate with Nora and then select nora from “works with Google” in google home.    

Now you use the nora nodes to connect with google and the home assistant nodes to connect with home assistant.  Of course there is more to using it than that but the links  in this post should get you started.