Git Product home page Git Product logo

Comments (4)

ttlappalainen avatar ttlappalainen commented on August 12, 2024

On that function it uses default value for format and as I see declaration is
bool AddTimeField(double GPSTime, const char *Format="%09.2f");
Where do you have "%06f"

from nmea0183.

jmattioni avatar jmattioni commented on August 12, 2024

The reference is in function NMEA0183SetRMC, which I see doesn't use a format override. Sorry, I must have put the format override in the AddTimeField call myself. For GPRMC messages, most examples I've found don't include fractional seconds so the GPS time field length would always be 6 padded with zeros and no decimal. What was in my copy of the code was a format override of "%06f", which failed to pad zeros. I changed it to "%06.0f" and it worked.

from nmea0183.

ttlappalainen avatar ttlappalainen commented on August 12, 2024

Devices should also handle time given in 2 decimals.

RMC:
$--RMC,hhmmss.ss,A,ddmm.mm,a,dddmm.mm,a,x.x,x.x,xxxx,x.x,ahh
NMEA 2.3:
$--RMC,hhmmss.ss,A,ddmm.mm,a,dddmm.mm,a,x.x,x.x,xxxx,x.x,a,m
hh
NMEA 4.1:
$--RMC,hhmmss.ss,A,ddmm.mm,a,dddmm.mm,a,x.x,x.x,xxxx,x.x,a,m,s*hh

from nmea0183.

jmattioni avatar jmattioni commented on August 12, 2024

You're right. I just confirmed that the Yamaha 6Y80-01 square gauge on my bench works with the library default format.

Thanks.

from nmea0183.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.