EINT2 interrupt hangs
Posted: Sat Nov 02, 2013 11:32 pm
I just bought a new ARMmite from Coridium. The new ARMmite runs a "Hello World" test just fine.
It hangs when EINT2 (IO15) is brought low the first time. The code simply ceases to execute. Here is the test code.
--------------------------------------------------------------------------
'Interrupt Test Code
SUB HandleInterrupt
PRINT "Processed interrupt."
ENDSUB
MAIN:
ON EINT2 FALL HandleInterrupt
' The main run loop is endless
WHILE 1
PRINT "In loop."
LOOP ' End of run loop
END
------------------------------------------------------------
If IO15 is high when I hit RUN, the code executes the main loop, printing out "In loop." over and over until IO15 goes low for the first time. At that moment, execution ceases until I hit STOP and then RUN again.
If IO15 is low when I hit RUN, the code exits immediately without printing anything.
The red IO15 light on the processor board glows red when IO15 is low and goes off as expected as IO15 goes high.
IO15 has an intermediate level when the interrupt driving circuit is powered off and the IO15 light glows dimly.
When I removed the new ARMmite board and replaced it with the old board, the code shows the loop message and occasionally the interrupt message as expected. For example,
In loop.
In loop.
In loop.
In loop.
In loop.
IProcessed interrupt.
n loop.
In loop.
In loop.
In loop.
In loop.
The only change to the ARMmite boards I have made since unpacking them is to solder a 34-pin header into the IO pin holes.
The signal applied to IO15 is about 4.0 v when it is high and about 0,3 v when it's low.
Any ideas? Seems to me the new ARMmite is just not handling interrupts correctly.
It hangs when EINT2 (IO15) is brought low the first time. The code simply ceases to execute. Here is the test code.
--------------------------------------------------------------------------
'Interrupt Test Code
SUB HandleInterrupt
PRINT "Processed interrupt."
ENDSUB
MAIN:
ON EINT2 FALL HandleInterrupt
' The main run loop is endless
WHILE 1
PRINT "In loop."
LOOP ' End of run loop
END
------------------------------------------------------------
If IO15 is high when I hit RUN, the code executes the main loop, printing out "In loop." over and over until IO15 goes low for the first time. At that moment, execution ceases until I hit STOP and then RUN again.
If IO15 is low when I hit RUN, the code exits immediately without printing anything.
The red IO15 light on the processor board glows red when IO15 is low and goes off as expected as IO15 goes high.
IO15 has an intermediate level when the interrupt driving circuit is powered off and the IO15 light glows dimly.
When I removed the new ARMmite board and replaced it with the old board, the code shows the loop message and occasionally the interrupt message as expected. For example,
In loop.
In loop.
In loop.
In loop.
In loop.
IProcessed interrupt.
n loop.
In loop.
In loop.
In loop.
In loop.
The only change to the ARMmite boards I have made since unpacking them is to solder a 34-pin header into the IO pin holes.
The signal applied to IO15 is about 4.0 v when it is high and about 0,3 v when it's low.
Any ideas? Seems to me the new ARMmite is just not handling interrupts correctly.