Hacker News new | past | comments | ask | show | jobs | submit login
Node-RED: How an open-source tool is establishing itself in Industrial IoT (umh.app)
91 points by JeremyTheo on Nov 9, 2021 | hide | past | favorite | 28 comments



I tried to use node red a few times to automate my devices at home. It is limited in what it can do but the ui is ok. This until you want to change something, or duplicate, or arrange several items - the code is not really editable.

I understand that the target population are not programmers, but even using the built in Hole Assistant automation is better.

Of course moving to pyscript or appdaemon opens new world.

To be clear: I am not trying to be dismissive of node red users, it is just that one will quickly hit its limitations for anything more fancy.


I've had the opposite experience. In my day job I already write plenty of YAML, so I didn't want to do the same for Home Assistant.

Setting up a simple flow such as "Turn on the robot vacuum at 10PM unless the 3d printer is running, in which case please wait for it to be done and then continue" it's as simple as connecting two nodes together.

The main issues I had were:

* If there's no node that does what you want, it can become messy very quickly to replicate the functionality. Either that, or you use a script node (which kinda defeats the purpose)

* In particular for Home Assistant, it can be annoying if there's no entity already defined in HomeAssistant and you have to hunt down some field inside a message payload. Or maybe you have to craft some special json to do what you want.

* There doesn't seem to be a lot of logic on what nodes available out of the box. For example, if one wanted to have a 'for loop'. It doesn't really exist out of the box (but there are libraries for this). It seems to have evolved organically, rather than something that was designed

* You can connect anything to anything even when it doesn't make sense

* Debugging seems to be mostly done by adding a debugging node and looking at logs. Being an event-driven and message passing environment, the graphical debugging capabilities should be way better than they are.


Fully agreed!

Being a programer I really dislike using Node-RED for complicated calculations as you land up pretty quick into the limitations of "low-code" like version control (some is available in Node-RED but not that good), documentation, other best-practices.

However, for smaller stuff or connecting APIs this is absolutely great as it saves a lot of time around boilerplate stuff like package management, setting up a repo or Docker. We only do this smaller stuff also known as "customer specific configuration" and let our proper programs handle the rest.

Main target group is, like you said similarly, mechanical or industrial engineers with very limited IT knowledge, but still huge process expertise.


I've had the opposite experience: the newer versions are very flexible, reliable, and miles better than Home Assistant for my setup (which is Homekit-based with Node-RED doing dashboards and device characteristics handling).

And it even supports git now via the projects feature, which I am using to build an RSS feed fetcher that does translations and aggregations for 200+ feeds.

- https://taoofmac.com/space/blog/2019/01/13/1900 (home automation stuff, before I adopted projects and Git versioning. Has most of the links to previous applications).


I've just switched to one of my pinned Home Assistant tabs. One of my Node-RED flows has a function node with a wodge of JavaScript in it. The editor JS is simple but has colour syntax highlighting. I'm using it to send settings to some quite complicated Zwave devices. There is a Zwave set node that does the complex stuff that I really don't need to worry about, I just pump settings into it.

Another flow I did unlocks an AD account via LDAP! I used a function node to build up a quite horrific looking command line that is passed through a ssh connection to the host system (HA and NR are containers) to run against AD.

You can do an awful lot with NR out of the box and with all the contrib stuff it rapidly becomes even more impressive. Just enough programming for me. I write a program or two as needed and no more and it doesn't detract from the flow thing either.


I'm curious if anyone has tried [huginn](https://github.com/huginn/huginn) or [beehive](https://github.com/muesli/beehive) or similar, and whether or not these work well for programmers?


I tried both and was turned off by the amount of clicking and steps involved in doing anything. Node-RED just lets you drag and write code inside custom nodes with much less friction.


Thanks, good to know!


My experience is similar: if you're already a programmer, you'll hate it. Almost any language will be better suited.


Using subflows and such I've not had any issues with even relatively complex flows, though I would recommend using the unsafe code execution block for any macros, since then you have the full power of node.


We were looking at using something like this for a hacked together solution. The customer had field equipment that could not be replaced. It communicated back to a gateway via some protocol via 900MHz radio (from what I recall not one of the common ones). The customer found a new gateway that could aggregate the signals, but it only spit out some open TCP data stream. Our equipment is traditionally industrial, so it only supports industrial protocols (modbus, modbus tcp, EthernetIP, etc). It’s also not programmable at a low level (all drivers developed by the application developer).

We had used node-red in non-GMP environments before, but this was very much a GMP environment. What we figured out was that it would be impossible to qualify and validate the code base by any means that would satisfy QA.

So…great for labs and pre-manufacturing (development) where you have a bunch of skids or equipment that talk different protocols, but a difficult to use in any validated environment.

