The quick question is -- does the statement "hetREG1->INTENAC = 1;" immediately suspend the HET interrupt or does it take a few cycles, and if it takes a few cycles, why?
In my application, I have the HET bound to the FIQ interrupt, and I have some shared-data between this FIQ interrupt and a separate IRQ interrupt, so I have the need to temporary suspend the HET interrupt in order to update the shared data. My data suggests that after the line-of-code "hetREG1->INTENAC = 1;", the interrupt can still occur within the next few lines of code. My solution is as follows:
hetREG1->INTENAC = 1;
INLINE_NOP();
INLINE_NOP();
INLINE_NOP();
return();
And this appears to work 100% of the time; do these 3 NOPs after disabling the HET interrupt make sense, and if so, why?
Thanks,
Jim