Manu Abraham wrote: > isr > ; save registers > movwf w_tmp ; save w > swapf STATUS, w ; swap status > clrf STATUS ; bank0 > movwf status_tmp ; save status > movf PCLATH, w ; save pclath > movwf pclath_tmp > clrf PCLATH > movf FSR, w ; save fsr > movwf fsr_tmp > > ; actual ISR > bcf INTCON, INTF > bsf flags, LEDBIT > > ; restore registers > movf fsr_tmp, w > movwf FSR > movf pclath_tmp, w > movwf PCLATH > swapf status_tmp, w ; set bank to original > movwf STATUS ; restore > swapf w_tmp, f ; swap tmp > swapf w_tmp, w ; swap tmp -> w > > retfie How did this mess ever assemble? Opcodes are not allowed in column 1 else the assembler interprets them as labels. In any case, format properly if you want others to take it seriously. It would be a lot easier to look at if opcodes, operands, and comments were all nicely lined up in fixed columns. ******************************************************************** Embed Inc, Littleton Massachusetts, http://www.embedinc.com/products (978) 742-9014. Gold level PIC consultants since 2000. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist