2024-02-04 10:00 PM
Hi,
I started a new project with selected target of Nucleo-STM32F767ZI board, and followed the instructions from
The printf works in the new project, however, when I did the same in the example project "LwIP_HTTP_Server_Netconn_RTOS", I did not get anything from printf.
I added the following into the main.c of the example project:
and
Regards
Chao
2024-03-01 06:51 AM
Hello @Chao ,
can you please attach the modification done in a text format because i can't read the pictures they are too much blurry .
in the meanwhile her are the step you need to follow to get Printf redirection with UART :
#include "string.h"
#include <stdio.h>
int __io_putchar(int ch)
{
/* Place your implementation of fputc here */
/* e.g. write a character to the USART3 and Loop until the end of transmission */
HAL_UART_Transmit(&huart3, (uint8_t *)&ch, 1, 0xFFFF);
return ch;
}
you will find in this link a working implementation of printf redirection with uart on the Nucleo-STM32F767ZI board from which you can cross check all the necessary configuration .
BR