Hello this is my first post here, but i'm using PicBasic Pro since some years. Here's my problem : I have to make a program with 2 interrupts source. The first Interrupt source is on RB0/Int, after many try and read, I decided not to interrupt this one but only scan INTCON.1 and make my main code around that. The second interrupt source is by receiving a Serial signal. I can't use the Hardware Serial Port cause it's inverted and it don't work with my circuit (I've tried with a PIC16F688 that have an Enhance Serial Port but PicBasic doesn't seems to support this one... but this is another story). So I use a RB4-7 Port change Interrupt. Everything seems to work fine but when I receive serial data, it doesn't return to the main code.

Here is what my code looks like :

'I'm using a 16F627 @ 20 MHz
'Naturally my prog start with all the define, registry settings and var

INTCON = %10001000 'Enable RB Port Change and GIE

ON INTERRUPT GOTO RECEIVE

START :
IF INTCON.1 = 1 THEN
'My main code is here and everything work before receiving serial data
'.........
INTCON.1 = 0
ENDIF
GOTO START

DISABLE
RECEIVE :
SERIN2 RXPIN,6,[DAT05,DAT04,DAT03,DAT02,DAT01]
LED = ~ LED
INTCON.0 = 0
RESUME
ENABLE


The LED tell me that my serial data is received and it toggle each time I send serial data. But the program never return to the main section. Any help will be appreciate Thanks