Open fnoop opened 7 years ago
ardupilotmega mavlink dialects in pymavlink contain the MAVLink_remote_log classes/messages, so it should be possible to request/access and extract the datalog-over-mavlink in realtime. Probably the simplest method if possible would be to create another DFReader class like DFReader_text/DFReader_binary, but accessing the log stream instead of file. It probably won't be possible to rewind this stream, so instead just wait until a valid clock is initialised and ignore any data up until that point. Data points before that should be filled in on subsequent transfer when the saved dflog file is closed and processed by the watcher daemon.
Currently mavlogd is set to fire import when a file is closed or moved into the watched directories. So any live dataflash logs being saved by mavlink-router aren't processed until they are closed (disarm). Find a way to process them in near-realtime.