AnsweredAssumed Answered

setting interrupt priorities

Question asked by Akshay Katare on Aug 17, 2016
Latest reply on Aug 20, 2016 by Akshay Katare

Hi,

 

I have following interrupts,

 

1)External interrupt at PORTA

2)LPTMR0

3)ADC0

4)PIT0

5)TPM1

6)TPM0

 

I have to set priorities as below written in brackets

 

1)External interrupt at PORTA       (0)highest

2)LPTMR0                                     (1)

3)ADC0                                          (2)

4)PIT0                                            (3)

5)TPM1                                         (4)

6)TPM0                                         (5)lowest

 

 

I have read many documents, through that I got following information.

 

There is register NVIC_IPRx.

In that register, four sections of 8 bits are there. Each 8 bit section is for respective interrupt.

But out of that 8 bits, only highest 2 nibbles are available for writing . Then how can I set priority for respective interrupt greater than 3(as through two bits we can set values only up to 3) ?

 

 

Please let me know proper procedure for setting priorities as listed above.

 

Thanks and regards,

Akshay.

Outcomes