cancel
Showing results for 
Search instead for 
Did you mean: 

USB CDC using USBX on F411

mahirmahota
Associate III

I am just a bit confused about how the CDC examples using USBX work. In the sample I've seen it seems that the code sets up some sort of UART to USB bridge. I think I don't need the UART and wanted to send and process data like the classic library used to do. However, when I remove the UART code, the device enumerates but USBD_CDC_ACM_Activate is now never called. Is the UART essential to using USBX or did I miss something in refactoring the program?

1 REPLY 1
FBL
ST Employee

Hi @mahirmahota 

  • The UART in the USBX CDC example is just for bridging USB to a physical UART; it’s not required for USB CDC functionality.
  • If USBD_CDC_ACM_Activate is not called after removing UART code, it usually means the USB CDC interface is not fully or correctly initialized.
  • Check that your USB descriptors, endpoints, and USBX CDC class initialization remain correct and complete after removing UART. Make sure also, the CDC interface and endpoints (interrupt IN, bulk IN/OUT) are properly configured and enabled.

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.