cancel
Showing results for 
Search instead for 
Did you mean: 

CubeMX doesnt generate MX_USB_DEVICE_Init function when FreeRTOS+USB CDC (Device) are selected together

Javier1
Principal

0693W00000QNJXEQA5.pngI am using recently updated CUBEMX version 6.6.1

As soon as i enable FreeRTOS cmss_v2 in cubeMX the USB init disappears...

0693W00000QNJYCQA5.png 

 MX_USB_DEVICE_Init is nowhere to be found........

Available for consulting/freelancing , hit me up in https://github.com/javiBajoCero
1 ACCEPTED SOLUTION

Accepted Solutions

0693W00000QNPf9QAH.png 

there is not USB_DEVICE folder generated in my project

I realiced the USB files are located directly under src/ directory now.

The directories where cubeMX puts the usb files have changed?

MX_USB_DEVICE_Init needs to be put manually in main.c .

/* USER CODE BEGIN 2 */
 
 MX_USB_DEVICE_Init();
 
 /* USER CODE END 2 */

Available for consulting/freelancing , hit me up in https://github.com/javiBajoCero

View solution in original post

5 REPLIES 5
Javier1
Principal

No clue of what is going on yet....

this guy pulls it out without problem https://www.youtube.com/watch?v=QZaC2Qf5bJI and i believe we do the same steps.

i tried with CMSIS v1 ... same issue

Available for consulting/freelancing , hit me up in https://github.com/javiBajoCero

tried the same thing with cubeMX 6.3.0, same issue.

Available for consulting/freelancing , hit me up in https://github.com/javiBajoCero

That youtube video is uploaded on 16th october 2020.

This means the cubeMX version he uses should be older than 6.1.0

0693W00000QNPJ8QAP.png

Available for consulting/freelancing , hit me up in https://github.com/javiBajoCero

I tried out cubeMX

  • 6.1.0
  • 5.6.1

and the issue is still there, im starting to think its not a version problem

Available for consulting/freelancing , hit me up in https://github.com/javiBajoCero

0693W00000QNPf9QAH.png 

there is not USB_DEVICE folder generated in my project

I realiced the USB files are located directly under src/ directory now.

The directories where cubeMX puts the usb files have changed?

MX_USB_DEVICE_Init needs to be put manually in main.c .

/* USER CODE BEGIN 2 */
 
 MX_USB_DEVICE_Init();
 
 /* USER CODE END 2 */

Available for consulting/freelancing , hit me up in https://github.com/javiBajoCero