I am using 6713 chip. In my project, I used the NMI interrupt to call the ISR, and I also want to return the main() to continue the program after the ISR is finished. However, after ISR is finished, the code cannot return the main(), do not know where it goes. The codes are like as followed.
main()
{
..................
while () { // waiting the NMI ISR
k = k+1;
}
.....................
interrupt void nmiISR (){
........... return;}
Who can help me to fix this problem? Thanks
Greetings,
Please follow details below
Good Luck,
Sam
Firephenix,
Please look at the C6000 Optimizing Compiler User's Guide and search for both the "interrupt" keyword and then for "NMI".
You probably should remove the "return" statement from your ISR, but I am not certain that is a problem. For safety, please remove it.
NMI requires special handling, which you will find in the Compiler UG, the pragma NMI_INTERRUPT.
Regards,RandyP
Search for answers, Ask a question, click Verify when complete, Help others, Learn more.