Archive for the ‘Node-RED’ Category

Node-RED Version 3.1.0 – auf einem Raspberry Pi Zero W ‚running as a service‘

Dienstag, November 21st, 2023
pi@rpi-NodeRed-01:~ $
pi@rpi-NodeRed-01:~ $  bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)
Running Node-RED update for user pi at /home/pi on raspbian
This can take 20-30 minutes on the slower Pi versions – please wait.
Stop Node-RED ✔
Remove old version of Node-RED ✔
Remove old version of Node.js ✔
Install Node.js for Armv6 ✔ v18.18.2 Npm 9.8.1
Clean npm cache ✔
Install Node-RED core ✔ 3.1.0
Move global nodes to local –
Npm rebuild existing nodes ✔
Install extra Pi nodes –
Add shortcut commands ✔
Update systemd script ✔
Any errors will be logged to /var/log/nodered-install.log
All done.
You can now start Node-RED with the command node-red-start
or using the icon under Menu / Programming / Node-RED
Then point your browser to localhost:1880 or http://{your_pi_ip-address}:1880
Started : Wed 15 Nov 15:52:28 CET 2023
Finished: Wed 15 Nov 16:03:43 CET 2023
**********************************************************************************
### WARNING ###
DO NOT EXPOSE NODE-RED TO THE OPEN INTERNET WITHOUT SECURING IT FIRST
Even if your Node-RED doesn’t have anything valuable, (automated) attacks will
happen and could provide a foothold in your local network
Follow the guide at https://nodered.org/docs/user-guide/runtime/securing-node-red
to setup security.
### ADDITIONAL RECOMMENDATIONS ###
– Remove the /etc/sudoers.d/010_pi-nopasswd file to require entering your password
when performing any sudo/root commands:
sudo rm -f /etc/sudoers.d/010_pi-nopasswd
– You can customise the initial settings by running:
node-red admin init
– After running Node-RED for the first time, change the ownership of the settings
file to ‚root‘ to prevent unauthorised changes:
sudo chown root:root ~/.node-red/settings.js
**********************************************************************************
Would you like to customise the settings now (y/N) ? y
Node-RED Settings File initialisation
=====================================
This tool will help you create a Node-RED settings file.
✔ Settings file · /home/pi/.node-red/settings.js
✔ Do you want to setup user security? · Yes
✔ Username · pi
✔ Password · *******************
✔ User permissions · full access
✔ Add another user? · No
Projects
========
The Projects feature allows you to version control your flow using a local git repository.
✔ Do you want to enable the Projects feature? · No
Flow File settings
==================
✔ Enter a name for your flows file · flows.json
✔ Provide a passphrase to encrypt your credentials file · ********
Editor settings
===============
✔ Select a theme for the editor. To use any theme other than „default“, you will need to install @node-red-contrib-themes/theme-collec tion in your Node-RED user directory. · default
✔ Select the text editor component to use in the Node-RED Editor · monaco (default)
Node settings
=============
✔ Allow Function nodes to load external modules? (functionExternalModules) · Yes
Settings file written to /home/pi/.node-red/settings.js
pi@rpi-NodeRed-01:~ $
pi@rpi-NodeRed-01:~ $ sudo systemctl enable nodered.service
Created symlink /etc/systemd/system/multi-user.target.wants/nodered.service → /lib/systemd/system/nodered.service.
pi@rpi-NodeRed-01:~ $

pi@rpi-NodeRed-01:~ $ sudo systemctl status nodered.service
● nodered.service – Node-RED graphical event wiring tool
Loaded: loaded (/lib/systemd/system/nodered.service; enabled; vendor preset: enabled)
Active: active (running) since Wed 2023-11-15 16:18:07 CET; 8min ago
Docs: http://nodered.org/docs/hardware/raspberrypi.html
Main PID: 255 (node-red)
Tasks: 11 (limit: 414)
CPU: 49.789s
CGroup: /system.slice/nodered.service
└─255 node-red
Nov 15 16:20:19 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:19 – [info] Settings file : /home/pi/.node-red/settings.js
Nov 15 16:20:19 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:19 – [info] Context store : ‚default‘ [module=memory]
Nov 15 16:20:19 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:19 – [info] User directory : /home/pi/.node-red
Nov 15 16:20:19 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:19 – [warn] Projects disabled : editorTheme.projects.enabled=false
Nov 15 16:20:19 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:19 – [info] Flows file : /home/pi/.node-red/flows.json
Nov 15 16:20:19 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:19 – [info] Creating new flow file
Nov 15 16:20:19 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:19 – [warn] Encrypted credentials not found
Nov 15 16:20:21 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:21 – [info] Server now running at http://127.0.0.1:1880/
Nov 15 16:20:21 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:21 – [info] Starting flows
Nov 15 16:20:21 rpi-NodeRed-01 Node-RED[255]: 15 Nov 16:20:21 – [info] Started flows
pi@rpi-NodeRed-01:~ $
pi@rpi-NodeRed-01:~ $ node-red-log
Started Node-RED graphical event wiring tool.
15 Nov 16:19:03 – [info]
Welcome to Node-RED
===================
15 Nov 16:19:03 – [info] Node-RED version: v3.1.0
15 Nov 16:19:03 – [info] Node.js version: v18.18.2
15 Nov 16:19:03 – [info] Linux 6.1.21+ arm LE
15 Nov 16:19:42 – [info] Loading palette nodes
15 Nov 16:20:19 – [info] Settings file : /home/pi/.node-red/settings.js
15 Nov 16:20:19 – [info] Context store : ‚default‘ [module=memory]
15 Nov 16:20:19 – [info] User directory : /home/pi/.node-red
15 Nov 16:20:19 – [warn] Projects disabled : editorTheme.projects.enabled=false
15 Nov 16:20:19 – [info] Flows file : /home/pi/.node-red/flows.json
15 Nov 16:20:19 – [info] Creating new flow file
15 Nov 16:20:19 – [warn] Encrypted credentials not found
15 Nov 16:20:21 – [info] Server now running at http://127.0.0.1:1880/
15 Nov 16:20:21 – [info] Starting flows
15 Nov 16:20:21 – [info] Started flows
pi@rpi-NodeRed-01:~ $
pi@rpi-NodeRed-01:~ $ node-red-restart
Restarted Node-RED
pi@rpi-NodeRed-01:~ $

A a set of dashboard nodes for Node-RED – to install the stable version use the Menu -> Manage palette option and search for node-red-dashboard

Node-RED – Dashboard Notifications

Sonntag, November 19th, 2023

Node-RED ’node-red-contrib-fritzapi‘ – home automation node for Fritz!Box Fritz!DECT and FRITZ!Powerline devices

Sonntag, November 19th, 2023

Control your smart home DECT devices through an AVM Fritz!Box with node-RED ’node-red-contrib-fritzapi‘ API

Node-RED – how to adjust the settings of your ui-slider dynamically

Sonntag, November 19th, 2023

Node-RED – how to style a custom Dashboard

Freitag, November 17th, 2023

Node-RED Version 3.1.0 – auf einem Raspberry Pi Zero W ‚running locally‘

Dienstag, November 14th, 2023
root@rpi-NodeRed-01:~#
root@rpi-NodeRed-01:~# bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)
Running Node-RED install for user root at /root on raspbian
This can take 20-30 minutes on the slower Pi versions – please wait.
Stop Node-RED ✔
Remove old version of Node-RED ✔
Remove old version of Node.js ✔
Install Node.js for Armv6 ✔ v18.18.2 Npm 9.8.1
Clean npm cache ✔
Install Node-RED core ✔ 3.1.0
Move global nodes to local –
Npm rebuild existing nodes ✔
Install extra Pi nodes ✔
Add shortcut commands ✔
Update systemd script ✔
Any errors will be logged to /var/log/nodered-install.log
All done.
You can now start Node-RED with the command node-red-start
or using the icon under Menu / Programming / Node-RED
Then point your browser to localhost:1880 or http://{your_pi_ip-address}:1880
Started : Mon 13 Nov 16:41:25 CET 2023
Finished: Mon 13 Nov 16:55:20 CET 2023
root@rpi-NodeRed-01:~#

Due to the limited memory of the Raspberry Pi Zero W you will need to start Node-RED with an additional argument to tell the underlying Node.js process to free up unused memory sooner than it would otherwise

root@rpi-NodeRed-01:~# node-red-pi –max-old-space-size=256

Node-RED ’node-red-contrib-shelly‘ – how to turn on and turn off a shelly switch

Montag, November 13th, 2023

This package contains nodes for controlling shelly devices via the following Node-RED ’node-red-contrib-shelly‘ API

Node-RED – powerfox poweropti basic flow for home assistant

Sonntag, November 12th, 2023

Proxmox Virtual Environment (VE) 7.3.4 – Installation von NodeRed #14

Freitag, Januar 6th, 2023

NodeRED – Read and Write Data To a File

Mittwoch, Dezember 7th, 2022

NodeRED – you want to parse CSV data to work with the values it contains

Mittwoch, Dezember 7th, 2022

my-PV ELWA Modbus Interface – fungiert als Bindeglied zwischen der autarken ELWA und einem Modbus Bussystem

Sonntag, Dezember 4th, 2022

Node-RED 3.0 – Dashboard Template Dropdown

Dienstag, August 23rd, 2022

Shelly & Tasmota – mit MQTT Node-Red InfluxDB in ein Grafana Dashboard

Freitag, August 19th, 2022

Node-RED 3.0 – what’s new

Samstag, Juli 16th, 2022