erikbaas
(erikbaas)
November 24, 2022, 5:11pm
1
I am planning on grouping my flight into sections. To make logfile analysis easier, I would like to end- and create a new logfile on command. Currently, the only way I know of is to power off- and on the battery, but I cannot do this in mid-air of course.
Does anyone know of a command to split logs as I would like to?
Kind regards,
Erik
Take a look at mavlogdump.py
#!/usr/bin/env python
'''
example program that dumps a Mavlink log file. The log file is
assumed to be in the format that qgroundcontrol uses, which consists
of a series of MAVLink packets, each with a 64 bit timestamp
header. The timestamp is in microseconds since 1970 (unix epoch)
'''
from __future__ import print_function
import array
import fnmatch
import json
import os
import struct
import sys
import time
# Detect python version
if sys.version_info[0] < 3:
This file has been truncated. show original
There are also some posts on the forum about it.
I dont think it is necessary though since all the logs are time stamped.
If this is useful for you, there is a parameter that creates a new log file for each flight, so this way you don’t need to plug/unplug your battery everytime:
https://ardupilot.org/copter/docs/parameters-Copter-stable-V4.0.8.html#log-file-dsrmrot-stop-logging-to-current-file-on-disarm
I think it is this one above.
Also, upgrade to the latest 4.3 stable if possible, it has many improvements over the 4.0 version.
1 Like