Bird
0
0

You have multiple ISRs that must notify a single task to handle different event types. Which FreeRTOS mechanism best allows the task to efficiently determine which events occurred without missing any?

hard📝 Application Q8 of 15
FreeRTOS - Interrupt Management
You have multiple ISRs that must notify a single task to handle different event types. Which FreeRTOS mechanism best allows the task to efficiently determine which events occurred without missing any?
AUse an event group where each ISR sets a unique bit and the task waits on the event group
BUse separate binary semaphores for each ISR and the task waits on all semaphores sequentially
CUse a single queue where each ISR sends a different event code and the task reads from the queue
DUse task notifications with eSetValueWithOverwrite action from each ISR
Step-by-Step Solution
Solution:
  1. Step 1: Understand multiple event signaling

    Multiple ISRs need to signal different events to one task.
  2. Step 2: Evaluate options

    Event groups allow each ISR to set a unique bit atomically, and the task can wait on multiple bits simultaneously.
  3. Step 3: Compare alternatives

    Separate semaphores complicate waiting; queues require parsing; task notifications with overwrite risk losing events.
  4. Final Answer:

    Event groups with unique bits per ISR -> Option A
  5. Quick Check:

    Event groups efficiently handle multiple event bits [OK]
Quick Trick: Use event groups for multiple ISR event flags [OK]
Common Mistakes:
  • Using task notifications with overwrite losing events
  • Waiting sequentially on multiple semaphores
  • Using queues without event differentiation

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More FreeRTOS Quizzes