At 01:48 AM 8/2/2005 +0400, you wrote: >Hi Andy. > >Squeezing the lemon :) > >incf reg,F ;INCF REG >movlw 0x66 ;MOVLW 0x06 >addwf reg,F ;ADDWF REG >skpndc ;SKPDC >andlw 0xF0 ;SUBWF REG >skpnc ;MOVLW 0x60 >andlw 0x0F ;ADDWF REG >subwf reg,F ;SKPC > ;SUBWF REG ;;btw here Cy is always=1 Nice, Dimitry. The zero flag is valid, so it can be used for carry. BTW, if you substitute 0xA6 for 0x66 in the second instruction you get an increment for packed BCD seconds or minutes (0..59). Best regards, Spehro Pefhany --"it's the network..." "The Journey is the reward" speff@interlog.com Info for manufacturers: http://www.trexon.com Embedded software/hardware/analog Info for designers: http://www.speff.com ->> Inexpensive test equipment & parts http://search.ebay.com/_W0QQsassZspeff -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist