Log what you need, not what your bandwidth allows

You can now send logs from your Zephyr devices without sending the log text. Your LOG_INF() calls stay exactly as they are.
Until now, every character of a log message cost bandwidth on the radio, and every format string took flash on the chip. So messages got trimmed, DEBUG got compiled out, and the detail you needed when a device failed in the field wasn't there. With Compact Logs, the device sends only the format string address and the raw argument values, and Spotflow rebuilds the readable message from your firmware's ELF file. Message size now depends on the arguments, not the text.

What you can do
Write the descriptive message:
LOG_WRN("Sensor %u failed after %u retries; check power supply", 7, 3)drops from 90 bytes to 43, the same size as a much shorter log with two arguments.Send fewer bytes per log: In our examples, complete log messages are 26 to 52% smaller than formatted CBOR logs.
Keep DEBUG logs in production firmware: Strip format strings from flash and keep them only in the ELF file. On our OTA sample for NXP FRDM-RW612, a DEBUG build with stripping was smaller than a WARNING build without it.
Turn on detail only where you need it: Keep the fleet on WARNING and raise the log level from the web app for the one device that misbehaves, without reflashing.
Skip text formatting on the device: The logging backend sends the arguments as they are.
Use it from any MQTT integration: The compact logs protocol is documented, so custom integrations can send compact logs in CBOR too.

Get started
Enable compact logs: Add
CONFIG_SPOTFLOW_COMPACT_LOGS=ytoprj.conf. KeepCONFIG_SPOTFLOW_GENERATE_BUILD_IDon (the default) so Spotflow matches each log to the right ELF file.Upload the ELF file for every build: Use Firmware Management, or add it to your release pipeline with the Management API. Upload it before the firmware reaches devices: logs without a matching ELF file show up unresolved.
Optionally, strip format strings from flash: Add the lines below. Stripping turns off Zephyr's text log output, so check the UART logging options first.

For setup and the full measurements, see Compact logs with Zephyr and Using Spotflow with resource-constrained devices. Building your own MQTT integration? Follow the compact logs protocol reference.
Check our Roadmap. Join our community on Discord. Follow Spotflow on LinkedIn.