PUTCHAR_PROTOTYPE
{
/* Place your implementation of fputc here */
/* e.g. write a character to the USART1 and Loop until the end of transmission */
HAL_UART_Transmit(&hlpuart1, (uint8_t *)&ch, 1, 0xFFFF);
return ch;
}
int fgetc(FILE *f)
{
int ret;
HAL_UART_Receive(&hlpuart1, (uint8_t *)&ret, 1, HAL_MAX_DELAY);
return ret;
}
|