Hello Bert,

Yes, you are right, I am using "ON INTERRUPT" and from the interrupt handler I accessed a subroutine placed outside. Putting "disable/enable" around that subroutine fixed the problem, but I will just copy that piece of code into the interrupt handler to avoid further problems. So far I am not ready to insert ASM code, so everything is in PICBasic.

I like Charles idea to put stack value onto display in the beginning of the main loop to check if there is a problem. In my case I needed it in the interrupt handler (where I now have this value slightly above zero) but the test of the main loop for zero value is just great!

Thanks, as usually you all are very helpful. Hope some day I will be able to help others too