Hi guys,
I am using Node-Red v3.0.2, Node.js v20.5.1 and node-red-node-serialport 1.0.4.
When I start Node-Red the connection works fine. As soon as I deploy Node-Red it tries to re-establish the serial connection. But this fails on every deploy because the port is supposedly not available. When I restart Node Red everything works as it should. It seems that Node Red is blocking the connection and cannot re-establish it. Does anyone have a solution to this problem?
*Welcome to Node-RED*
*===================*
*14 Aug 14:05:39 - [info] Node-RED version: v3.0.2*
*14 Aug 14:05:39 - [info] Node.js version: v20.5.1*
*14 Aug 14:05:39 - [info] Linux 5.15.0-78-generic x64 LE*
*14 Aug 14:05:39 - [info] Loading palette nodes*
*14 Aug 14:05:40 - [info] Dashboard version 3.5.0 started at /ui*
*14 Aug 14:05:40 - [info] Settings file : /home/app/.node-red/settings.js*
*14 Aug 14:05:40 - [info] Context store : 'default' [module=memory]*
*14 Aug 14:05:40 - [info] User directory : /home/app/.node-red*
*14 Aug 14:05:40 - [info] Projects directory: /home/app/.node-red/projects*
*14 Aug 14:05:40 - [info] Server now running at http://127.0.0.1:1880/admin/*
*14 Aug 14:05:40 - [info] Active project : Meilhaus_Steuerung*
*14 Aug 14:05:40 - [info] Flows file : /home/app/.node-red/projects/Meilhaus_Steuerung/flows.json*
*14 Aug 14:05:40 - [warn] Using unencrypted credentials*
*14 Aug 14:05:40 - [info] Starting flows*
*14 Aug 14:05:40 - [info] Started flows*
***14 Aug 14:05:40 - [info] [serialconfig:f1697cd44ae12613] serial port /dev/ttyUSB0 opened at 9600 baud 8N1***
***14 Aug 14:06:01 - [info] Stopping flows***
***14 Aug 14:06:01 - [info] serial port /dev/ttyUSB0 closed***
*14 Aug 14:06:01 - [info] Stopped flows*
*14 Aug 14:06:01 - [info] Updated flows*
*14 Aug 14:06:01 - [info] Starting flows*
*14 Aug 14:06:01 - [info] Started flows*
***14 Aug 14:06:01 - [error] [serialconfig:f1697cd44ae12613] serial port /dev/ttyUSB0 error: Error: Error Resource temporarily unavailable Cannot lock port***
*^C14 Aug 14:06:11 - [info] Stopping flows*
*14 Aug 14:06:11 - [info] serial port /dev/ttyUSB0 closed*
*14 Aug 14:06:11 - [info] Stopped flows*
*app@evndlegkk:~$ node-red* **(RESTART)**
*14 Aug 14:06:14 - [info]*
*Welcome to Node-RED*
*===================*
*14 Aug 14:06:14 - [info] Node-RED version: v3.0.2*
*14 Aug 14:06:14 - [info] Node.js version: v20.5.1*
*14 Aug 14:06:14 - [info] Linux 5.15.0-78-generic x64 LE*
*14 Aug 14:06:15 - [info] Loading palette nodes*
*14 Aug 14:06:15 - [info] Dashboard version 3.5.0 started at /ui*
*14 Aug 14:06:15 - [info] Settings file : /home/app/.node-red/settings.js*
*14 Aug 14:06:15 - [info] Context store : 'default' [module=memory]*
*14 Aug 14:06:15 - [info] User directory : /home/app/.node-red*
*14 Aug 14:06:15 - [info] Projects directory: /home/app/.node-red/projects*
*14 Aug 14:06:15 - [info] Server now running at http://127.0.0.1:1880/admin/*
*14 Aug 14:06:15 - [info] Active project : Meilhaus_Steuerung*
*14 Aug 14:06:15 - [info] Flows file : /home/app/.node-red/projects/Meilhaus_Steuerung/flows.json*
*14 Aug 14:06:15 - [warn] Using unencrypted credentials*
*14 Aug 14:06:15 - [info] Starting flows*
*14 Aug 14:06:15 - [info] Started flows*
***14 Aug 14:06:15 - [info] [serialconfig:f1697cd44ae12613] serial port /dev/ttyUSB0 opened at 9600 baud 8N1***
Best regards
Sebastian