I am using THIS article and example for testing my gps.
And first of all I must say that program is really great, but of course I need some help.
FIRST
So what I need is to get coordinates in a “normal” (normal for my knowledge) European format for example in decimal as 16,445554477 something…
Here I get degrees which is nice but I need it in decimal values. And when I tried put decimal values that I got in this program I don’t know how to use them as I am not familiar with this format. For example I got 5600,35568 something… I don’t know how to represent it in google maps.
SECOND
I am recording data from gps into database. Problem is that I get 2-4 records in one second. How to make it to one data per second? I have tried to look in the code but no success.
THIRD – and the last
Is how to implement this data from first question into Google maps API v3?
First question is the main one. Other two are only if someone knows what to do.
I am sure that lot of people are having same issues as I am.
And of course there is many people that solved this “problems”.
So give me some examples please.
Have a nice coding 🙂
Cheers!
First
You need to parse your NMEA string, and the string you should be interested in is RMC
This has the information for Latitude and Longitude. To convert them from degree to x y coordinate check this thread. Once you convert them to X Y coordinate using WGS84, you would be able to use them in Google maps.
Second
Usually GPS data receiving interval is 1 (one) second. I am not sure how are you getting 2-4 records in a second. But I would suggest you to use a timer and fetch record after each second and only store the one you need, like in your case you need to store location based data which is available in GPRMC string. Please check this link Writing Your Own GPS Applications: Part 2
Third
If you want to display position based on the first question in the google maps, you will find lots of help on Google Maps API. I haven’t work with this API, but I have worked with android.