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
SeaTalk 1 to NMEA0183/2000 with Raspberry Pi
#14
ÍI’ve been playing for a while with the STALK_read.py trying to make my ST2000+ work with the autopilot app without success. Also tried the new standard signalk connection. I’ve found that the 9c seatalk1 datagram gets translated to signalk but not the 84 that reports autopilot state.

This is one example taken from my device:

$STALK,84,56,e,0,0,0,0,0,8*0F

I tried even pasting it into the Data Fiddler but it didn’t translate into any delta. I also installed the nmea signalk parser and got the same result so i did a step trace debug of the code and found that when it parses for the values of:

[U, VW, V, XY, Z, M, RR, SS, TT]

I get this results:

[ 5, 14, 14, 0, NaN, NaN, 0, 0, 8 ]

And the function returns a null after finding the NaNs

Those values are parsed like this:

  var Z = parseInt(parts[4].charAt(1), 16)
  var M = parseInt(parts[5].charAt(1), 16)

After this finding i tried the following modified datagram adding some zeros:

$STALK,84,56,e,00,00,00,00,00,8*3F

And the translation worked in both command line parser and data fiddler.

In conclusion I see two posible solutions, modify the STALK_read.py code to add the additional zeros or modify the parser so it can parse the single 0 correctly (I guess charAt(0)).

If anybody can guide me to the location of the files on sk server and which solution will be more suitable I can try making the changes, test and report the final solution.

Best regards,
Cari20
Reply


Messages In This Thread
RE: SeaTalk 1 to NMEA0183/2000 with Raspberry Pi - by Cari20 - 2020-08-25, 05:48 AM

Forum Jump:


Users browsing this thread: 2 Guest(s)