Fine grained interrupt masking (XC800/XC878)

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Not applicable
I'd like to do more fine grained interrupt masking, such as only setting EADC = 0 while reading from the variable my ISR stores the conversion result in.

EADC = 0;
adc7_copy = adc7;
EADC = 1;


My question is, will an interrupt be lost while EADC is disabled or will it be serviced once EADC is enabled again?

So far I've done all that masking with EA. But I'd prefer to make such locks not only as short, but also as narrow scoped as possible.
0 Likes
3 Replies
Not applicable
I've done some reading and now I think I'll get the desired result if I set IMODE = 1.
0 Likes
Not applicable
Yes, IMODE=1 is exactly what you need in this case
0 Likes
Not applicable
Thank you for the confirmation!
0 Likes