diff --git a/usbd_cdc_if.c b/usbd_cdc_if.c --- a/usbd_cdc_if.c +++ b/usbd_cdc_if.c @@ -290,10 +290,13 @@ uint8_t CDC_Transmit_FS(uint8_t* Buf, ui /* USER CODE BEGIN 8 */ uint16_t i; + + // Zero out user TX buffer (EMZ FIXME: why bother?) for (i=0; i < sizeof(UserTxBufferFS); i++) { UserTxBufferFS[i] = 0; } + // Copy input buff to user TX buffer for (i=0; i < Len; i++) { UserTxBufferFS[i] = Buf[i]; }