newbi for gps, CoreLocation...

Discussion in 'iPhone/iPad Programming' started by henktade, Apr 21, 2009.

  1. macrumors newbie

    Joined:
    Jan 30, 2009
    #1
    hi,

    can any one give me brief description of how to get like City names, zip codes, street names etc.. after we get the coordinates of the current location of my iPhone.

    tanks
     
  2. macrumors demi-god

    fishkorp

    Joined:
    Apr 10, 2006
    Location:
    Ellicott City, MD
    #2
    3.0 has a Reverse Geocoder that can do all that for you. 2.x does not, you'd have to use a 3rd party service (or provide your own) for it.
     
  3. thread starter macrumors newbie

    Joined:
    Jan 30, 2009
    #3
    so i send the coordinates to this 3rd parties? like 25.333 North , 110.0345 West

    how would it be if I want to get data from maps.google.com?

    tanks
     
  4. macrumors demi-god

    fishkorp

    Joined:
    Apr 10, 2006
    Location:
    Ellicott City, MD
    #4
    Carefully read Google's TOS for their revers geocoder. I think you can only use their service in a free app.

    However Google is providing the reverse geocoding in 3.0, with slightly modified TOS for use of the API.

    If you want to use Google, I suggest you read the Google maps TOS on the web APIs, or read the TOS for 3.0 linked off the developer portal.
     
  5. thread starter macrumors newbie

    Joined:
    Jan 30, 2009
    #5
    Premium service

    fishkorp, tanks for the info.. as I understand now, for non-free apps u should sign for the Premium google maps api. I am wondering though if all navigation related application in Appstore use this premium service. Because I think it is quite expensive for individual programmers like me.

    henk
     
  6. macrumors demi-god

    fishkorp

    Joined:
    Apr 10, 2006
    Location:
    Ellicott City, MD
    #6
    Currently, I'm using my own service. I got a dump of data (free) from geonames.org. GeoNames also offers a web service, but it gets hammered a lot and your request can time out. If you make your own service you'll have to do some pretty complicated math in order to calculate the closest city/state/address based on the lat/lon coordinates. You'll need a web server and a database to offer your own service. Google isn't the only one offering reverse geocoding though, there are plenty of others (Microsoft offers it, as well as many 3rd party companies that ONLY do reverse geocoding). It's best to just do some research on the topic and figure out what works best for you and fits into your budget.

    However I changed my code to use the reverse geocoder in 3.0 and it works much quicker. You can charge for apps that use the 3.0 reverse geocoder (provided by Google) as long as that isn't the only purpose of the app (like I said, read the 3.0 TOS on the topic on the dev portal). If you can wait until the summer to release your app, I'd suggest using the stuff already built into 3.0. Makes things a lot easier.
     

Share This Page