> movf portb,1 ;Read portB (into itself) to end mismatch condition > > What mismatch condition? Why is this necessary? What is really going on? For various design reasons, the interrupt-on-change circuitry uses a "current state" latch-word (4-bits) which is compared with the actual signals on port B. Any time such values are different, the PIC will set RBIF. While it might have been possible to use synchronizers so that the "current-state" latch-word would be updated automatically after setting RBIF, such a design would have been a little tricky in a context where there's no guaranteed clock (the CPU might be sleeping). To force the "current-state" latch-word to match the port-pin values, you must either read or write to PORTB. Note that if FSR is pointing to portB, a NOP or CLRW instruction may also have this function. I don't know whether a skipped instruction which [tried to] read PORTB would or not; I don't know how the skipping logic works.