Bird
0
0

You want to ensure that a critical sensor interrupt always preempts a less important communication interrupt. How should you configure NVIC priorities for SENSOR_IRQn and COMM_IRQn?

hard📝 Application Q15 of 15
ARM Architecture - Exception and Interrupt Model
You want to ensure that a critical sensor interrupt always preempts a less important communication interrupt. How should you configure NVIC priorities for SENSOR_IRQn and COMM_IRQn?
ASet SENSOR_IRQn priority lower than COMM_IRQn (e.g., SENSOR=0, COMM=1)
BSet SENSOR_IRQn priority higher than COMM_IRQn (e.g., SENSOR=2, COMM=1)
CDisable COMM_IRQn and enable SENSOR_IRQn only
DSet both priorities equal and enable both
Step-by-Step Solution
Solution:
  1. Step 1: Recall NVIC priority rules

    Lower numeric priority means higher priority and can preempt others.
  2. Step 2: Apply to SENSOR and COMM interrupts

    To let SENSOR_IRQn preempt COMM_IRQn, SENSOR_IRQn must have a lower priority number.
  3. Final Answer:

    Set SENSOR_IRQn priority lower than COMM_IRQn (e.g., SENSOR=0, COMM=1) -> Option A
  4. Quick Check:

    Lower number = higher priority = SENSOR_IRQn preempts [OK]
Quick Trick: Lower priority number means higher interrupt priority [OK]
Common Mistakes:
  • Assigning higher number for higher priority
  • Disabling interrupts instead of prioritizing
  • Setting equal priorities expecting preemption

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More ARM Architecture Quizzes