I am using Particle device and neo-6m GPS which does give me values for both longitude and lattitude. However, the values appear to be too high and different from ones that are accepted by google. I’m thinking they might need to be converted in some way?
The values that are output are;
Latitude: 5555.8287
Longitude: 302.4025
The values accepted by google and what they should be close to are
Latitude: 55.53
Longitude: 302
I understand this isn’t specifically a Particle Argon issue but i was hoping someone may have came across this and can guide me. I think by the looks of these figures they need some kind of conversion?
You didn't mention which library you are using for the GPS. It looks like it's passing the direct value from the GNSS NEMA messages.
29.1.5 Latitude and Longitude Format
According to the NMEA Standard, Latitude and Longitude are output in the format Degrees, Minutes and (Decimal) Fractions of Minutes. To convert to Degrees and Fractions of Degrees, or Degrees, Minutes, Seconds and Fractions of seconds, the 'Minutes' and 'Fractional Minutes' parts need to be converted. In other words: If the GPS Receiver reports a Latitude of 4717.112671 North and Longitude of 00833.914843 East, this is
Latitude 47 Degrees, 17.112671 Minutes
Longitude 8 Degrees, 33.914843 Minutes
Latitude 47.28521118 Degrees
Longitude 8.56524738 Degrees
In other words, the raw output from the GNSS is degrees and minutes in the whole part and fractional minutes in the decimal part, so if you want degrees and fractional degrees you'll need to convert it as above.
@paul41, to be honest I’m not sure why you don’t use the TinyGPS++ library which does all that parsing and conversions for you. The Particle-GPS library makes extensive use of Strings which are known to create heap fragmentation problems.