AnsweredAssumed Answered

Active interrupts after MCUXpresso restart?

Question asked by Ed Arrington on Jan 8, 2020
Latest reply on Feb 5, 2020 by Alexis Andalon

We are currently using MCUXpresso 11.0.1 to develop a project using LPC4330 processors (M4 with M0APP).  Our application uses interrupts to manage a few time-dependent processes.  If we set a breakpoint inside one of these interrupt processes, that interrupt is obviously active.  Here's the problem.  If, while at a breakpoint, we simply use the IDE restart button to restart, the active interrupt REMAINS ACTIVE through the restart per the system control block (SCB) ICSR register.  Because the SCB shows an interrupt active, any new interrupts being initialized--that have the same or lower priority--cannot run.  Ever.  The processor appears to continually wait for the active interrupt--which occurred prior to the restart--to complete.  But the interrupt cannot complete because the debugger has restarted the application and the code has been restarted.

I don't recall having this issue with LPCXpresso version 8, but it is consistent and repeatable in MCUXpresso version 11.0.1.

Did something change in MCUXpresso?  Is a processor reset no longer done during a debug restart?


Related:  I have looked for a way to reset the SCB->ICSR (read only) register to convince the processor that no interrupts are running, but cannot find a programatic method (obviously a full software-load restart will work, but then whats the point of the debug restart?).  If I can just clear the SCB-ICSR register, I believe this problem goes away.


Is there another solution that can get past this restart issue?


Thank you for recommendations or help!