How To - PPK Processing with RTKLib (Phantom 4 RTK)

Here are the instructions for using RTKLib to process the P4RTK flight data. Aerotas has done a excellent write-up on how to process the data and I’ve added a few images to help clarify the steps.

Follow the steps in the link above and use the following images to help answer questions you may have.

Step 1) Select closest CORS Site to your mission, in the example the flight was in the Pittsburgh area so zoom in to the area and click the icon closest to the mission. This will bring up a window giving it’s CORS Site ID (ex. PAAP)

Step 2) This shows all the different areas you need to fill out to get the correct CORS Data. Fill in the Flight Date, Time, Duration, CORS Site ID, Satellites, and Options. Then Click get CORS data file Button

Step 3) Based off the date you need to download the appropriate date file. Go to the CDDIS Site to get the daily GPS Broadcast file. Navigate to the daily/{year}/brdc directory and locate the files brdcXXX0.19n.Z, replace the XXX with the the number in Step 2 (Green circle), the 19 is the year ex 2019.

Step 4) Set all these Options, You will need to set these options before you can set the Base Station file. Click Options Button
RTKPost
Settings 1
RTKPost%20-%20Settings%201

Settings 2
RTKPost%20-%20Settings%202

Output
RTKPost%20-%20Output

Positions
RTKPost%20-%20Positions
Click OK Button

Step 5) Execute the process, Click Execute Button
RTKPost

Step 6) These are the results of a successful process, Click Plot Button

Click View Button to see .POS file output

You can skip these steps if you want to use GeoSetter, skip down a few posts and look for the How to generate a GPX file

Here are the Screenshots of the Aerotas Excel Spreadsheet Steps:
Credit goes to Aerotas for creating this spreadsheet and I’ve only help with the following images to assist in clarification.

Launch the Excel Spreadsheet and follow the instructions/images

  1. Click “Reset File to Starting Format” Button

  2. Set the name of the Survey Directory that the photos are in, See example in Yellow (This is used to create the Photo File Name in the Output Step)

  3. This Process requires performing additional steps in a different Excel Spreadsheet, See Convert to CSV Instructions below. Copy the CSV Output to The Position File Tab (Yellow Tab), See Position File below. Once Done the orange box will turn green

  4. Copy the contents of the “timestamp.mrk” file from the mission located in the Survey/Photo Directory, See Timestamp below. Once Done the orange box will turn green

  5. Click “Calculate Interpolation & Position Offset” Button. Once complete Click “OK”

  6. Once you Calculate the Process you will see 3 green blocks. Now verify the Output, See Output below. Once done Click “Save Output as CSV file” Button. This will save and close the spreadsheet.

Calculation Tab
No User Interaction on this Tab

Convert to CSV Instructions
Open a New Excel Workbook and then Open the .POS file from the flight. This will Open the Text Import Wizard.

  1. Select Delimited, Click Next
    Excel%20-%20Convert%20to%20CSV%201

  2. Uncheck Tab, Check Comma, Click Next
    Excel%20-%20Convert%20to%20CSV%202

  3. Click Finish
    Excel%20-%20Convert%20to%20CSV%203

  4. Select All Rows, Starting at Row under the Header and Select All Columns, Make sure you scroll to the bottom of the file to select all the rows

  5. Copy the Selected Rows/Columns, this will be pasted in the Process Spreadsheet.

Position File

  1. Select the Position File Tab, down at the bottom. Make sure the cursor is in Row/Column as shown in the image

  2. Paste the contents from Step 5 in the Convert to CSV Instructions

Timestamp

  1. Select the Timestamp Tab, down at the bottom. Make sure the cursor is in Row/Column as shown in the image

  2. Open the “timestamp.mrk” file in a editor, Select All and Copy content

  3. Paste the .MRK content from Step 2

Output

  1. This is how the Output Tab looks after a Reset

  2. This is the output after the Calculation is preformed

  3. This is after you Save the CSV Output

  4. This is te CSV file that was created by the Process Spreadsheet to be used in 3rd party software to correct the Lat/Long/Elevation of each photo.

Hopefully this helps clarifies the Spreadspheet process.

3 Likes

Link to original post with ALL the history…

1 Like

