Question
How forward data from COM PORT to UART
I want to forward all data received at the VCP with USB FS to UART how can i implement this specific in code?
I have been searching for long time for this and i have not found any good example of it.
Can you please help me?
Until now i am doing this like this in my main:
uint8_t byte[1111];
for (;;)
{
if (VCP_read(&byte, 1) != 1)
continue;
HAL_UART_Transmit(&huart5, byte, sizeof(byte), HAL_MAX_DELAY);
VCP_write("\r\nYou typed ", 12);
VCP_write(&byte, 1);
VCP_write("\r\n", 2);
}
If you can help me i will reward you.
Thanks.
