Download Log Files from pixhawk SD card via USB?

Is there a way to download files from a Nuttx / PX4 system over the usb connection without using qgroundcontrol?

Ideally there would be a python script or something.

I’m not aware of a command line tool that does this.

In the Tools directory, there is the fetch_file.py script, but that seems to be for serial connections. Since PX4 starts a mavlink instance on the serial port by default, that script won’t work.

There is also the mavlink_ulog_streaming.py script, but I don’t think that will download already completed logs.

You could write a script yourself that uses the LOG_REQUEST_LIST and LOG_REQUEST_DATA mavlink messages and contribute it. I’m sure it would be welcome.

Thanks for the response Nicolas,

Yeah that seems like a potentially useful script that I will explore.

I attempted to use the fetch_file.py script and found it to be currently broken. I filed an issue with the details here: https://github.com/PX4/Firmware/issues/10053