Now, being open source, it would be great if someone took the base application and built the other tools around it that would make it great for manufacturing where there are more strict regulations. Maybe Siemens is headed that way since they are rolling it.


Recent and related:

Node-RED: Low-code programming for event-driven applications - https://news.ycombinator.com/item?id=28985268 - Oct 2021 (90 comments)

Prior related threads:

Node-RED 2.0 - https://news.ycombinator.com/item?id=27892226 - July 2021 (62 comments)

How-to normalize home volume levels with Node-RED - https://news.ycombinator.com/item?id=23349902 - May 2020 (28 comments)

Node-Red – Flow-Based Programming for the Internet of Things - https://news.ycombinator.com/item?id=18859019 - Jan 2019 (77 comments)

Replacing a Pool and Spa Controller with Raspberry Pi, Arduino, Node Red - https://news.ycombinator.com/item?id=18142335 - Oct 2018 (3 comments)

Node-RED: A visual tool for wiring the Internet of Things - https://news.ycombinator.com/item?id=13495156 - Jan 2017 (6 comments)

Node-Red, a tool for wiring together hardware devices, APIs and online services - https://news.ycombinator.com/item?id=8419984 - Oct 2014 (8 comments)

Node-RED - https://news.ycombinator.com/item?id=8310536 - Sept 2014 (1 comment)

Node-red, a visual tool for wiring the Internet of Things - https://news.ycombinator.com/item?id=8217664 - Aug 2014 (3 comments)

Programming the Missing Links in the Internet of Things - https://news.ycombinator.com/item?id=6459564 - Sept 2013 (1 comment)


Is there any supported way to integrate a data-diode into this? This would allow far more secure remote monitoring of systems by exfiltrating real time data through the data-diode, and having certainty that you don't risk of control infiltration.


Very interesting idea! Thank you!

I would not move it between Node-RED and the PLC but I see other applications of a data diode. We usually create a very small DMZ around each machine and a data diode can additionally protect it (see also a very old article from us: https://docs.umh.app/docs/getting-started/usage-in-productio... ) You could place the data diode as a "firewall" between the internet and the edge PC.


I made POC for Festo a few years back using OPCUA that was mentioned in the Article. Agree, the manufacturers really want their systems to be federated and locked into their own systems (eg. Rockwell, Siemens).

Here's the post on the Project:

https://medium.com/@tuffluver/control-an-industrial-robot-wi...


I back a company around NodeRed, FlowForge Inc. https://flowforge.com/blog/first-deploy/

It is building a low-coding development platform fit for the enterprise with Node-RED at its heart.


TLDR: Use Node-Red as a dashboard reporting tool but do not use it for its anything critical.


In my last job I used to work with a major vendor (in industrial manufacturing) who provided a Cloud+Edge Integration solution for factories. The Edge portion was a Industrial PC with a software layer that basically allowed you to deploy stuff developed in the "Cloud" to the Edge PC.

One of the OOTB things on the Edge stack was a customized version Node-Red. It was one of the most popular components for customers and used a lot in factories.

Yes, it's true that you don't want to use it as the thing that connects your industrial controller/PLC to a Python script (running in a container on the Edge PC) that decides if a machine should be turned off for safety reasons.

But there are a lot of use cases if you think about it as a low/no-code development environment for streaming data. It provides a way to automate a lot of boring manual processes around data. Being able to use Javascript code snippets also means a lot of developers have an easy way to deploy small blocks of codes. It's easier to learn JavaScript than trying to figure out something with a PLC or a SCADA system.

The dashboarding was also pretty nice - especially compared to the Dashboards you'd see on a machine HMI (basically a touchscreen that controls a machine).

It wasn't perfect of course. If your sensor data is streaming at 1Khz you'd need to use something else. But the data from a lot of factories is a lot more mundane than that. And a lot of fancy factories have mundane things they need done simply and quickly.


Is this based on personal experience? Because the article says that it’s production ready and many industrial environments.


The article says, near the bottom,

> However, we strongly recommend NOT using it to intervene in the production process, e.g., process control or ensuring safety mechanisms


Well, yeah... I am not going to wire my e-stop to a node red process/board. Somethings need to be on proper PLC controls as the article states.


Ah, so it's the technical world's definition of "production" but not the manufacturing world's definition of "production"


I've used it for critical ops successfully over the course of a few years. It's not perfect but it's also not a toy app anymore.


Using Nodered since 2019 in smartfactory projects, mainly to unify very different datasources to something compareable. Swiss army knife for factory telemetry..


Node-RED also works pretty well for museum interactives.

https://imgur.com/a/3XAH5LD


I don’t think I’d ever use something javascript based for industrial purposes. Reliability is too important.


No scripting languages?


I suppose this is where we say "CNC would like a word."




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: