Hi Team,
My customer has a question regarding a piece of code they are trying to implement.
In the code below, they are trying to prevent INT7 from being invoked.
IER &= ~(1 << 7); IER |= (1 << 7);
However, when they compiled it with optimization level 2 and ran it, they realized that this still generated INT7.
They believe the optimization is allowing the interrupt to occur and changed it to below.
void disable_int7(void) { IER &= ~(1 << 7); } void enable_int7(void) { IER |= (1 << 7); } disable_int7(); enable_int7();
Would this prevent INT7?
Best regards,
Mari Tsunoda