I have few questions about interrupts. I use ATmega169P.
1. If an logic change interrupt is triggered (say PCINT pin goes low to high), and if the context switching from main() to ISR takes 10usec,
a)what if the interrupt re-appears within 10usec?
b)what if some other interrupt comes DURING context switching (say timer0 expires when AVR was pushing variables in stack)?
2. During an ISR execution, if I dont explicitly cli() and sei(), how will AVR react to other interrupts? Are rest of the interrupts disabled till ISR is complete? While SERVICING PCINT ISR, if timer0 expires, how this is handled?
3. Is there anything like interrupt priority?
4. Is there something like interrupt queue? Say when PCINT ISR is serviced, timer0 expires, then INT0 gets an edge and another PCINT is triggered by key press. How this will be handled by AVR?
All of my questions are answered by some or other datasheet of AVR, and I would be happy if you could point me to correct source. Pardon me if these questions have already been asked before, and honestly, I did not search forum before posting this.
Thanks and regards,