USB - STR71x and FreeRTOS

nobody wrote on Monday, January 02, 2006:


Do I need to make the RTOS handle all the USB standard requests or can I just let it happend in interrupts?

I will then use the RTOS queues for collecting data from the data endpoints.

Best regards,

Frank Andersen

nobody wrote on Monday, January 02, 2006:

Not quite sure what you are asking here.  You have the design choice of handling USB events from the interrupt service routine if you want.  If the event is going to take a long time to process then it is best to let a task perform the processing.  Maybe you want some events processed directly in the ISR and some passed to a task.

nobody wrote on Thursday, January 05, 2006:

Hello, I’m trying to do the same thing.  Use an str711 with usb and IAR.  What interrupt handlers do I need to include to get the usb to work, so far I only have an example of how to use the uart handler with freeRtos (that was included with the iar build)

thanks for any help

nobody wrote on Monday, January 09, 2006:

You need to write an interrupt handler like the one for uart


        EXTERN USB_Istr
        PUBLIC vUSBISREntry

; Wrapper for the USB interrupt service routine.  This can cause a
; context switch so requires an assembly wrapper.

; Defines the portSAVE_CONTEXT and portRESTORE_CONTEXT macros.
#include "ISR_Support.h"


    portSAVE_CONTEXT            ; Save the context of the current task.

    bl    USB_Istr            ; Call the ISR routine.

    portRESTORE_CONTEXT            ; Restore the context of the current task -
                                ; which may be different to the task that
                                ; was interrupted.


and then exchange the DefaultISR with vUSBISREntry at the USBLP_Addr and the USBHP_Addr

Best regards,

Frank Andersen