Write uncompressed Vector BLF CAN log files on embedded devices.
#include "can_common.h"
#include "blflogger.h"
BLFWriter writer('name.blf');
int main()
{
frameobject_t fobj;
fobj.frame.id = 0x123;
fobj.bus_number = 5;
writer.log(&fobj);
writer.stop();
}
Most of this is transcribed verbatim from the python-can BLF module. That module credits TobyLorenz' comprehensive vector_blf.
I made this for a project that uses the Arduino libraries and toolchain on ESP32. I tried cross-compiling , but found that the version of ESP-IDF pinned by Arduino doesn't support C++ exceptions, a language feature which vector_blf
makes use of.