I'm using a STM32F407ZG. When we use printf, it goes where?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-12-03 5:37 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-12-03 6:34 AM
In GNU/GCC as implemented via ST _write() then __io_putchar() to the UART you've created/enabled to output the data
In Keil the plumbing is slightly different, but the overall method is to sink characters and output them via a channel you opt to use.
They can go to HAL_UART_Transmit() or ITM_SendChar(), or both. Or whatever equivalent bare-metal or library you utilize.
https://community.st.com/s/article/how-to-redirect-the-printf-function-to-a-uart-for-debug-messages
https://community.st.com/s/question/0D50X0000BNLT7RSQX/role-of-syscallsc
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-12-07 9:28 AM
If I didn't use any UART or If it's not redirected, I suppose it goes nowhere, right?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2022-12-07 9:33 AM
Or traps in a BKPT..
Some of this might be evident with some debugging, and code walking. You could look at a disassembly, perhaps .MAP symbols.
Not much to work with here, your description of the system and build tools, pretty vague.
Up vote any posts that you find helpful, it shows what's working..
