Skip to content
This repository was archived by the owner on Jun 6, 2023. It is now read-only.

Post Dive Data Analysis

Shashank Swaminathan edited this page Jun 9, 2018 · 1 revision

Retrieving data logs

There are two types of logging that automatically occur during testing - telemetry logs, and dataflash logs. Telemetry logs are records of the telemetry information from the Pixhawk, at 10 Hz; telemetry is logged while the device is armed - logs are split around when the device is armed. Dataflash logs stores more detailed information from the Pixhawk at 50 Hz; the logs start from when the Pixhawk is powered, to when it is turned off - while the arming status is also logged, the logs do not split around when the device was armed. Generally, telemetry logs should be enough, if what is required is just telemetry data (motion data). However, if more detailed information of the Pixhawk commands is desired, dataflash logs are required.

To change the level of data stored in dataflash logs, change the GCS_Log_Bitmask parameter in either Mission Planner or QGroundControl.

Storing Telemetry logs

Telemetry logs are automatically stored during testing in a folder labeled Telemetry on the computer as .tlog files. When testing the ROV, the logs are stored in the Telemetry subfolder in the QGroundControl directory. Note that telemetry logs are only stored when testing the ROV using QGroundControl - when testing the ROV using ROS, use the rosbag command to store data from the mavros node.

Storing Dataflash logs

Unlike telemetry logs, dataflash logs will store whether using ROS or QGroundControl. However, the log is stored on the Pixhawk. There are three options on pulling the dataflash logs from the Pixhawk:

  • Using QGroundControl to store the logs - while connected to the ROV, go to the data file tab on QGroundControl (top bar, right most). There, a list of all the dataflash logs stored on the Pixhawk should appear, each with a timestamp. Select the desired log(s), and click download. Do not power off or disconnect the Pixhawk during this process.
  • Using Mission Planner to store the logs - connect a cable to the Pixhawk's USB-B port, and connect the other side to the computer. In the bottom left area, click the tab named Dataflash Logs. There, download the logs from the Pixhawk.
  • Directly copying from the Pixhawk - the previous two examples, while usable, also tend to have issues with data transmission - they time out, corrupt the file during the process of transmitting, or crash altogether. Another alternative is to take out the microSD card on the Pixhawk, and directly insert that into the computer's microSD reader (or use an adapter to read it). On the SD card, there will be a folder labeled 'Logs'. There, the logs should be stored - copy from there to retrieve the dataflash logs. Additionally, delete the copied logs (and the unnecessary logs) from the Pixhawk's storage - after the Pixhawk's allotted storage is used up, there can be problems with data storage in the future.

The dataflash logs are stored as .bin files.

Analyzing the logs

It is inconvenient to parse .tlog files, and not possible to read .bin files - to do so, Mission Planner can be used. After opening Mission Planner, in the lower left area, under either the tabs "Telemetry Logs" or "Dataflash Logs", depending on what is being analyzed, there are options for loading logs. Selecting that will open up a file search box to find the log to be loaded - once a log is selected, a separate window will open, which will have all the stored parameters and data, on the side or below, to be graphed within the window.

The option to convert the logs into different file formats (.log, .kml, .mat) will also be available - after selecting these options, follow the instructions to finish the conversions.

Clone this wiki locally