node-red / node-red/node-red-nodes
serialport node hangs after some time (no input from/no output to serial device)
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.1k
- Forks
- 612
- Avg merge
- 13h 57m
- Merged PRs (30d)
- 3
Description
Which node are you reporting an issue on?
node-red-node-serialport
What are the steps to reproduce?
- Arduino Uno with sketch, that writes every 30 seconds sensor data via serial.write
- Arduino is connected via USB cable, Port is ACM0
- Arduino LED 13 blinks every second, so its possible to see if the controller is crashed or not
What happens?
After some time (30 minutes or 12 hours or 2 days, interval is not the same) in node-red is no data available.
The arduino LED 13 blinks.
To solve the problem its possible
- to disconnect the arduino for a short time (disconnect the usb cable, connect the cable)
- redeploy the flow
After that, everything is fine until the next crash.
In case of the "crash" there is via dmesg no entrie available, that the usb port is disconnected
What do you expect to happen?
It would be nice, if its possible to reset the serial connection via a node.
So its possible to create a flow to check the last time a message arrived. If > 60 seconds reset the connection.
Please tell us about your environment:
-
Node-RED version:
0.18.5 -
node.js version:
6.14.3 -
npm version:
3.10.10 -
Platform/OS:
Linux Debian Jessie -
Browser:
Chrome
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the node-red-node-serialport entry point and reproduce the hang using an Arduino Uno that sends sensor data every 30 seconds over ACM0. Compare the behavior before and after disconnecting/reconnecting the USB cable or redeploying the flow. Done means the serial connection can be reset through a node after messages stop arriving.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- embedded-iot
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100