This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

In Stm32, Is that possible to use CMSIS USB driver(common access struct) for developing CDC device class application without any CMSIS RTOS ?

Hi,

I have the following question based on CMSIS USB Middleware driver:

1) In Stm32, Is that possible to  use CMSIS USB driver(common access struct) for developing CDC  device class application without any  CMSIS RTOS (neither with CMSIS keil RTX, Keil RTX5 or FreeRtos) nor with any OSthreading?

2) My main requirement is to use the same CMSIS USB driver software developed for Stm32 with CDC (Communication Device Class) device should be portable (re-use) the same code to other microcontrollers from atmel or texas instruments arm based MCU and MPUs.

Kindly let me know the possibilities.

Thanks,

Gokul.

  • Hello Gokul,

    The CMSIS-Driver API is designed to be generic and independent of a specific RTOS making it reusable across a wide range of supported microcontroller devices. Having said that, the same is true for CMSIS-RTOS v2. If you are using Keil RTX5 or the FreeRTOS port, it will run on any Arm Cortex-M based device, so no need to worry.

    Kind regards,

    Christopher

  • In addition to what Christopher said, please note that if you want to use MDK Middleware USB library, it is mandatory to use CMSIS RTOS v1 or v2, because MDK middleware requires CMSIS RTOS or FreeRTOS with cmsis wrapper to work.

  • Could you go into more detail about your concerns of an RTOS? USB is a very transactional, and time specific protocol, so by the time you would have implemented timers and semaphore like behavior, you would have almost re-implemented an RTOS.

    If you use the RTOS with the USB examples, you could run all of your code from a main thread - if you want to avoid anything RTOS related. 

    The CMSIS-RTOS is just a standard. it should work for any Cortex-M device. Find USB device CMSIS-driver might be more of a porting roadblock that the RTOS. http://www.keil.com/support/docs/3707.htm

    ======

    Another option for portability is to using the Freertos variant of the CMSIS-RTOS - since that is a 3rd party RTOS:

    http://www.keil.com/pr/article/1280.htm

  • Just out of curiosity, what is your application going to do? Won't the USB hardware and registers be very different on those different Chip Manufacturer's chips?