Adventure Motorcycle Magazine Subscribe Now

Page 1 of 7 123 ... LastLast
Results 1 to 10 of 65
  1. #1 Mastering Google Maps 
    Life Is Good! ChinaV's Avatar
    Join Date
    May 2008
    Location
    Guangdong, China
    Posts
    1,508
    This is a basic tutorial for using Google Maps on your computer and transferring a route to your smartphone. Doesn't matter if you have a Mac, PC or Linux, and this works with just about every phone running Google Maps, with the exception of the iPhone. Also works with ditu.google.com AFAIK.

    Concept: Spend hours plotting an awesome route on your Mac/PC, jump on your moto, follow that exact route with your phone as a GPS.

    Problem: Google Maps has a tendency to take you on the shortest route, missing all those great twisty roads.

    Skills: You don't need to be a computer genius, but you do need a basic understanding of files and things like copy and paste.

    Tools: A browser (Safari, Firefox etc.), a plain text editor (Notepad, TextEdit, Pico etc.), a way to upload a file to the internet (FTP, SFTP, WebDAV etc.), and a smartphone running Google Maps. You will also be able to use the output file in programs like OruxMaps. A simple online converter can also convert these files to the GPX format for use on GPS units like Garmin etc.

    Let's begin...

    #1 Open you browser and go to Google Maps



    #2 Figure out where you want to go and right mouse click on a start point. Select "Directions from here"



    #3 Navigate to where you want to end the trip for the day and right mouse click on an end point. Select "Directions to here".



    #4 On the left hand side of the window, click the "Show options" link.



    #5 Select the "Avoid highways" box (as motorcycles are not allowed on those roads in most places) and then click get directions.



    #6 You now have a boring route between point A and B.



    #7 Use your mouse to "grab" your route by clicking on it and dragging the route to the road you actually want to take.



    #8 You can do this multiple times to create a complicated route adding lots of twisty roads. In this example, I made four custom points on the route. If you make a mistake, just right click on the little circle and select "Remove this point".



    #9 Now you need to get this route out of Google Maps. (Sure, you could just save it to "My Maps" if you have a google account, but the following gives you a bit more power and flexibility.) In the right hand corner click on "Link" and you will get a choice of links. "Copy" the top line of text.



    #10 Open a new browser window or a new tab in your browser and "Paste" the text into the URL box at the top. Don't hit enter yet... go to the end of the line you just "Pasted" and type "&output=kml". Now hit enter ( or return) and a kml file will download to your computer. It will probably be named something like maps.kml.



    #11 Let's open that "maps.kml" file in our text editor and have a peek. Lots of scary looking text. Don't worry, we're only going to use the coordinates, the part I have highlighted in orange. Go ahead and look for the <coordinates> statement and "Copy" it and everything else until you get to the </coordinates> statement. If you mapped a big route, you will have a lot of text to select. Just "Copy" all that info.



    #12 Now we need to make a new kml file with a header and footer that Google/Orux Maps will understand. Don't worry, I've already made one for you and you can download it here. This is the basic data needed to draw route lines on the map. You only have to worry about "Pasting" your data over the orange part I have highlighted.



    #13 After adding your coordinates to the the text file, you need to scan the file for "breaks" that google maps will sometimes insert on long routes. I recommend you remove these lines, as they sometimes cause problems and you will only see part of the route you created. Just scan the file and remove each occurrence you find, being sure you leave a space so it all looks uniform.



    #14 OK, the hard part is done, you can now save the file to your desktop, documents folder, or wherever makes you happy. Make sure you name the file "XXX.kml" and not "XXX.txt". You can put whatever you want for XXX, but I usually use something very short, like "107.kml", it's easier to remember short file names.

    Now this is where many of you have a problem. You can't open this file in Google Maps without it being stored online. That means you need access to a web server that will host the file for you. I don't know how you can get that for free, maybe someone can chime in with some suggestions. I don't mean something like rapidshare or mega-upload, you need a plain jane folder being served by a normal web server. I will be happy to post a file or two for people here, but it's not a service I can reliably offer to everyone. You can shoot me a PM and I will give you my email to send the file if you want to try it.

    Once you have the file stored online, you just go to the search box in Google Maps and enter the location of your file. You can do this on your computer or on your phone. You can also send that link to a friend and they can do the same. The file will be public and can be seen by everyone, so you might want to start your routes a few blocks from home if you're paranoid about that kind of stuff.

    Here's a route example...



    If you want to get all fancy, you can edit the XXX and YY part of the text file to add the distance and time. You can also change the route color and transparency. I made it pink because I'm secure with my manhood and can use such colors, you may feel more comfortable with blue or purple.

    Just remember, everything you are seeing is just an XML text statement being translated by the Google Maps program. The more you play with it, the more customized you can get. The basic route is simple, maybe later on I will go into things like correcting offsets and overlaying map layers for those that really want to go nuts.

    Fire away with questions and suggestions.

    Cheers!
    ChinaV
    Last edited by ChinaV; 04-20-2013 at 03:18 AM.
    Reply With Quote  
     

  2. #2 Re: Mastering Google Maps 
    Senior C-Moto Guru euphonius's Avatar
    Join Date
    Dec 2009
    Location
    mostly Shanghai, sometimes northern California
    Posts
    3,222
    Awesome tutorial, ChinaV. How the f*&K did you figure all that out? Don't you have a fulltime job? Do you ever sleep? Anyway, this MCM denizen deeply admires your geotechnical prowess. Wow.

    I have two questions:

    1) I'll take your word that none of this works in the iPhone. But is that perhaps in the works? Is there something in the jailbreak/Cydia universe that would be able to accept a .kml map of this sort? Or is this just an unfortunate outcome of the Google-Apple rivalry in mobile world, with no likelihood of a solution?

    2) Is it possible to download that google map into my Garmin Zumo 660?

    Again, beautiful tutorial, for which many thanks!

    cheers
    jkp
    Shanghai
    2010 JH600 "Merkin Muffley" (in Shanghai)
    2000 KLR650 "Feezer Ablanalp" (in California)
    Reply With Quote  
     

  3. #3 Re: Mastering Google Maps 
    grumpy old sod jape's Avatar
    Join Date
    Jan 2010
    Location
    central victoria, australia
    Posts
    1,291
    I made it a sticky thread as ChinaV was too modest. Thanks mate.

    It is valuable and relevant, and usable for a lot of people, so add your various questions and comments and solutions about anything Google maps and related GPS issues for now, with the proviso that we will split off other related Q and A if they become cumbersome, ie if we get lots on Garmin, then we will have a Garmin thread. etc. Those decisions will be ChinaV's as it is his expertise and hard work!
    Kinlon R/T KBR JL200GY-2
    Reply With Quote  
     

  4. #4 Re: Mastering Google Maps 
    Life Is Good! ChinaV's Avatar
    Join Date
    May 2008
    Location
    Guangdong, China
    Posts
    1,508
    Quote Originally Posted by euphonius View Post
    1) I'll take your word that none of this works in the iPhone. But is that perhaps in the works? Is there something in the jailbreak/Cydia universe that would be able to accept a .kml map of this sort? Or is this just an unfortunate outcome of the Google-Apple rivalry in mobile world, with no likelihood of a solution?
    I'm not sure if this kind of thing is an Apple or Google issue. When I had my iPhones, I just couldn't get this to work, and it's the main reason I never considered another iPhone. Google Maps on Android and WinMobile have no offset issues and can easily open these custom KML files, I hear lots of conflicting reports about maps on iPhone having, or not having, the offset.

    Also have heard a bit about using the "My Maps" account with google to open custom maps on iPhone, but since I don't have one anymore, I can't try it. You can easily create a google account for free and load the example kml I posted at ...http://www.contactdi.com/map/107.kml... then save it to your "My Maps" account and then try to log into your "MyMaps" account on your iPhone. If it works, that would be great. I usually hit Hong Kong at least once per month and whenever I get my paws on an iPhone or iPad, the first thing I try is to open the kml via the search bar in maps... it never works.

    Quote Originally Posted by euphonius View Post
    2) Is it possible to download that google map into my Garmin Zumo 660?
    Some Garmin GPS units support KML files and some have browser plugins that are supposed to allow uploading a route. I only have Garmin Mobile XT for pocket PC, and there isn't any way of loading a route, but you can load a single waypoint directly from your browser using Garmins crappy plug in for Safari.

    One thing you can do with any Garmin unit:
    Take the kml file you have and go to http://www.gpsvisualizer.com/ There's a built in converter that will change your file from KML to GPX. Once it's in the GPX format, you can load it into your Garmin GPS. Some Garmin units allow you to just put the file on your SD card, others require Basecamp or Mapsource to upload the GPX track.

    Cheers!
    ChinaV
    Reply With Quote  
     

  5. #5 Re: Mastering Google Maps 
    C-Moto Guru Fred's Avatar
    Join Date
    Oct 2010
    Location
    Shanghai
    Posts
    333
    Absolutely awesome ChinaV !! Thanks a lot for taking the time to post all this with screenshots and all !

    One of my geek friend is also thanking you, as I was on his back all the time asking him how to do this exact thing, and also to force him to sell me his "old" HTC, teasing him with the newest one... Now I only have to insist on the HTC part. ;-))
    Reply With Quote  
     

  6. #6 Re: Mastering Google Maps 
    MCM Chinese fellow td_ref's Avatar
    Join Date
    Jun 2010
    Location
    Shenzhen, Meizhou
    Posts
    387
    Thanks, V, I just learn a new trick downloading a google map route into a kml file and making it ready for usage.

    About the question from the other thread, I was curious that anyone has been aware Google Maps mobile can overlay Mymaps' route, so that one at least can see the route at his phone as he goes.

    Mymaps has some advantage than the exporting kml way describe at this tutorial. After a planed route saved to Mymaps, modify the waypoints, route still snap to roads. You get similar flexibility in Mymaps as in Google Maps. At my test import the kml back to Mymaps does not. But V's way solve one problem that Mymaps cannot save route with options, either "avoid toll" or "avoid highway". Google should make that work, but not now. Another is Mymaps is simple, one don't have to be a GPS geek like V.

    Google Navigation can't load Mymaps route, it would be one key selling point for me, maybe that's why the app still in beta.

    ...Once it's in the GPX format, you can load it into your Garmin GPS.
    I haven't touched pro Gps device like Garmin, did you mean Garmin can voice navigate thought pre-load GPX route?
    Last edited by td_ref; 02-20-2011 at 11:45 AM.
    Reply With Quote  
     

  7. #7 Re: Mastering Google Maps 
    Life Is Good! ChinaV's Avatar
    Join Date
    May 2008
    Location
    Guangdong, China
    Posts
    1,508
    Quote Originally Posted by td_ref View Post
    did you mean Garmin can voice navigate thought pre-load GPX route?
    No, it can't do that. The uploaded GPX will show up as a track instead of a route, so you still need to manually plot your route if you want turn by turn voice navigation. The GPX track import is mostly used for roads that don't show up on the Garmin maps or to help you plot your route.

    TD, you are correct about some of the editing advantages of using "MyMaps". One thing I have not tried comparing is what happens if you are following a route with a MyMap layer and you lose internet connection? With the KML file loaded in the above example, you lose the map background, but you can still see the pink line and your position. I know the offline support of Google Maps is getting better, so that will probably not be an issue soon, and I'm sure MyMaps will get all the features necessary to avoid this kind of complicated mess sometime in the future.

    One other nice thing with the KML file is sharing. If your friend calls while on the road, and asks for a twisty route, you can tell them to load the KML file and they can follow along. It's a bit complicated to share your MyMaps route with a friend via smartphone.

    Cheers!
    ChinaV
    Reply With Quote  
     

  8. #8 Re: Mastering Google Maps 
    Motorcycle Addict chinabiker's Avatar
    Join Date
    Apr 2008
    Location
    near Vienna, Austria
    Posts
    809
    First of all, thanks for the excellent write up , particularly from 8 onwards.

    Quote Originally Posted by ChinaV View Post
    TD, you are correct about some of the editing advantages of using "MyMaps". One thing I have not tried comparing is what happens if you are following a route with a MyMap layer and you lose internet connection?
    Yes, the line from MyMaps and your position will still show, even when the Internet connection is lost.
    I am not sure but it seems that as soon you load a map from MyMaps, caching concentrates on the area the map covers - again, not sure but it seems to be.


    Some remarks from my experience with Google Maps.

    The map link is different in Chrome (at least in XP Pro), and doesn't work with the "&output=kml"



    I usually don't select the start and the end and drag the points, but choose the end pretty near the start and then add one by one destination (right click - add destination). I find it a bit easier to force where I actually want to go and it doesn't re-calculate the whole route when you only drag the last destination you've added, but that's just a matter of taste.


    The good thing on MyMaps is that you can save the maps, share and collaborate with others and create day by day routes for longer trips. The good thing is that the method described by ChinaV from 8. onward still works.

    According to my experience the filename and pathname for the kml shouldn't contain special characters as it won't open.


    Again, thanks for starting this
    Andy
    Reply With Quote  
     

  9. #9 Re: Mastering Google Maps 
    Senior C-Moto Guru
    Join Date
    May 2009
    Location
    was in China. will be back
    Posts
    654
    Quote Originally Posted by ChinaV View Post
    Now this is where many of you have a problem. You can't open this file in Google Maps without it being stored online. That means you need access to a web server that will host the file for you. I don't know how you can get that for free, maybe someone can chime in with some suggestions. I don't mean something like rapidshare or mega-upload, you need a plain jane folder being served by a normal web server. I will be happy to post a file or two for people here, but it's not a service I can reliably offer to everyone. You can shoot me a PM and I will give you my email to send the file if you want to try it.
    Dropbox's online backup service offers direct links to your files; upto 2 gb free total. Unfortunately it's bl*cked in China. I needed such a service for my students, if anyone knows an equivelant service that's still not blocked, please let me know.

    Thanks for the great writeup V, especially step 11. I did something similar before I went to Chengdu, but without stepp 11, all I got was the points where GMaps tells you to turn. I ended up with waypoints I use just for confirmation that I'm getting closer to my destination. With the special offset here, I'm not sure how useful that was for me.
    Reply With Quote  
     

  10. #10 Re: Mastering Google Maps 
    Duct tape savant felix's Avatar
    Join Date
    Jun 2009
    Location
    Guilin, China
    Posts
    1,252
    I had a look at the windows live skydrive for file hosting but to no avail. It lets you store 25gb of pictures or any files for free, but doesn't give a direct link to the files. Shame. I still think it's great for hosting pictures for ride reports though.
    Reply With Quote  
     

Page 1 of 7 123 ... LastLast

Similar Threads

  1. Offline maps on Android in China
    By felix in forum Ride Prep and Making Tracks
    Replies: 62
    Last Post: 10-15-2016, 04:46 AM
  2. Google Earth 5.0 update...
    By CrazyCarl in forum Ride Prep and Making Tracks
    Replies: 3
    Last Post: 02-12-2009, 11:41 AM
  3. Little Google Earth Trick
    By ChinaV in forum Ride Prep and Making Tracks
    Replies: 4
    Last Post: 12-18-2008, 06:15 AM
Bookmarks
Bookmarks
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •