Problems with Geotagging using mission planner

Hi everyone, this is my first post on here and i would like to thank everyone for all the hard work and long hours helping others.

So i am running mission planner 1.2.94 and using a steadidrone quad with 12" props, extended landing gear, gopro, no gimbal. canon a2300 attached facing down. Using the latest 3.1.1 arducopter. Flies great, auto missions are good etc. 

My issue is is that when i geotag the pictures from the canon, the altitude, longitude and latitude are mixed up. I am at a loss as to where to begin to fix this. Has anybody had an issue like this before? While flying using telemetry, it shows good data, when i view the kmz in post, it looks perfect. but when i geotag, it gets all messed up.

attached is a sample picture to see the gps details, and the log file and the log.gpx for the flight.

i synchronized my camera and laptop so the offset should be zero, but when i run the offset estimator, it gives me like -345456. im stumped.... any suggestions?

2014-02-06 09-33.log


2014-02-06 09-33.log.gpx

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –


  • Developer

    I'm having a problem with geotag tool for some time now, look at my last file from a test flight, almost 200 pictures.

    Look at the lat and long, almost the same for most of the file, with the plane flying of course. The log in APM shows the right lat and long. Whats happing? Why this isn't fixed? I'm seeing more and more people with the same or similar problem...

    • With out having the pictures and the original log file I can't tell for sure, but I think you calculated offset is incorrect. The locations on the pictures seem to show that the vehicle does not get off the ground until these pictures:

      DSC05706.JPG 2014:03:08 18:08:27 -47,9713952 -15,8345392 1093,86
      DSC05707.JPG 2014:03:08 18:08:30 -47,9712736 -15,8347776 1100,17

      So assuming that the first picture DSC05572.JPG is taken at take off, then you have an error of  5min 47s, you should either add or subtract (I think subtract) this from the estimated offset. Currently its at 3919,325, try geotagging again with this number set to 3572,325 or 4266,325. 

  • In the folder where you have the images there should be a file with there you can preview data being input into the geotag. You can check there if your log offsets are correct or not when you do the geotaging.

    • thanks jamie, i see mission planner was updated today, i tried geotagging again and it worked just fine. not sure what the issue was.

      • Anyone have additional information on this issue? We've seen two flights in the last day where the Geo-Tags are off significantly. I am creating a script locally to re-geo-tag from flight logs and will post it if needed. Thanks

        • This isn't the best approach because I don't have a ton of time to spend writing a complete parser, but if you follow the guidelines at this post:

          To extract .tlog data to CSV, you can use the following (with modifications) php code to generate a gpx. Once you have the gpx you can use exiftool to re-geotag the images accurately. Hard coded stuff in bold, which will need to change for your logs/etc.

          * Change date_default_timezone_set to your flight timezone, you will also
          * need to add a -geosync offset for exiftool on the command line if the
          * time (hour) field doesn't match.

          * Input/Output files
          $incomingfile = "./flight2.csv";
          $outputfile = "./flight2.gpx";

          $mygpx = '';
          $mygpx .= '<?xml version="1.0"?>';
          $mygpx .= "\n";
          $mygpx .= '<gpx creator="" version="1.0" xmlns="" xmlns:xsi="" xsi:schemaLocation="">';
          $mygpx .= "\n";
          $mygpx .= '<trk>';
          $mygpx .= "\n";
          $mygpx .= "\t".'<number>1</number>';
          $mygpx .= "\n";
          $mygpx .= "\t".'<name>DroneMapper UAV</name>';
          $mygpx .= "\n";
          $mygpx .= "\t\t<trkseg>\n";

          $row = '';

          if (($handle = fopen($incomingfile, "r")) !== FALSE) {
          while (($data = fgetcsv($handle, 1000, ",")) !== FALSE) {
          $num = count($data);

          $data[2] = $data[2] * 0.0000001;
          $data[3] = $data[3] * 0.0000001;
          $data[4] = $data[4] * 0.001;

          print "\tGPS Timestamp: " . $data[0] . " " . $data[1] . "\n";
          print "\tGPS Lat: " . $data[2] . "\n";
          print "\tGPS Lon: " . $data[3] . "\n";
          print "\tGPS Altitude: " . $data[4] . "\n";

          $mygpx .= "\t\t\t<trkpt lat=\"".$data[2]."\" lon=\"".$data[3]."\">\n";
          $mygpx .= "\t\t\t\t";
          $mygpx .= '<ele>'.$data[4].'</ele>'."\n";
          $mygpx .= "\t\t\t\t";

          $data[1] = preg_replace("/ /", "", $data[1]);
          $mygpx .= '<time>2014-02-07T0'.$data[1].'Z</time>'."\n";

          $mygpx .= "\t\t\t";
          $mygpx .= '</trkpt>'."\n";

          $mygpx .= "\n\t\t";
          $mygpx .= '</trkseg>';
          $mygpx .= "\n\t";
          $mygpx .= '</trk>';
          $mygpx .= "\n";
          $mygpx .= '</gpx>';

          /* Write GPX */
          file_put_contents($outputfile, $mygpx);

          % exiftool -geotag flight2.gpx '-geotime<${DateTimeOriginal}+02:00' *.JPG

          also mav2gpx python code looks promising but I haven't visited this in a while. 

          • Why did you have to write a script? could't you just adjust the geotag offset in Mission planner? or did you find a problem with that?

            Also if your tlogs are not accurate or you lost comms at some point you will have data missing and in that case its better to use the data flash logs to geotag. You can do that in mission planner as well.

  • here is also a copy of the original image to compare.


This reply was deleted.


DIY Robocars via Twitter
7 hours ago
DIY Robocars via Twitter
RT @_JonMyer: 🚨Attention DeepRacer's including #UndergroundDeepRacer🚨 Check our our LIVE stream that including @IAM_dbro Take a few moments…
Aug 5
DIY Drones via Twitter
RT @MarvelmindMaxim: Extreme precision for 60 swarming robots. #marvelmind #autonomousrobotics #robotics #swarmrobotics #rtls #ips #indoor…
Aug 3
DIY Drones via Twitter
RT @MarvelmindMaxim: Precise (±2cm) tracking for racing boats and autonomous boats. Works outdoor and indoor. #autonomous #AutonomousVehic…
Aug 3
DIY Drones via Twitter
RT @MarvelmindMaxim: Helping PixHawk folks to fly autonomous quadcopters using PX4 and ArduPilot. Equally suitab…
Aug 3
DIY Robocars via Twitter
RT @chr1sa: The @DIYRobocars @donkey_car virtual AI car race is starting in 15 minutes! Watch it live on Twitch htt…
Aug 1
DIY Robocars via Twitter
RT @chr1sa: Don't miss our monthly @DIYRobocars @donkey_car virtual AI car race tomorrow at 10:00am PT live on Twitch. Head-to-head racing…
Jul 31
DIY Robocars via Twitter
RT @sparkfun: Our completed tutorial on building an @NVIDIA Jetson Nano-powered @Sphero RVR gets your bot up and running via teleoperation…
Jul 30
DIY Robocars via Twitter
RT @SmallpixelCar: Freeway test
Jul 29
DIY Robocars via Twitter
Very small autonomous cars racing, thanks to an overhead camera:
Jul 29
DIY Robocars via Twitter
Jul 29
DIY Robocars via Twitter
Jul 29
DIY Robocars via Twitter
RT @chr1sa: Don't miss our virtual AI car race this Saturday! Real developers + virtual cars =🏎️🏎️🏎️ Head-to-head battles with thrills, sp…
Jul 28
DIY Robocars via Twitter
Jul 27
DIY Robocars via Twitter
RT @usashirou1: Jetson nano by Isaac Kaya #jetson
Jul 23
DIY Robocars via Twitter
RT @GPUsolution: JetRacer mady by Iflytek company #JetsonNANO #Nvidia
Jul 23