Convert NMEA Lat and Lon to........

Posted on 2006-06-06
Last Modified: 2008-01-09
I need to convert NMEA Lat and Lon values to.....well I don't know.  I need to convert them to the typical format I am used to seeing.  

Right now I am getting them in the following formats:

Latitude, ddmm.mmmm format.
Longitude, dddmm.mmmm format.

I need to put them in the format traditional people are used to seeing:


      lat ="42.938660";

Can you help me or point me to the formula for this.


Question by:jfill89
    LVL 13

    Accepted Solution

    Formula is

    dd + mm.mmmm/60   (For latitude)
    ddd + mm.mmmm/60 (For Longitude)

    LVL 1

    Author Comment

    Ok good deal, thanks.  Now when I test a few way points for example starting at

    lat ="42.938660";

    And going to:

    lat ="42.907554";

    If I look at the data coming in it is not returning the long as a negitive number?  It is returning it as a positive.  Do I just need to mult. by -1??

    LVL 13

    Expert Comment

    Yes you can...... -ve Longitude means you are in west.... and you will be receiving your longitudes as xxx.xxxxW


    Featured Post

    Threat Intelligence Starter Resources

    Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

    Join & Write a Comment

    Suggested Solutions

    Title # Comments Views Activity
    Mobile Phone Proximity Marketing 6 1,089
    Custom Google Map 2 411
    Upload a list of contact address to Google Map 5 635
    Using Google Maps API 2 238
    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…

    733 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

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now