> > xorlw (0x08 ^ 0x1C) ; CV541 > > btfsc STATUS,Z > > retlw CVAR_29 > > xorlw (0x1C ^ 0x02) ; CV515 > > btfsc STATUS,Z > > retlw MAX_BRIGHT > This is not very good programming because....... What you said Olin and also it would be much more readable if all those ghastly btfsc STATUS,Z were replaced with skpnz Being so many, a simple lookup/comparison table might be better -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist