I find it's best to put a PAUSE 100 at the very top of the program (before anything) so that the ICD has something to latch onto before it goes wacko with interrupts.
Each of the include files disables debugging within that include by default.
But they also ENABLE it again at the end of each file.
Moving the first disable down to after the includes might help.You must also disable ALL code used by the interrupt handlers.Code:INCLUDE "DT_INTS-18.bas" ; Base Interrupt System INCLUDE "ReEnterPBP-18.bas" ; Include if using PBP interrupts INCLUDE "Elapsed_INT-18.bas" ; Elapsed Timer Routines Disable debug ASM INT_LIST macro ; IntSource, Label, Type, ResetFlag? INT_Handler TMR1_INT, _ClockCount, PBP, yes endm INT_CREATE ; Creates the interrupt processor ENDASM @ INT_ENABLE TMR1_INT enable debug
You can not debug the actual interrupt code because it could interrupt any debug information already being sent at the time the interrupt occurs.
Well, I should say that you CAN debug the interrupts, but only if the entire rest of the program is disabled. And the time it takes to communicate with the ICD makes it so you will miss many hundreds of interrupts in the process, so what you see may not be what you expect.
<br>




Bookmarks