This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
NodeRed stealing the data from SignalK
#1
I just tried Node Red for the first time. I installed it using the SignalK plugin.
I created a simple flow to take input from SignalK's environment.wind.angleApparent, environment.wind.speedApparent, environment.wind.speedTrue and environment.wind.directionTrue. The last two are calculated using the "derived data" plugin. I also convert a good amount of SignalK data to NMEA0183 using the corresponging plugin to later display it in OpenCPN.

It all worked beutifully in Node Red. I could filter the data to slow down the input to every 5 seconds. Very nice. Except suddenly I stopped receiving the NMEA0183 data in OpenCPN. Nothing. All stopped until I uninstalled Node Red then everything worked as before and I could see the NMEA0183 data.

I would like to use Node Red. It seems very powerful but I need my NMEA0183 in OpenCPN data as well.

Has anyone encountered this behaviour before?
Reply
#2
Hi shinken. Never seen that. Which nodes were you using? Is opencpn getting nmea from tcp port 10110?
Reply
#3
(2024-03-22, 08:51 AM)PaddyB Wrote: Hi shinken. Never seen that. Which nodes were you using? Is opencpn getting nmea from tcp port 10110?

I am using UDP to transfer the nmea stream.
I used the SignalK-input-handler node and the filter node, a function node to convert rad to deg and a debug node. Quite simple really.

Could the "derived data" plugin be competing with the Node Red plugin?
Reply
#4
(2024-03-22, 10:15 AM)shinken Wrote:
(2024-03-22, 08:51 AM)PaddyB Wrote: Hi shinken. Never seen that. Which nodes were you using? Is opencpn getting nmea from tcp port 10110?

I am using UDP to transfer the nmea stream.
I used the SignalK-input-handler node and the filter node, a function node to convert rad to deg and a debug node. Quite simple really.

Could the "derived data" plugin be competing with the Node Red plugin?

You could try TCP from port 10110 to get nmea, that's the default output from signalk. Is opencpn looking at the same UDP port maybe? 

[Image: Mne6DBh.png]
Reply
#5
I tried TCP 10110 but the folks over at OpenCPN recommended using UDP 2000. That connection works well and fast. At least when Node Red is not online.
Reply
#6
(2024-03-22, 12:45 PM)shinken Wrote: I tried TCP 10110 but the folks over at OpenCPN recommended using UDP 2000. That connection works well and fast. At least when Node Red is not online.

That's a sailing forum, not programming Wink , there a a few on there don't help.  TCP is the way to go, that's they way signalk is set up. AIS data is too important for UDP. Everyone using signalk (almost) uses TCP. It's there already coming out of signalk,  works fine & is reliable. Better to leave opencpn receiving nmea on tcp port 10110.  Node red can read from the same port with the settings above. No need to set up a UDP output in signalk. Give it a go, should work fine.  Cool
Reply
#7
Agree. TCP is easy, stable and bi-directional (you can send autopilot data calculated from OCPN back on the same connection). I can't imagine Node Red would be interrupting NMEA0183 data. I've used node red for years and never had any issues that I didn't cause myself.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)