AnsweredAssumed Answered

Stm32f4 Usb VCP corrupted data (CubeMX)

Question asked by carsten32 on Sep 22, 2017
Latest reply on Sep 26, 2017 by carsten32

Hi,

I have a problem while implementing a USB Virtual Com Port (USB CDC Class) with CubeMX.

The setup is the following:

PC running Hyper Terminal sends keystrokes to the microcontroller (STM32F407VG) which are echoed to UART.

Now when im sending the same character more than once, every second byte returned is not the character I sent.

I Debugged it to the point where the I can see that the RX Buffer (given to USBD_CDC_SetRxBuffer) is already wrong when the OTG_FS_IRQHandler is called.

What do I have to look for?

Outcomes