/r/nodered
A place to share nodes and flows, and discuss Node-RED, a low-code tool for event-driven applications.
Node-RED is a drag and drop programming tool made by IBM Emerging Technology to automate the Internet of Things.
You can think of it as the glue that connects your phone to your air conditioner, so that your AC is on half an hour before you get home.
Project home page at: http://nodered.org
/r/nodered
I've got a fan I want to control by both Radon- and CO2-levels. Whichever is "worse" must be the decider.
Fan settings are 0%, 25%, 50%, 75% and 100%
Radon-levels are 0-200
CO2-levels are 0-2000
If Radon = 200 and CO2 = 0 then the fan = 100%
If Radon = 0 and CO2 = 100 then the fan = 25%
If Radon = 100 and CO2 = 200 then the fan = 50% and so on.
Any pointers on how to do it?
Hi all,
I have started using Node Red a couple of months ago and have managed to get data in and out of REST APIs following lots of examples online. I can also display JSON data on a Dashboard (2.0) with the standard table node.
My problem is, I now want to show tables with nested data.
Tabulator supports this but I have no clear examples of how to get this working,. I think I need to send commands to the tabulator node and then link it to the standard table? Can anyone provide or point me to a guide with examples of how to do this please? The tabulator site has lots of reference data but I don't know how to apply this to the Node Red workflow. I can only go so far on guesswork and limited coding experience.
Any pointers would be greatly appreciated.
Hi everyone!
I'm developing a chatbot using Node Red and the node-red-contrib-ai-intent package, and I'm encountering a persistent issue with function invocation. The chatbot seems to get trapped in an endless loop, repeatedly calling the same function even when it should logically stop.
Specific details:
Has anyone experienced similar challenges? Any insights on:
Any guidance or troubleshooting tips would be greatly appreciated!
Hi,
I'm wondering: is possible to use a global variable in e.g., a change node, or do I need to replace it with a function node to be able to call the global variable?
Thanks!
Hey guys, so amnew to node red and am still trying to learn it but I have an issue that i cannot solve If someone can help Pls !
So I want to display my database info in a table. If I use tableify it works perfectly, But I want to do it using a template node because it's more flexible.
Am using : http in (post) => Mongodb in => Funtion that collects data and does some math on the data => Tableify => Http response. So this works perfectly.
But when I use template instead of tableify (or even a template after tableify) it doesn't work anymore ( { template (the orange one) nor </> template (the blue one) ) and it's a huge obstacle for me ATM
If someone can help I would appreciate it <3
Here is the result of the first flow
But when I use a template : { template (the orange one) or </> template (the blue one) it doesn't work anymore.
I used a debug node in each step and I have the problem specifically in the template.
If anyone knows how to fix this problem, I would appreciate the help ! much love reddit <3
I'm a Chinese software technology blogger who has been blogging consistently for more than 8 years, and all my posts are on CSDN (China's largest technical communication community). I wrote a column about Node-RED, there are more than 80 articles, contains the basic concept of Node-RED explanation, use, component development, business case design, and some project examples I did using it. But these documents are all in Chinese, I don't know if anyone needs them. Here's the link to the column.
https://blog.csdn.net/github_35631540/category_11294112.html
If anyone wants to know more about it, feel free to write to me privately, and if anyone wants technical support for Node-RED, I'd be happy to help.
Should i change the code or add a function connected to the switch
Hello Redditors,
I wanted to ask a small question, I am currently working with a Zynq 7000 series SoC module and have Node-Red installed on it via Embedded Linux, can you also find a library for Zynq 7020 IO pins? like Raspery pi?
My board is a Digilent Pynq-Z1
Thank you!
I use node-red as a home-assistant add-on. Both are up to date, with the add-on version 18.1.1. Everything has been working, but since I last touched node-red, at some point none of the Inject nodes work as buttons in the interface. They'll work as expected at specific times etc, but can't be used as a push-button any more for debugging. I've scanned the changelogs, but don't see anything really relevant.
Is that new behavior, or am I missing something stupid?
Hi,
Nodered Noob here.
I am trying to get power readings form my shelly PM mini.
In the picture is the Output from the Shelly API. The only problem is the ":" in "pm1:0".
Please could someone telly me, how to extract the "apower" value. All my attempts failed because of the ":"
FlowFuse MQTT Broker for Industrial Transformation
Optimize your industrial processes with FlowFuse MQTT Broker, a new service that simplifies real-time data access.
In today's rapidly evolving industrial landscape, real-time data is the key to unlocking operational efficiency and driving innovation. However, managing and utilizing this data effectively can be a significant challenge. Legacy systems, disparate data sources, and complex integration processes often hinder organizations from harnessing the full potential of their industrial data.
This is where an MQTT Broker can help. It acts as a central hub, facilitating communication between devices and applications by receiving, filtering, and distributing messages.
About the Webinar:
In this webinar, we'll introduce the FlowFuse MQTT Broker, a seamless solution that enables you to manage all your MQTT clients, Node-RED instances, and devices from a single, centralized platform, eliminating the need for a separate broker service.
Join Nick O’Leary, creator of Node-RED and CTO at FlowFuse on November 27, 2024, at 17:00 CET (11:00 AM ET) to learn about :
Who Should Attend?
This webinar is perfect for:
Register now to secure your spot and take the first step toward transforming your industrial processes with FlowFuse!
Hey guys.
I have a device I’m trying to control via Telnet. I can control it just fine with basic strings through Telnet via putty, though as soon as I try via node red I get all sorts of whacky outcomes.
Tried with SSH aswell, and I get errors back on the SSH authentication (which is odd as there’s no password).
I spent afew hours trying to debug with chatGPT, to which got to a point where it seemed the command would be sent correctly as per debug, though no actual state change was made on the device. And expected feedback message from the device was different.
Does anyone have any pointers / suggestions to try and resolve this?
Very confused why I can send a basic string command in putty and it works perfectly but trying the same thing on node red just errors out.
Thanks!
Integrating node red with Google Classroom
I am a student who uses Notion for all my college work. I am looking at integrating Notion into node red, and I wondered if there is a way to integrate Google Classroom into node redt too, so I can use node red to create flows such as 'when assignment added to classroom, create task in database' with the title and date etc. I have already tried this in Pipedream and it works however I am limited to 3 workflows. Does anyone know of anyway to integrate Google Classroom to node red? I don't have much knowledge of coding however can try and teach myself if someone can explain the basics of how to create such an integration
I am trying to send a message using my lte modem (SIM A7670c) to cloud. I am interested in making use of the http protocol for achieving the same. I also set up a node red flow as shown below. I tried sending http request using the modem's at commands, but it responds with an error - 'connect socket failed'. To refine the issue to the modem or node red or server, I made use of MQTT protocol instead of HTTP and just replaced the 'http in' node in the flow to a 'mqtt in' flow. The message sent using at commands was received. So, I think its safe to presume that the modem is working just fine. Then, I used Postman to a HTTP request to the same url and I was able to notice the requests in the debug panel of the node red flow. I have also tried to send HTTP request from the modem to ThingSpeak instead of NodeRed and it works. But, how does this error occur when we try to connect the modem to node red. I have done multiple attempts and wasn't able to get over it. I have attached the AT commands I have used and also the http AT command list of the modem. Any views/ opinions on tackling this situation is welcome. TIA
I am a complete beginner with node-red, and have just started tinkering about with zigbee2mqtt and a couple handful sensors and lights.
I was wondering, what is the best practise when it comes to MQTT input?
Is it having a single input node listening to all messages in the zigbee2mqtt topic and then branches out and maybe connects to other flows?
or
Having multiple MQTT in nodes listening to only relevant topics for the flow it is placed in?
The reason I am asking is that I can see that node-red establishes separate connections per MQTT in node, which will result in many connections to the MQ server.
Hello all,
I am trying to store data from my p1 port of my electricity meter. This spits out data every second. This has 34 variables. Now I tried to put that in a csv file but after some time my pi zero 2 started to become very slow and not responding and accessible via the website. I had to pull the plug and restart and start node red in safe mode from putty. I checked the file and it is 17mb after 1 week or so. Is this (too) big? Does anyone have advise on how to store this data. Should I for example start a new file every day or is once a month enough? Thanks in advance.
Hi !
I plan to install a node-RED instance on an IOT2050 advance from Siemens in production.
On this device, the disk space is limited to 16GB.
What would be the best solution a node-RED docker container or a native installation ?
I plan to have the MQTT broker mosquitto, too.
I'm afraid that the docker would use more disk space. But on the other hand, I could create a backup image of the container (configuration + flows) which would be easier to deploy in case of crash.
I sure hope they get integrated in the version control? can you also connect it to github?
I'm very new to node red and home assistant in general, but my first project has been automating my IR ceiling fan with a zigbee IR blaster and a zigbee wall switch.
What I want:
- If I press the left switch, this toggles the light on and off (done)
- If I press the right switch, this turns on the ceiling fan at the speed it was on previously (value stored in a file, sends the right IR code as a payload based upon the value stored in file)
- If I press the right switch again while the fan is on, it sends the payload to the fan off button.
- If I press and hold the right switch, it cycles the value stored within the file.
I am not sure what is the best way to do these things in Node Red, can anyone please help a newbie out?
Hi there, I have a very simple flow that turns on/off a shelly (which my christmas lights are connected to) at certain time a day.
But the same outlets I use for my christmas lights are also used for other stuff during the year. Therefore I want a Switch in my Dashboard 2.0 that Basically allows the Time based activation to work or not to block it if the switch is turned off.
I think it is very easy to do with an "if (switch is on) then pass on the received function to the shelly; else dont do anything". But im to new to node red and json to actually implement it.
It would be great if you could help me out, probably done quickly for the pros :)
I left out my specific Shelly information, but the shelly is connected and works, I checked.
[
{
"id": "1ecb09b1a8e9c9f1",
"type": "function",
"z": "c3c9639b29b171fb",
"name": "0 on",
"func": "msg.payload = {\n method: \"Switch.Set\",\n parameters : {\n id : 0,\n on : true,\n \n }\n};\nreturn msg;",
"outputs": 1,
"timeout": "",
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 510,
"y": 160,
"wires": [
[
"46d8129945cd99ec"
]
]
},
{
"id": "9c07e75deb355aee",
"type": "function",
"z": "c3c9639b29b171fb",
"name": "0 off",
"func": "msg.payload = {\n method: \"Switch.Set\",\n parameters : {\n id : 0,\n on : false,\n }\n};\nreturn msg;",
"outputs": 1,
"timeout": "",
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 510,
"y": 240,
"wires": [
[
"46d8129945cd99ec"
]
]
},
{
"id": "f718049e4bd1c324",
"type": "inject",
"z": "c3c9639b29b171fb",
"name": "Switch on Timer",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "00 18 * * *",
"once": false,
"onceDelay": "",
"topic": "",
"payload": "Time",
"payloadType": "str",
"x": 310,
"y": 160,
"wires": [
[
"1ecb09b1a8e9c9f1"
]
]
},
{
"id": "211de484376b3b07",
"type": "shelly-gen2",
"z": "c3c9639b29b171fb",
"hostname": "",
"description": "",
"mode": "polling",
"verbose": false,
"server": "",
"outputmode": "event",
"uploadretryinterval": 5000,
"pollinginterval": 5000,
"pollstatus": false,
"getstatusoncommand": true,
"devicetype": "",
"devicetypemustmatchexactly": true,
"captureblutooth": false,
"outputs": 1,
"x": 890,
"y": 200,
"wires": [
[]
]
},
{
"id": "46d8129945cd99ec",
"type": "ui-switch",
"z": "c3c9639b29b171fb",
"name": "",
"label": "Its Christmas Time!",
"group": "",
"order": 0,
"width": 0,
"height": 0,
"passthru": false,
"decouple": false,
"topic": "topic",
"topicType": "msg",
"style": "",
"className": "",
"layout": "row-spread",
"clickableArea": "switch",
"onvalue": "true",
"onvalueType": "bool",
"onicon": "",
"oncolor": "",
"offvalue": "false",
"offvalueType": "bool",
"officon": "",
"offcolor": "",
"x": 690,
"y": 200,
"wires": [
[
"211de484376b3b07"
]
]
},
{
"id": "f13f10491e634e5b",
"type": "inject",
"z": "c3c9639b29b171fb",
"name": "Switch off Timer",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "00 00 * * *",
"once": false,
"onceDelay": "",
"topic": "",
"payload": "Time",
"payloadType": "str",
"x": 310,
"y": 240,
"wires": [
[
"9c07e75deb355aee"
]
]
}
]
Hello guys,
I need an advice from you. I think it will be easy to setup but I'm too bad with NodeRed to be able to build this.
Basically I need indication that my fish tank was fed in last 24 hours because my kids want to feed them too.
Flow will look like this:
When I press a button then diagram will check if this button was pressed in past 24 hours. If it was not pressed in past 24 hours then the light will blink once. If the button was pressed in past 24 hours then the light will blink twice.
So I will know if I can feed them or not.
Thank you for your help guys !!
Hello, I use nodered to activate the nest thermostat based on the temperature of a sensor I have in the bedroom. Do you know if:
Is there a way to create a virtual switch that shows in Homekit, by which I can turn on/off the flow?
Is there a way to create a virtual "setting button" that shows in Homekit, where I can change the temperature threshold in the node in nodered that triggers nest to switch on?
Thank you.
Hello,
I am looking into Nodered as a tool to collect data from several PLCs (mostly siemens S7 and allen bradley)
Here I have around 35 PLCs. this data would be then stored into a SQL database.
How well does nodered handle several PLCs? Do I need to create several flows/nodes, one for each plc?
Hi,
So I am going to need to have 2 Node red clients talk to eacher other across lan and across the web. the issue with that is i'd like to use wss (if that uses ssl) for over the web connections. I was told that wss would be easier to do then mqtt
Edit: sorry this didn't sound like a question I forgot to ask if It is possible to add ssl to the websockets in node red, I don't see an option for it
i really need it to change ui design
i get a buffer in read node of storage, i need to convert it to blob to make a post api call where key is "file" and blob is value in function. I got no solution. The file can be anything.
Actually, I need to make an POST API call with param "file" and "data". file should be "binary" and data should be "json". I need a flow for this. Can anyone help ?