Hello,
What will the following piece of code do?
... key = Hwi_disable(); CriticalFunction(); Hwi_restore(key); // outer restore ... void CriticalFunction() { newKey = Hwi_disable(); EvenMoreCritical(); Hwi_restore(newKey); // inner restore }
If nesting is allowed - Interrupts will not be active until 'outer enable' will be called. If not, however, interrupts will be enabled right after 'inner enable' is called.
Which one is it? Can you nest Hwi_disable and Hwi_restore calls?
Thanks
Nitay