![]() I have never tested the script on Windows, so let know how that works out. On Microsoft Windows you will need to supply the full path to the script. I suggest you it install in /usr/local/bin. On Mac OS X and Linux/Unix the $PATH environment variable will be searched to find gpsbabel, so if you can use it from the command-line, Whereabouts will find it. The basic translation is done through GPSBabel. The script only uses standard components, so no further additions to the Python installation are needed. The script is written in Python, so you’ll need to have that installed. You’ll need to have the following software installed to use the script: MapSource files (gdb) can be produced, but this is not recommended.īecause most kml files will come compressed into kmz files, support for this is added to the script, a plain GPSBabel will not handle these files. My script will try to transfer kml commands to the output kml file.įor symmetry reasons in the code, you can use any combination of kml, kmz, gdb and gpx input files, and produce gpx, kml or kmz from them. However, processing by GPSBabel will strip out the descriptions you might have added to the tracks. Since I can add useful information to a track, it makes sense to process kml to kml, for instance to combine several files, or just to add lengths. Since I’m a metric kind of guy, you'll get the length in kilometres.Ī second feature has to do with processing kml to kml. ![]() All I had to do was translate from JavaScript into Python. ![]() ![]() It actually became trivial after I found some code by Chris Veness to do the calculation. Since my tool is rewriting the output kml file from GPSBabel anyway, it was not very hard to calculate the total length of the tracks and add that information to the description of the track. There are some web tools available to claculate this length, but it should be classified as a missing feature. Google Earth has no method of calculating the length of a track, at least not easily. Macintosh users may find the droplets that are listed below useful to perform these tasks without having to use the command-line. Transfer a track to my Garmin GPS device. Take a file from Google Earth, and create a gpx file with multiple tracks, but with each track containing no more than n points, with n=500 for my device. In this mode, the script will produce a single file with multiple tracks in it. Take one or more tracks from the dutch “Fietsrouteplanner” (bicycle route builder) in gpx format, and turn it into a Google Earth file. This mode will reate a single track, that is: separate parts of the file will be glued together, to compensate for loss of reception or the tea-break. I prefer to transfer this file, rather than read the track-log from the device. Note that my GPS device already creates a track log in gpx format, straight on the µ-SD card. Take a track from my Garmin handheld GPS device, and translate it into something Google Earth will read. When developing “Whereabouts”, I hade the following use scenarios in mind: After playing with the options for a while, I found a set of option that produced something pretty close to what I wanted, and I took it from there. Besides, I like the output of GPS Visualizer, and GPSBabel just adds too much information. Practically all conversions of GPS-related data can be done with GPSBabel, but it has too much options, and I grew tired of figuring out how to achieve what I wanted it to do. ![]() The “Whereabouts” Python script is a helper tool to handle geolocated data more easily. This software is licenced under the CC-GNU GPL. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |