Node-RED + fieldbus nodes
Debian with Node-RED and fieldbus nodes to exchange IO data with Real-Time Ethernet systems
The image provided hereunder deploys a container with installed Debian, Node-RED and two fieldbus nodes communicating with netPI RTE 3's onboard Industrial Network Controller netX to exchange IO data with connected Real-Time Ethernet networks.
Base of this image builds a tagged version of debian:stretch with installed Internet of Things flow-based programming web-tool Node-RED, two extra nodes fieldbus in and fieldbus out and a fieldbus IO configurator as web server application. The nodes initialize netX as PROFINET IO device or EtherNet/IP adapter (type of protocol configureable at container start) allowing the exchange of cyclic IO process data with PLCs such as Siemens S7 or Allen Bradley and your flow.
The container checks automatically whether it is running on a netPI RTE 3 or on a standard Pi with NHAT 52-RTE on top and loads the appropriate netX firmware accordingly.
To allow the access to the Node-RED programming over a web browser the container TCP port
1880 needs to be exposed to the host.
To grant access to the containerized fieldbus configurator web server application the container TCP port
9000 needs to be exposed to the host port
To grant access to the netX from inside the container the
/dev/spidev0.0 host device needs to be added to the container.
(If using a Pi make sure the device /dev/spidev0.0 is activated. If not use
raspi-config tool to enable it.)
The type of field network protocol loaded into netX is configured through the following variable
- FIELD with value
pnsto load PROFINET IO device or value
eisto load EtherNet/IP adapter network protocol
On netPI RTE 3
STEP 1. Open netPI's landing page under
https://<netpi's ip address>.
STEP 2. Click the Docker tile to open the Portainer.io Docker management user interface.
STEP 3. Enter the following parameters under Containers > Add Container
Host "1880" (any unused one) -> Container "1880"and
Host "9000" -> Container "9000"
Restart policy" :
Runtime > Env :
name "FIELD" -> value "pns" or "eis"
Runtime > Devices > add device:
Host "/dev/spidev0.0" -> Container "/dev/spidev0.0"
STEP 4. Press the button Actions > Start container
Pulling the image from Docker Hub may take up to 5 minutes.
On Pi + NHAT 52-RTE
STEP 1. Establish a console connection to Pi.
STEP 2. Install Docker if not already done, else skip.
STEP 3. Run a container instance of the image using the following command lines
PROFINET IO slave:
docker run -p 1880:1880 -p 9000:9000 --device=/dev/spidev0.0 -e "FIELD=pns"--restart=always hilschernetpi/netpi-nodered-fieldbus
docker run -p 1880:1880 -p 9000:9000 --device=/dev/spidev0.0 -e "FIELD=eis"--restart=always hilschernetpi/netpi-nodered-fieldbus
The container starts Node-RED automatically.
Open Node-RED in your browser with
http://<netPi ip address>:<mapped host port> (NOT https://) e.g.
http://192.168.0.1:1880. Use the two extra nodes fieldbus in and fieldbus out in the nodes library for exchanging process IO data with netX and the rest of your flow. The nodes' info tab explains how to use the nodes.
Use the electronic data sheets in the folder
electronic-data-sheets to feed your PLC/master engineering software with device related data.
In case of PROFINET please keep in mind that a virgin netX needs a PROFINET device name setup over the network as described here. Use your engineering software to assign a corresponding name (e.g."niotenpi351enrepns" which is default).
- hilscher/netPI-nodered-fieldbus:latest - non-versioned latest development output of the master branch. Can run on any netPI RTE 3 system software version or Pi with NHAT 52-RE module on top.
View the license information for the software in the Github project. As with all Docker images, these likely also contain other software which may be under other licenses (such as Bash, etc from the base distribution, along with any direct or indirect dependencies of the primary software being contained). As for any pre-built image usage, it is the image user's responsibility to ensure that any use of this image complies with any relevant licenses for all software contained within.
Hilscher Gesellschaft fuer Systemautomation mbH www.hilscher.com