?
Solved

Logging GPS Data

Posted on 2005-03-23
11
Medium Priority
?
752 Views
Last Modified: 2009-07-29
I have a Pharos GPS unit (which I bought with Microsoft Streets and Trips 2005) and I want to log my gps data (NMEA sentences) to my laptop for some routes I use.  I need to find some software to do this (I know there has to be some free VB or C++ program to do such a thing).  I also have Delorme Street Atlas USA 2005 that does logging but it is their .gpl extension.  I found some software to convert the .gpl file to NMEA sentence but it didn't appear to work....

Here is what I got with it:
======================================================================================

$GPGGA,114853,3450.729,N,08240.572,W,04,0,0,0.000,M,0.0,M,,*71
$GPGGA,114853,3450.729,N,08240.572,W,04,0,0,0.000,M,0.0,M,,*71
$GPGGA,114853,3450.729,N,08240.572,W,04,0,0,0.000,M,0.0,M,,*71
$GPGGA,114853,3450.729,N,08240.572,W,04,0,0,0.000,M,0.0,M,,*71
$GPGGA,114853,3450.729,N,08240.572,W,04,0,0,0.000,M,0.0,M,,*71
$GPGGA,114853,3450.729,N,08240.572,W,04,0,0,0.000,M,0.0,M,,*71

======================================================================================

I know what all the positions are supposed to mean but 3450.729,08240.572 is not a valid lat/long.

Basically what I want is some software to log the correct NMEA sentences using my USB Pharos unit.

Thanks

r2
0
Comment
Question by:r270ba
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 4
11 Comments
 

Author Comment

by:r270ba
ID: 13615156
Ok I actually found some software to do what I want but it is still giving me sentences like

3450.729,N,08240.572,W

How do I convert that to at Lat./Long.?
0
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 13615252
Those are really latitude and longitude, but in "nmea style". Them correspond to:

Latitutde: 34 deg 50.729 min North (very cold!)
Longitude: 082 deg 40.572 min West
0
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 13615272
You will find lots of free GPS applications here (some with source code):
http://freegis.org/database/?cat=7&_ZopeId=93032502A1wdrECPlFU
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:r270ba
ID: 13615274
Ok I figured it all out....the above is in degrees/minutes/seconds and I want to convert it to decimal...here are the conversions
===================================================
PLEASE DO NOT DELETE THIS...HERE IS THE ANSWER TO THE QUESTION
===================================================
Procedure for converting decimal degrees into degrees, minutes, seconds:
Decimal degrees value: 37.427916
1. Degrees = whole number part of decimal degrees: Degrees = 37
2. Remove the whole number part of the decimal degrees number: 37.427916 - 37 = .427916
3. Multiply the remainder from step 2 by 60: .427916 * 60 = 25.67496.

4. Minutes = whole number part of results from step 3: Minutes = 25
5. Remove the whole number part of the decimal number from step 3: 25.67496 - 25 = .67496
6. Multiply the remainder from step 5 by 60:  .67496 * 60 = 40.4976
7. Seconds = whole number part of results from step 6 : Seconds = 40
8. Or if you want decimal seconds, then seconds = results from step 6: Seconds = 40.5
So decimal degrees 37.427916 = 37 Degrees, 25 Minutes, 40.5 Seconds.

 

Procedure for converting degrees, minutes, seconds into decimal degrees:
Degrees, minutes, seconds value: 37 degrees, 25 minutes, 40.5 seconds
1. Decimal degrees = degrees + (minutes/60) + (seconds/3600)
2. 37 degrees, 25 minutes, 40.5 seconds = 37. + (25/60) + (40.5/3600)
3. 37. + .416666 + .01125
4. So 37 degrees, 25 minutes, 40.5 seconds = 37.427916 in decimal
degrees.
0
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 13615324
So, you have an specific programming language?
0
 

Author Comment

by:r270ba
ID: 13621856
Yea I am programming in C#...just needed to know the calculations.
0
 
LVL 55

Accepted Solution

by:
Jaime Olivares earned 1500 total points
ID: 13624675
I am not a C# guru, but I think calculus is correct
value is something like 3450.729
resutl (deg,min,seg) will be 34,50,43.74

static public void ConvertNmeaToDMS(double value, ref short deg, ref short min, ref double seg)
{
     deg = System.Math.Floor(value/100.0).ToInt16();
     value = value - deg.ToDouble()*100.0;
     min = System.Math.Floor(value).ToInt16();
     seg = (value - min.ToDouble()) * 60.0;
}
0
 
LVL 13

Expert Comment

by:imarshad
ID: 13647081
Have you got it working??? or do you need some more help?

Imran
0
 

Author Comment

by:r270ba
ID: 13658460
actually I have it working....I figured it out with the above post that I made...

however, I am goign to award jaime_o the points b/c his he did give me the idea of converting it from a string to a double and extracting it....

I will post the correct C# code for future reference however....

Thanks for all your help...

Please check out another post regarding fencing

 http://www.experts-exchange.com/Databases/GIS_GPS/Q_21369030.html

Thanks

r2
0
 

Author Comment

by:r270ba
ID: 13658465
The correct code for extracting the NMEA string data and then converting from degrees to decimals is here

C# version
www.clemson.edu/~wronald/463/parser.html
0
 

Author Comment

by:r270ba
ID: 13658480
The reason I gave you a B jamie_o was due to the fact that the actual question I answered above right before you posted....

But your extraction algorithym for getting the correct decimal is right on minus a few syntax errors...thanks for your help!!!!

r2
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I feel like more and more people want to know how to programmatically convert addresses into geospatial locations. So in this article, I will show you how you can do it with Bing Maps. I'm going to use PowerShell, which is a nice scripting language,…
Introduction This article is designed to assist GIS (Geographic Information System) and GPS (Global Positioning System) developers using ESRI ArcGIS and other spatial information management systems.   For the uninitiated the concept of projectio…
This tutorial demonstrates how to identify and create boundary or building outlines in Google Maps. In this example, I outline the boundaries of an enclosed skatepark within a community park.  Login to your Google Account, then  Google for "Google M…
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…
Suggested Courses
Course of the Month12 days, 5 hours left to enroll

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question