Extracting useful data from tlogs

Good morning,

I am trying to calculate the mean, max, and min current from a 52 minute flight using a tlog. The graph looks like a straight line because of the duration. I cannot make any sense of the .csv file, because it doesn't appear to be columnated. Any ideas?

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

Join diydrones

Email me when people reply –

Replies

  • Developer

    Hmm, The backend of droneshare includes support for calculating these things.  If it would help I can add it to the standard info shown for flights?

  • Dave,

    I spent a good part of yesterday dealing with this same issue, but think I finally deciphered it.

    Skip the first 300 lines or so, which are parameters. My most recent flight log starts on line 322. Mavlink sends many different types of messages, which are documented here: https://pixhawk.ethz.ch/mavlink/. Each message is given a line in the .CSV file. The fields of each message (also documented above) are arranged horizontally within that line in the format FIELDNAME, VALUE, FIELDNAME, VALUE, FIELDNAME, VALUE. 

    To plot values from the .CSV file, import it into Excel or other spreadsheet software, then filter by the mavlink message you are interested in (in your case, I think that will be mavlink_sys_status_t). Now you will have columnated data of the fields within that message type. 

    I also came across a couple free tools to assist with parsing .CSVs. I haven't tried it yet, but here is one written in C#: http://diydrones.com/profiles/blogs/extracting-data-from-tlog-files...

    Hope that helps,

    Mark

This reply was deleted.