OpenMarine
Signal K and VWT sentence (True Wind) - Printable Version

+- OpenMarine (https://forum.openmarine.net)
+-- Forum: OpenPlotter (https://forum.openmarine.net/forumdisplay.php?fid=1)
+--- Forum: How do I...? (https://forum.openmarine.net/forumdisplay.php?fid=3)
+--- Thread: Signal K and VWT sentence (True Wind) (/showthread.php?tid=2599)



Signal K and VWT sentence (True Wind) - we9v - 2020-05-22

Searched for anything "VWT" in the forum, and couldn't find anything, so here it goes:

Signal K doesn't seem to accept my wind instruments VWT sentence.  Specifically, here's an example:
$IIVWT,38,R,10.1,N,5.1,M,18.7,K*60

When putting that into the SK Data Fiddler, there are no complaints, but also no deltas.  I've also erased the checksum, but that doesn't change SK.

As SK passes all NMEA0183 to 10110, OpenCPN and qtVlm have no problem displaying the True Wind angle and speed.

My goal is to display, and log into InfluxDB, true wind angle (relative to boat) and speed, as well as calculate, display and log true wind direction (compass direction) and speed.  How can I accomplish this?  (My wind instruments calculate and show true wind compass direction as well, but it does not produce a MWD sentence.)

Thanks,
Chad
S/V Kookaburra


RE: Signal K and VWT sentence (True Wind) - we9v - 2020-05-22

I see now that there's a signalk-derived-data plugin to generate these things from my other existing data, but the question still remains as to why Signal K doesn't process my VWT sentence.


RE: Signal K and VWT sentence (True Wind) - PaddyB - 2020-05-22

Vwt is an odsolete sentence though a few programs still seem to recognize it. You could probably change it into something signalk recognises in node red though the derived data can probably do just the same thing.


Signal K and VWT sentence (True Wind) - tkurki - 2020-05-24

The answer is the same as to the often heard question ”why doesn’t open source software x support y”: because nobody has written the code needed to do that.

The list of supported sentences is at https://github.com/SignalK/signalk-parser-nmea0183/tree/master/hooks


Sent from my iPhone using Tapatalk


RE: Signal K and VWT sentence (True Wind) - PaddyB - 2020-05-25

here's a little node-red which sends your VWT speed to environment/wind/speedTrue and angle to environment/wind/angleTrueGround, should work Smile  >


Code:
[
   {
       "id": "485c6a6a.b30564",
       "type": "tcp in",
       "z": "1ffaa926.033937",
       "name": "",
       "server": "client",
       "host": "10.10.10.1",
       "port": "10110",
       "datamode": "stream",
       "datatype": "utf8",
       "newline": "",
       "topic": "",
       "base64": false,
       "x": 220,
       "y": 640,
       "wires": [
           [
               "3141d807.47a188"
           ]
       ]
   },
   {
       "id": "3141d807.47a188",
       "type": "switch",
       "z": "1ffaa926.033937",
       "name": "Filter just pressure",
       "property": "payload",
       "propertyType": "msg",
       "rules": [
           {
               "t": "regex",
               "v": "^(?=.*IIVWT)",
               "vt": "str",
               "case": false
           }
       ],
       "checkall": "true",
       "repair": false,
       "outputs": 1,
       "x": 290,
       "y": 720,
       "wires": [
           [
               "44800ded.615034",
               "c5daff41.52d96"
           ]
       ]
   },
   {
       "id": "44800ded.615034",
       "type": "function",
       "z": "1ffaa926.033937",
       "name": "",
       "func": "msg.split = msg.payload.split(',');\nmsg.angle = msg.split[1] * 3.14 / 180;\nmsg.speed = msg.split[5];\nif (msg.split[2] != 'R') {\n    msg.angle = msg.angle * -1;\n}\nmsg.topic = 'environment/wind/angleTrueGround'\nmsg.payload = msg.angle;\nreturn msg;",
       "outputs": 1,
       "noerr": 0,
       "x": 500,
       "y": 680,
       "wires": [
           [
               "1f3f4db4.1f3cf2"
           ]
       ]
   },
   {
       "id": "c5daff41.52d96",
       "type": "function",
       "z": "1ffaa926.033937",
       "name": "",
       "func": "msg.split = msg.payload.split(',');\nmsg.angle = msg.split[1] * 3.14 / 180;\nmsg.speed = msg.split[5];\nif (msg.split[2] == 'R') {\n    msg.angle = msg.angle * -1;\n}\nmsg.topic = 'environment/wind/speedTrue'\nmsg.payload = msg.speed;\nreturn msg;",
       "outputs": 1,
       "noerr": 0,
       "x": 510,
       "y": 740,
       "wires": [
           [
               "10c8a381.61f7fc"
           ]
       ]
   },
   {
       "id": "1f3f4db4.1f3cf2",
       "type": "signalk-send-pathvalue",
       "z": "1ffaa926.033937",
       "name": "",
       "source": "",
       "x": 830,
       "y": 680,
       "wires": []
   },
   {
       "id": "10c8a381.61f7fc",
       "type": "signalk-send-pathvalue",
       "z": "1ffaa926.033937",
       "name": "",
       "source": "",
       "x": 810,
       "y": 740,
       "wires": []
   }
]



RE: Signal K and VWT sentence (True Wind) - we9v - 2020-05-25

(2020-05-25, 03:38 AM)PaddyB Wrote: here's a little node-red which sends your VWT speed to environment/wind/speedTrue and angle to environment/wind/angleTrueGround, should work Smile 
Thanks!  This will also help me understand node red a bit more.