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

Keil RTX Task, FIQ & SW IRQ Interraction

Hello,

Besides an RTX task polling, is there any glue that interconnects an FIQ with an RTX task?

Details below and thank you for your help,
Lonnie

Details
I have a peripheral driver (ARM Cortex) that is asynchronous and triggers an FIQ when it receives data. The FIQ analyzes the data (checks to see if it had received the correct closing sequence). Now, somehow I need to inform an RTX task that the complete set of data has been received.

Since FIQ cannot call RTX functions, how can I inform the task that there is data ready?
I can only think of polling.

Unless, there is some way to mate an RTX software interrupt to the peripheral?

Parents
  • Is this what you mean?

    // DO NOT CALL THIS FUNCTION FROM PROGRAM CONTEXT - ONLY FROM FIRMWARE INTERRUPT CONTEXT !!!
    void report_event_to_application(logical_id a_logical_id, int32u a_signal)
    {
            task_info_t *lp_task_info = g_task_info ;
            int32u           l_index = NUMBER_OF_APPLICATION_USER_TASKS - 1 ;
    
            do
            {
                    if (lp_task_info->logical_id == a_logical_id)
                    {
                            isr_evt_set(a_signal, lp_task_info->id) ;  // must not be invoked from program content - only interrupt mode
    
                            break ;
                    }
    
                    ++lp_task_info ;
            }
            while ( (l_index--) > 0 ) ;
    }
    

Reply
  • Is this what you mean?

    // DO NOT CALL THIS FUNCTION FROM PROGRAM CONTEXT - ONLY FROM FIRMWARE INTERRUPT CONTEXT !!!
    void report_event_to_application(logical_id a_logical_id, int32u a_signal)
    {
            task_info_t *lp_task_info = g_task_info ;
            int32u           l_index = NUMBER_OF_APPLICATION_USER_TASKS - 1 ;
    
            do
            {
                    if (lp_task_info->logical_id == a_logical_id)
                    {
                            isr_evt_set(a_signal, lp_task_info->id) ;  // must not be invoked from program content - only interrupt mode
    
                            break ;
                    }
    
                    ++lp_task_info ;
            }
            while ( (l_index--) > 0 ) ;
    }
    

Children