After migrating a working program from a 28x1 to a 28x2, I noticed an interrupt issue.
In a nutshell, I can't seem to get out of the interrupt routine...here's a test routine thats using INT 0 (B.0). It goes to interrupt when B.0 = 1, but keeps jumping back into the interrupt routine when B.0=0. Ive tried various combos of hintsetup and also issued a setinflags off
before the re-issue of the setinflags..this is in the sim and the 28x2 chip
Must be me but I can't see what i'm missing...
In a nutshell, I can't seem to get out of the interrupt routine...here's a test routine thats using INT 0 (B.0). It goes to interrupt when B.0 = 1, but keeps jumping back into the interrupt routine when B.0=0. Ive tried various combos of hintsetup and also issued a setinflags off
before the re-issue of the setinflags..this is in the sim and the 28x2 chip
Must be me but I can't see what i'm missing...
Code:
Hintsetup %00001001 'SETS INTERRUPT
main:
setintflags %00000001,%00000001
do
pause 2000
loop
interrupt:
if pinB.0=1 then interrupt 'loop until switch is released
for b1=0 to 5
high A.0
pause 1000
low A.0
pause 1000
next b1
setintflags %00000001,%00000001
return