Hi Carol, some general comments here, and specific comments in code. Good start, just needs some tidying up First, try to be consistent. For example, you use a mix of banksel and setting status bits directly. Either work but not quite so easy to read (for you, most importantly). Better to stick with banksel throughout Also the mixed cases and variables. For example you've set radix to decimal but use d'57' and then just 6 Secondly, I personally prefer to assign code locations with org. I think yours should compile correctly into memory though from 0x0005 Do you use tabs ? The line alignment is very staggered. Spaces are better. Tabs are the devil's work > GOTO $+4 This would be much safer jumping to a label, although what it jumps to (clear TMR1) is not necessary > CLRF TMR1L ; I do not know if it is necessary > to clear register TIMER1 once interruption is serviced (I guess it is done > automatically) > CLRF TMR1H True. TMR1 = 0000 is the cause of the interrupt. By resetting TMR1 you've lost time, as it had already advance past 0000 > ; ------------------------ > ; FUNCTION OF PORT A PINS > ; ------------------------ > MOVLW 6 > MOVWF ADCON1 ; All pins digital I/O > BCF STATUS,RP0 ; RAM bank 0 This bit of code is never accessed because of the goto right before it -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist