Sorry to post on this old theme. But what you suggested, Scott, seems not to be only a little trick to shorten the processing time. Sometime it is crucial. If two interrupts flags are set - and you want only one interrupt to trigger the ISR - AND you have interrupt routines for both interrupts, you have to ask, if the interrupt enable flag AND the corresponding interrupt flag are set. To avoid problems I always use your code to determine which interrupt source has triggerd the ISR: btfsc intcon,t0ie btfss intcon,t0if goto check_intb0 goto handle_tmr0_int check_intb0 btfsc intcon,inte btfss intcon,intf goto check_tmr1 goto handle_intb0_int Martin > From: Scott Dattalo [mailto:scott@dattalo.com] > Sent: Tuesday, April 11, 2000 12:31 AM > One little trick I and others use to speed up the ISR is this: > btfsc intcon,peie > btfss pir1,rcif > goto check_next_int_in_list > If the interrupt is not enabled, then it can't be the source. > So the first BTF > will skip the second and the next possible interrupt source > is checked. If the > interrupt is enabled but the interrupt flag is cleared, then > this interrupt > isn't the source.