I don’t own a P4RTK but kudos to @GregO for taking the time to post this helpful information regardless. Good Job!

2 Likes

I’ve only had mine a short period of time but it already has 36 miles and 6.5 hrs in the air. In the next few weeks it’s going to getting a lot more, dang Texas weather has been crappy lately.

:facepunch: No doubt. Get it when you can! I just put in 10 maps in 3 days. And we are just playing with toys…

1 Like

Hello, thank you very much, where do I get the Excel file? (Here are the Screenshots of the Aerotas Excel Spreadsheet Steps)

Thank you

Eddison

2 Likes

In the this link down at the very bottom. Look for “Download PPK Correction File”

It will ask you for a email address and then you can download it.

Do you use a general rule of how far the correction source can be from your location? As I understand it, you will start getting errors around 10km?

I try and locate the closest source to my flight. But from everything I’ve read once you start going over 10km you can get errors.

1 Like

Same here. I have 3 stations surrounding our office, but they are all 8km-15km… :disappointed_relieved:

1 Like

Yeah I had to use SAM2 the other day.

1 Like

Muchas gracias!

Saludos

Eddison

2 Likes

Here is a example showing the difference between two CORS Sites. This proves the discussion above about errors based on distance from CORS site vs the Flight area.

CORS Site: SAM2

PhotoNum Latitude Longidute Elevation (meters)
100_0001_0001.JPG 30.24034697 -97.72583982 146.4987782
100_0001_0002.JPG 30.24031065 -97.72587944 146.4720228
100_0001_0003.JPG 30.24027855 -97.72591547 146.4654744
100_0001_0004.JPG 30.24024518 -97.72594882 146.5066328
100_0001_0005.JPG 30.24021283 -97.72598409 146.440826
100_0001_0006.JPG 30.2401819 -97.72601861 146.4568368
100_0001_0007.JPG 30.24014909 -97.72605507 146.4421832
100_0001_0008.JPG 30.24013495 -97.7260682 146.477577
100_0001_0009.JPG 30.24009665 -97.72609204 146.5046157

CORS Site: TXAU

PhotoNum Latitude Longidute Elevation (meters)
100_0001_0001.JPG 30.24034696 -97.72583961 146.5172525
100_0001_0002.JPG 30.24031064 -97.72587928 146.4859228
100_0001_0003.JPG 30.24027848 -97.72591535 146.4740901
100_0001_0004.JPG 30.24024517 -97.72594864 146.5252451
100_0001_0005.JPG 30.2402128 -97.72598394 146.4628012
100_0001_0006.JPG 30.24018187 -97.72601843 146.487676
100_0001_0007.JPG 30.24014908 -97.7260549 146.4770748
100_0001_0008.JPG 30.24013495 -97.72606802 146.515177
100_0001_0009.JPG 30.24009665 -97.72609186 146.5414755

This is the same mission just being processed with two different CORS data and how each CORS site sees the satellites. Below shows the area of the flight vs where the CORS sites are located.

image

Haha, we are literally right across the lake on one and across the highway on the other…

image

1 Like

How to Generate a GPX file

Here is a different way to get your data out of DTKPost.

Click the KML/GPX… button
RTKPost

Select GPX, Q-Flags - All, Output Altitude - Elliposoidal, Output Time - UTC
Select the Input/Output/GE Exe File
Click the Convert button
KML%20-%20GPX

Click the View button to see the GPX file that was created.

If you want a KML file, Select KML and set the path to your Earth Earth Exe, Click the Convert button.
KML%20-%20GPX1

Now that you have a GPX file you can use GeoSetter to read the GPX file and modify the photos exif GPS data.

I will be creating a How To GeoSetter , there is a GeoSetter Guide that was written and hard to see the photos and follow the instructions, but you can manage. They way I do it I skip a lot of this Guides steps and it’s a lot cleaner process. I created a new How To - Use GeoSetter thread, you can find the link two posts down.

3 Likes

This is how I do it. I use the GPX to re-tag the photos in Geosetter. Very easy.

If you use the Emlid version of RTKLIB you will get an “events” POS file as well.

How To - Use GeoSetter to Update GPS Metadata (PPK Processing)

@GregO i’m not using CORS, i’m using my own gnss reciever for base. Can you help me with the rtklib steps for using my own base?