Node red 101

Can someone help me understand the basics of node red. I understand it handles flows / automation.

My question if using with hubitat, do you just pull in all devices to hubitat, turn do all the automation in node red and don't touch the apps in hubitat?

You can run Node-Red and Hubitat based automations in parallel. You don't have to completely commit to Node-Red and shun potentially useful Hubitat apps.

On the other hand, you also have the option of moving everything to Node-Red and using Hubitat as a glorified device coordinator. Both approaches work equally well at a technical level in my opinion. I put everything in Node-Red because it was easier to keep track of everything (and tie automations together) in one place. It's just personal preference.

The easiest way to get started with Node-Red is to just play around with it. Set up a device node along with a debug node to see what messages are generated with various events. Then, play around with command nodes and see what's possible. Once you have an idea of what the messages structures are, you can start adding logic nodes and you're off to the races!

There's plenty of Node-Red videos available, but I have a particular liking to this one:

https://www.hubitatcommunity.com/nodered/Hubitat_Node-Red/index.php

Plan on using pause a lot. The video is fast paced and Hubitat specific although the version of Node-Red shown is several versions back, the ideas are still valid.

4 Likes

are the numeric data types still always returned as string from the community node-red implementation?

Sorry to but in,.... (says the guy who is doing it anyway :slight_smile: )... But this does feel like there should be a topic for the HE plugin for NR, if there's not one already..... Feels like calling out the discussion for what it is would be more helpful, if it doesn't already exist...

1 Like

One of the earlier threads is here: https://fcommunity.hubitat.com/t/node-red-palette-common-choices/38896 but there is an entire category of Node Red discussion (Node-RED - Hubitat) to find answers in.

2 Likes

:point_up: That's the guy who did the research I could not be bothered to do... :slight_smile:

:rofl:
Just one of the categories I spent a lot of time reading at one point.

2 Likes

So we shouldn't call @JasonJoel into this conversation... you've got this covered.... :wink:

I’m 100% Node Red. I don’t have RM installed on either of my hubs. I didn’t start off that way but ended up there very quickly. The forum here helped me a lot.

1 Like

As usual there are much more competent people on this forum in terms of remembering where the info is.

I will say I disagree with all sorts of guides on node choices and how to use them, though. But each to their own.

I regularly see people doing things in function nodes with JavaScript that you could easily do in two or three standard nodes.

I will almost always do something in two or three nodes versus writing JavaScript in a function node. I find it more maintainable long-term, And it is much easier to see what is going on visually in the flow.

Others have the opposite opinion.

That's not to say I never use function nodes, there are some things it is easier for or that would be extraordinarily messy doing it with standard nodes.

2 Likes

Who invited him.... ? :-p

2 Likes

Peace and love brother. Peace and love.

I'm not in an argumentative mood today. :slight_smile:

2 Likes

Me neither, only friendly tongue-in-cheek banter.... :slight_smile:

Happy to have your input, definitely more experience than I can provide.

1 Like

I tried oh so hard to remain pure... but I have fallen more often lately. I have 5 fan controllers tied to temperature sensors to set fan speed. The sensors can have an offset set to normalize room to room, but I want the raw temps too so I put a change node to perform the offset.

to become:

I couldn't help myself. I wanted to quit, but couldn't. :smiley: :smiley: :smiley:

Why? because I wanted the little hint below the Function that the Change Node didn't offer. :smiley:

2 Likes

You've won this one @JasonJoel .... :wink: We'll win @csteele back.... :rofl:

2 Likes

I am the same way. When I migrated from Wink, I duplicated the logic in HE rules. Once I had things settled, I used the same logic in Node-RED and haven’t touched the HE rules again (they are all disabled).