Go Down

Topic: TinyGps++, sentences and gps questions (Read 295 times) previous topic - next topic

jcduino

Hello,

I am trying to make a gps signal viewer for the interface of a drone.

The graphical interface is in Processing and the gps data is acquired with an Arduino Mega and a Neo 6M gps card, specifically with a NEO-6M GY-GPS6MV2 that can be found on ebay or aliexpress.

It is not in motion, the data acquisition is static.

I use the good TinyGps++ library and I acquire most of the data without problems, but there is one piece of information that does not appear and I also have some doubts.

When I try to read the magnetic variation, the value does not appear, it appears blank, I use one of the examples that exist in the library and on the website. I do not know why it is, since if I want to get other data from the $GPRMC statement that I use, it does appear, but data 10 and 11 just appear blank. I thought that it could be the module that I use and that with the m7n or the m8n it could be requested, what do you think?

On the other hand I have doubts with the values โ€‹โ€‹of the $GPGSV and $GPGSA sentences. My idea is to show all the satellites in view on a circle N, E, S, W

The satellites that have a 0 signal in red, those that have a signal but are not used to triangulate the position (in green and those that have a signal and are being used to triangulate (used) white.

With this premise, I needed some clarification on each type of satellites.

With the $GPGSV statement, I acquire satellites in sight, that is, with or without a signal, in addition, if they appear as assets, they would be those that are being used to triangulate the signal, and if they are active, they should match values โ€‹โ€‹3-14 of the $GPGSA statement. Is that so?

Thanks for the feedback.

Regards.

srnet

When I try to read the magnetic variation, the value does not appear, it appears blank, I use one of the examples that exist in the library and on the website. I do not know why it is, since if I want to get other data from the $GPRMC statement that I use, it does appear, but data 10 and 11 just appear blank. I thought that it could be the module that I use and that with the m7n or the m8n it could be requested, what do you think?
Perhaps you will find the answer in the datasheet for your GPS ?
http://www.50dollarsat.info/
http://www.loratracker.uk/

Klaus_K

Did you print out the RAW serial messages from your GPS module to the Serial Monitor? If yes, could you post a couple of the messages, preferably after the module has been running for a while and found a couple of satellites. Make sure you include all of the message types that are send by the module.

It would also be helpful if you could include a link to the datasheet of your module, that way we can just look things up instead of searching for the datasheet first.

HillmanImp

I have a similar module and use TinyGPS++. The best way to examine the raw sentences is through the u-center software that can be downloaded from the u-blox site.

I see that on mine fields 10 & 11 in the RMC sentence are indeed empty.

I found two data spec documents for the module. I couldn't find any specification of the structure of the sentences. Best go by the Message View in u-center.

Perhaps the 6M model does not provide the magnetic deviation. How would it derive that I wonder. Anyone know?

Your interpretation of the satellite info in the GSV & GSA sentences makes sense.

John.

srnet

#4
May 24, 2020, 10:17 am Last Edit: May 24, 2020, 10:24 am by srnet
There are modelling systems that allow you to lookup magnetic declination (its normal name), you can look it up online;


Magnetic Declination


So presumably with certain base parameters from the GPS constallation the GPS works out the declination, when it knows its location.

UBLOX produce 'protocol' specification datasheets for their GPSs, whats included in each standard NMEA sentence and whats not is in there.  

Try a Google search on 'ublox 6 protocol datasheet'


http://www.50dollarsat.info/
http://www.loratracker.uk/

jcduino

Hi,

Did you print out the RAW serial messages from your GPS module to the Serial Monitor? If yes, could you post a couple of the messages, preferably after the module has been running for a while and found a couple of satellites. Make sure you include all of the message types that are send by the module.
These are the RAW sentences: (XXXXX.XXXXX are my position, omited).

$GPRMC,090901.00,A,XXXX.XXXXX,N,XXXXX.XXXXX,W,0.210,,240520,,,A*69
$GPVTG,,T,,M,0.210,N,0.389,K,A*22
$GPGGA,090901.00,XXXX.XXXXX,N,XXXXX.XXXXX,W,1,07,1.49,60.9,M,51.6,M,,*71
$GPGSA,A,3,31,14,29,06,02,12,25,,,,,,2.58,1.49,2.11*0F
$GPGSV,3,1,10,02,22,067,27,06,10,038,40,12,43,058,30,14,45,285,30*76
$GPGSV,3,2,10,24,21,126,21,25,72,027,30,26,04,261,18,29,56,175,25*7E
$GPGSV,3,3,10,31,30,305,40,32,48,248,*78
$GPGLL,XXXX.XXXXX,N,XXXXX.XXXXX,W,090901.00,A,A*72



There are modelling systems that allow you to lookup magnetic declination (its normal name), you can look it up online;


Magnetic Declination


So presumably with certain base parameters from the GPS constallation the GPS works out the declination, when it knows its location.

UBLOX produce 'protocol' specification datasheets for their GPSs, whats included in each standard NMEA sentence and whats not is in there. 

Try a Google search on 'ublox 6 protocol datasheet'
I don't know about the "protocol datasheet". I was looking for module datasheet and this don't help me, so thak's because it has been very helpful. I've find that if it's blank there is not supported.

Page 55 of the following document:

u-blox6-GPS-GLONASS-QZSS-V14_ReceiverDescrProtSpec

But, how can I find a module with magnetic declination support? I think I can't read all modules protocol datasheets.

srnet

But, how can I find a module with magnetic declination support? I think I can't read all modules protocol datasheets.
The UBLOX 6 is a fairly old UBLOX GPS, there have since been the 7 series and then the 8 series.

So maybe check the data sheet for a UBLOX 8 ?
http://www.50dollarsat.info/
http://www.loratracker.uk/

jcduino

#7
May 24, 2020, 01:08 pm Last Edit: May 24, 2020, 01:26 pm by jcduino
I've started with 7 and 8 series.

The 7 series said "Magnetic variation value (blank - not supported)" Only this, so...if I've lucky will work...

The 8/M8 series said "Magnetic variation value. Only supported in ADR 4.10 and later"
I've searched and the M8L have the ADR. This is a very specific and some expensive module.

Testing with my smartphone (Xiaomi mi 8 lite) I can see the magnetic declination in various apps. The phone is offline, no signal but gps. I can't believe my cheap smartphone have a $80 gps module. May be all apps I test have a modelling system saved in the phone memory. May be I can try the NOAA World Magnetic Model Coefficients https://www.ngdc.noaa.gov/geomag/WMM/soft.shtml, Do you know a arduino library for integrate it?

I think I can buy a M8N for testing, it's not a big money lost.

srnet

I think I can buy a M8N for testing, it's not a big money lost.
Yes, they are relativly low cost.

I have one here, it has an M8N label on it, but the firmware reports its a M7 with June 2012 firmware.

Maybe why that why they are low cost.


If you want a GPS with specific providence, be prepared to pay for it from a known trusted supplier.




http://www.50dollarsat.info/
http://www.loratracker.uk/

HillmanImp

Try putting your queries to the u-blox forum:

https://portal.u-blox.com/s/

There are extremely knowledgeable people there who will be able to help.

If the receiver uses a stored model, then perhaps you can find the declination for your position. Would it not be constant?

John.

srnet

Would it not be constant?
Not a constant as such, it does change at a slow rate.

Its moved about 7 degrees in 40 years in the UK. 
http://www.50dollarsat.info/
http://www.loratracker.uk/

CrossRoads

Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

srnet

When the declination reaches 0degrees where I live, I think a 'Declination Day' party is required.
http://www.50dollarsat.info/
http://www.loratracker.uk/

Klaus_K

$GPRMC,090901.00,A,XXXX.XXXXX,N,XXXXX.XXXXX,W,0.210,,240520,,,A*69
As you can see in the message, there is no magnetic declination value in the data. It should be at the end before the checksum. And there is a good reason. See below

But, how can I find a module with magnetic declination support? I think I can't read all modules protocol datasheets.
I looked at the magnetic declination information.

If there is a module with magnetic declination support, it would need to be able to get regular updates. The declination is simply calculated from the position using a map/model. This would need to be supported by the manufacturer. Unless this is an often-used feature, I doubt GPS module manufacturers like this. Sounds like a support burden to me. They would need to provide regular software updates and help their customers when the updates create issues. These companies want to build silicon. It also costs a lot of memory to store the model data which could be used for more valuable features.

Because you said you are writing a processing app, I suspect it will be better to do this in your app. For instance, you could have a look at the following web page. It states

Quote
The calculator provides an easy way for you to get results in HTML, XML, CSV, or JSON programmatically (API).
https://www.ngdc.noaa.gov/geomag/calculators/magcalc.shtml#declination

The following python program on Github might be useful as well to figure out how the API works.

https://gist.github.com/kevana/7079081

Go Up