Micro-RLE is the smallest drop-in I could come up with: 264 B of Thumb code, 36 B of state, no malloc, worst-case 14 cycles/byte and still lossless for every 8-bit pattern.
On the usual sensor streams (ADC, IMU, GPS) it’s 33-70 % smaller than raw output and boots in < 600 µs, so you can fire-and-forget from main() before the PLL even locks.
Repo is a single .c file and a 3-function API—replace the weak emit() hook with your UART / DMA / ring-buffer and you’re done.
Size proof: arm-none-eabi-size micro_rle.o text data bss 264 0 36
MIT licensed, link in the repo. Happy to hear where else this fits!
dmitrygr•2h ago
That is to say: I am doubting the 33-70% compression
CoreLathe•1h ago
The headline should read “compresses repetitive logs”; sorry for the noise.