Think is has already been reported but can you give me a work around or fix

Bond

New Member
setint %00000000,%00001000

main:
pulsin 3,0,w0
do while w0<10
pulsin 3,0,w0
loop

gosub strobe_flash


goto main


'----------------
strobe_flash:
pulsout 1,150
pause 50
pulsout 1,150
pause 100
return


'======================
interrupt: 'off state
do while pin3=0
high 1
loop


low 0
setint %00000000,%00001000
return

This should be that while there is some sort of input on input 3 (pulse or not)then it should stay out of the interrupt routine but the moment I lose connection on input 3 I need to turn things on like pin one and stay there until input 3 see something again (not matter what else is going on).

I do not understand why the first time around it all looks ok and then on the 2nd or third time I take the siginal away from input 3 it gets stuck on the return from the interrupt routine.

this is all happening in the simulator I have not tried to see if it works for real as it would be difficult to provide ,exspesserly as it appears not to work on the simulator.


Hope this makes sence (by the why this is on the PICAXE-08M simulation)
 

Technical

Technical Support
Staff member
This is a do...loop bug in the simulator we are working on a fix for. What happens is the second do-loop actually loops back to the do line of the first do...loop, which eventually causes a stack error.

It will be fixed in the next release.
 
Top