Page 1 of 1

Interrupt Macro

Posted: Wed Sep 12, 2012 10:34 am
by MarkW
Hello

Using 18F2620 to capture 8bit data on port using strobe on INT0. Does the FC interrupt
macro clear the interrupt flag automatically when entering the ISR (interrupt service routine)?
Also, does it automatically re-enable the INT0 when exiting the ISR?

Reason, i ask is that using interrupts before using a different compiler, you have to clear the interrupt
flag.....and the interrupt is re-enabled when exiting the routine(typically a RETFIE asm command).

Flowcode is awesome :D (for lazy guys like me)

Cheers

Mark

Re: Interrupt Macro

Posted: Wed Sep 12, 2012 10:42 am
by Enamul
Hi,
Does the FC interrupt macro clear the interrupt flag automatically when entering the ISR (interrupt service routine)?
Yes, clear the interrupt flag is in the interrupt handler code and so it's done automatically.
Also, does it automatically re-enable the INT0 when exiting the ISR?
INT0 is enabled after exiting from ISR..if you not disable that using disable macro in main program..

Re: Interrupt Macro

Posted: Wed Sep 12, 2012 9:57 pm
by MarkW
Hi Enamul

Thanx for confirming this about interrupt flags etc....

I suspected that smething like this was been done, otherwise the interrupt would be re-cursive all the time.

Thanx

Mark