Page 1 of 1

Affichage incorrect sur mon répéteur GPS du COG

Posted: Sat Sep 24, 2022 1:11 pm
by joel66
Bonjour,
J'ai un problème d'affichage du COG sur mon répéteur GPS Autohelm sur bus Seatalk.
C'est correct sur les COG de 0 à 90 mais au delà il n'affiche pas le bon COG.
J'ai le traceur GPS TRACKER 5600 en P1 , l'émetteur AIS en P2 ( éteint pour simplifier la trace) et un bus Seatalk avec le sondeur , la girouette, le répéteur GPS, le pilote automatique .
Je vous joins la trace du Nmea3wifi en mode Débug.
Dans cette trace on voit que pour les phrases reçus RMC et VTG de P1, il manque la valorisation du deuxième octet de ST53 tel que le présente une doc extraite de Thomas Knauf

53 U0 VW Course over Ground (COG) en degrés :
Les deux bits inférieurs de U * 90 +
les six bits inférieurs de VW * 2 +
les deux bits supérieurs de U / 2 =
(U & 0x3) * 90 + (VW & 0x3F) * 2 + (U & 0xC) / 8




Merci d'avoir l'amabilité d'analyser ce problème.
Cordialement.
Joël

Re: Affichage incorrect sur mon répéteur GPS du COG

Posted: Sun Sep 25, 2022 7:20 pm
by verizzen
this is how i parsed the COG on my PC using a direct connection with a wired seatalk interface .
it work well for all angle of COG

Maybe it can help the developpers of the nmea wifi 3.

it is C# in ,net microsoft language.
buffer Databuffer CONTAINS THE 0X53 DATAGRAM STATING AT INDEX 0
//53 U0 VW Course over Ground(COG) in degrees:
//The two lower bits of U *90 +
//the six lower bits of VW * 2 +
//the two higher bits of U / 2 =
//(U & 0x3) * 90 + (VW & 0x3F) * 2 + (U & 0xC) / 8
//The Magnetic Course may be offset by the Compass Variation
else if (Databuffer == 0x53)
{
if (CurrentDataIndex - i < 3)
continue;

h1 = (int)Databuffer[i + 1];
if ((h1 & 0x0f) != 0x00)
continue;
h1 = h1 >> 4;
XX = (h1 & 0x03) * 90;

h2 = (int)Databuffer[i + 2];
h2 = (h2 & 0x3f) * 2;
float mYY = (float)h1 /(float)8.0;
COG = (float)(XX + h2 + mYY);
i += 1;
continue;
}

Re: Affichage incorrect sur mon répéteur GPS du COG

Posted: Wed Oct 12, 2022 1:06 am
by Luis Sa
Hello Joel and Verizon,

I am sorry but these posts did not reach my attention until today. Will try to look at it and will come back here.

Regards, Luis

Re: Affichage incorrect sur mon répéteur GPS du COG

Posted: Wed Oct 12, 2022 9:34 am
by dagnall
Joel, Verizzen.
I must also apologise. I had discovered and corrected that bug in some updated code Luis and I called "V16", but we failed to publish it in the Binary updates for NMEA3.
The code corrects the bad COG in ST53 and also bad XTE in datagram 85.
It also adds an automated (RMC/GPS)COG to (SeaTalk_ST20) STW conversion feature that a user requested. (this switches off if the "proper" SEATALK STW (ST20/ST26) are ever seen.
We had passed this to that user for test, but failed to make it generally available.

There are a couple of other bugs associated with sending waypoints to the autohelm in seatalk format that we have also corrected, but that took a lot longer and we hope to soon update NMEA3WIFI to V17, but testing takes time..

Unfortunately this part of the forum will not accept pure .bin files, so I have zipped NMEA3WIFIV16.bin and attached it.
I am sure that very soon Luis will have the file in the "proper" NMEA3 Binaries update section.

Please let me know if you find any other bugs!

Best regards Dagnall

Re: Affichage incorrect sur mon répéteur GPS du COG

Posted: Wed Oct 12, 2022 9:37 pm
by Luis Sa
Hello Verizon,

You created a post under the announcement forum of the Nmea3Wifi Multiplexer. I should had that forum blocked. So, I copied here your question and Dagnall's response:

You wrote on Fri Sep 23, 2022 11:23 pm:
  • IS it possible to send receive nmea/seatalk data using a PC wired connexon via com port to the multiplexer wifi 3 ??
Dagnall answered on Wed Oct 12, 2022 5:54 pm:
  • Yes.
    NMEA 3's "Port1" can be set to receive data from the NMEA3 USB, or can be used as a normal serial com port.

    I use this for testing. I can send NMEA formatted messages out from my PC USB port, and the NMEA3 will convert them to Seatalk.
    You can also "see" any Seatalk on the USB, which "mirrors" the "P3" serial output.

    But please be aware that the small USB connector can be easily damaged, so make sure that you are careful connecting and disconnecting it.

    Hope this helps.
    And sorry for delay in response.
    Dagnall
I am sorry but that was the only way I had to clean the announcement forum,

Regards, Luis