Skip to main content
olebenny
Associate II
Jun 15, 2022 6:38 PM UTC
Solved

I am using AzureRTOS on STM32F407/417 and need to add USB to my project. I have alrerady a few tasks run on my target, but how do I actually add USBX ?? Are there any examples from ST, that shows this ??

..

This topic has been closed for replies.
KDJEM.1
KDJEM.1Best answer
ST Technical Moderator
Jun 16, 2022 1:31 PM UTC

Hi @olebenny​ ,

Many examples project that use Azure RTOS USBX are available in CubeIDE as shown in the below figure. 0693W00000Ns1M8QAJ.pngFor more explanation, I advise you to follow these links to know how to use the USBx for AzureRTOS applications:

Kaouthar

To give better visibility on the answered topics, please click on "Best answer" on the reply which solved your issue or answered your question.

7 replies

KDJEM.1
KDJEM.1Best answer
ST Technical Moderator
Jun 16, 2022 1:31 PM UTC

Hi @olebenny​ ,

Many examples project that use Azure RTOS USBX are available in CubeIDE as shown in the below figure. 0693W00000Ns1M8QAJ.pngFor more explanation, I advise you to follow these links to know how to use the USBx for AzureRTOS applications:

Kaouthar

To give better visibility on the answered topics, please click on "Best answer" on the reply which solved your issue or answered your question.
olebenny
olebennyAuthor
Associate II
Jun 19, 2022 2:03 PM UTC

Hello Kaouthar

Thank you for responding.

I am using STM32 Cube IDE v1.9.0 and STM32 Cube MX V 6.5.0.

If I select the USB example Ux_Device_DFU for NUCLEO-F429ZI I get the 'old' USB-code, that works with FREERTOS, not the Azure_RTOS + USBX.

Unfortunately, Azure_RTOS and USBX are not part of 'my' Cube MX for direct selection, I have to select it through 'Software Packs --> Select Components'.

Here I can select 'STMicroelectronics X-CUBE_AZRTOS-F4' and in that sub-tree, I can select 'RTOS ThreadX' and 'USB SUBX'.

I have already succeeded doing this with 'RTOS ThreadX' for NUCLEO-F429ZI as well as our own STM32F417 board by following this article:

How to create a Thread using AzureRTOS and STM32CubeIDE?

It describes in easy understanding steps what to do with Cube MX and Cube IDE.

Best regards

Ole

mohamed.ayed
ST Employee
Jun 20, 2022 7:32 PM UTC

.

olebenny
olebennyAuthor
Associate II
Jun 20, 2022 8:29 PM UTC

Hello AYEDMSTM

Your screenshot show exactly, what I selected under 'Software Packs --> Manage Software Packs'.

I then also under 'Software Packs --> Select Components' selected 'RTOS ThreadxX' and 'USBX', and I think I now got it imported to my project. Now I just have to figure out how to use it.

Please see attached screenshots.

Best regards

Ole

olebenny
olebennyAuthor
Associate II
Jun 21, 2022 7:11 AM UTC

Hello AYEDMSTM

Thank you for your email, nice description. I will save it for future reference.

How do I tell USBX which USB-device on the STM32F407/417 to use ??

Best regards

Ole

mohamed.ayed
ST Employee
Jun 21, 2022 7:54 PM UTC
olebenny
olebennyAuthor
Associate II
Jun 22, 2022 6:33 AM UTC

Hello AYEDMSTM

Thank you for pointing this example.

And even better, I found an example for NUCLEO-F429ZI, which I happen to have 7 pcs of, as the STM32F429/439 are quite similar to STM32F407/417.

Best regards

Ole

Software Development, FAE

**Amended by Moderation, please, do not share personal contact details in the public feed**