cancel
Showing results for 
Search instead for 
Did you mean: 

Data Corruption with USB CDC communication

Aishwarya
Associate III

Continuous transmission of data of tx rate 500 samples per seconds(33 bytes per sample) using USB virtual com port(USB CDC).

USB mode - full speed

Transmit data to serial monitor using function CDC_Transmit_FS();

Received data on serial monitor is corrupted data, and this data corruption is not regular.

To solve this problem -

  • check the status of CDC_Transmit_FS() who check the state of variable(hcdc->TxState )
  • send data after multiples of 1millisecond window.
  • Set/reset flag continuous in CDC_TransmitCplt_FS() function.
2 REPLIES 2
James Murray
Senior
Aishwarya
Associate III

hi @James Murray​ 

Problem is, data get corrupted when high speed data(16500 Bytes per second) transmission takes place.