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
NMEA into KPLEX from node-red?
#1
How do I do that? Tried every combination of ports & ip address I can think of but nothing shows up in the diagnostic window. NMEA message is from another thread - $WIMWV,28,R,4.7,N,A*04

Node-red - 
Code:
[
   {
       "id": "eb4147d4.73a6d8",
       "type": "inject",
       "z": "3f30ea31.da3756",
       "name": "",
       "topic": "",
       "payload": "$WIMWV,28,R,4.7,N,A*04",
       "payloadType": "str",
       "repeat": "1",
       "crontab": "",
       "once": false,
       "onceDelay": 0.1,
       "x": 220,
       "y": 1380,
       "wires": [
           [
               "137d8646.f9660a"
           ]
       ]
   },
   {
       "id": "137d8646.f9660a",
       "type": "function",
       "z": "3f30ea31.da3756",
       "name": "",
       "func": "msg.payload =  msg.payload + \"\\n\";\nreturn msg;",
       "outputs": 1,
       "noerr": 0,
       "x": 480,
       "y": 1420,
       "wires": [
           [
               "5c27d805.90e408"
           ]
       ]
   },
   {
       "id": "5c27d805.90e408",
       "type": "udp out",
       "z": "3f30ea31.da3756",
       "name": "",
       "addr": "10.10.10.1",
       "iface": "",
       "port": "6666",
       "ipv": "udp4",
       "outport": "",
       "base64": false,
       "multicast": "false",
       "x": 680,
       "y": 1440,
       "wires": []
   }
]


KPLEX -

Code:
pi@openplotter:~ $ cat .kplex.conf
# For advanced manual configuration, please visit: http://www.stripydog.com/kplex/configuration.html
# Please do not modify defaults nor OpenPlotter GUI settings.
# Add manual settings at the end of the document.

###defaults

[udp]
name=system_a
direction=in
address=localhost
port=10110

[udp]
name=system_b
direction=in
port=10110

[tcp]
name=opencpn
direction=out
mode=server
ofilter=-**RMB
port=10109

[udp]
name=signalk
direction=out
ofilter=-OC***
address=127.0.0.1
port=55556

###end of defaults

###OpenPlotter GUI settings

[serial]
name=gps
direction=in
optional=yes
filename=/dev/ttyUSB0
baud=4800

[serial]
name=ais
direction=in
optional=yes
filename=/dev/ttyUSB1
baud=38400

[udp]
name=node
direction=in
optional=yes
address=10.10.10.1
port=6666

[udp]
name=tablet
direction=in
optional=yes
address=10.10.10.1
port=50000

###end of OpenPlotter GUI settings

###Manual settings
Reply
#2
found this haven't tried yet let me know if it works

http://forum.openmarine.net/showthread.p...949#pid949
Reply
#3
(2018-06-05, 07:29 PM)jim321 Wrote: found this haven't tried yet let me know if it works

http://forum.openmarine.net/showthread.p...949#pid949

Thanks, that works, and helps a lot or something else i was looking at  but not for this..

Still can't get a NMEA essage from node red into KPLEX.  I have a tablet running an app called shareGPS which is set to send NMEA gps  messages to 10.10.10.1 port 50000 - works fine, streaming GPS NMEA messages in the diagnostic for a UDP in set to 10.10.10.1 port 50000. 
I turn that app off then from node red on a laptop run your linked node red tweaked a little - works fine as well, signalk being seen on openplotter. 

Send a copied GPS nmea sentence to 10.10.10.1 50000 (with added \n) and nothing in diagnostic. Turn off that entry in openplotter and the message shows up in node-red on the Pi. So getting to the Pi, just not showing up in KPLEX. 

Odd....
Reply
#4
Got there in the end, that took a bit of trial and error  Smile

So to send an NMEA message from either node-red or an ESP8266 over UDP the message needs both a carriage return and linefeed - $NMEA_MESSAGE\r\n



"$GPRMC,191224,A,3701.281205,N,00756.662889,W,0.0,,050618,0.0,W,A*34\r\n"
Reply
#5
cool i kept failing at it i was starting to think of sending to a virtual serial port...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)