The Basic STDIO is a minimal stdout redirection layer for STM32 that provides quick printf output through UART, ITM (SWO), or a custom input/output interface
Basic STDIO is a lightweight trace utility with a small footprint and low integration effort, designed for early board bring-up, firmware prototyping, and basic diagnostic tracing, and easy to integrate, remove, replace, or extend later.
Main features of Basic STDIO:
- Single init entry point
- Supports UART, ITM, or a custom interface
- Deterministic blocking output (character-by-character)
- Hides toolchain libc hook differences (_write, __write, fputc, etc.)
The start-up sequence can be split into two steps:
Initialize Basic STDIO with the selected interface handle by calling BASIC_STDIO_Init(&io_handle) for UART or custom interfaces, or with NULL when using ITM.
Send trace data using printf(const char *fmt, ...) over the configured interface.