Michael, On Wed, 26 Jan 2005 06:48:05 -0600, michael brown wrote: > > > movlw (1< > > iorwf FLAGS,f > > > > I can't for the life of me see what you're doing with this one (I must > be getting old! :-) - care to explain? > > He's setting up a bit mask. >...< Ah! Thanks for that - it's a Demon Tweak that I'd only seen a couple of times and hadn't understood before... > The assembler will build a literal that consists of a 1 left shifted 4 > bits (0x10) AND'd with a 1 left shifted 1 bit (0x02) AND'd with a 1 left > shifted 0 bits (0x01) resulting in a literal with a value of 0x13. This > is a clever way to help make the program oblivious to absolute bit > positions within the registers assigned to ports. ...and oblivious to this reader without an explanation - I am getting old, I'm sure :-( > This way you only > have to change the EQU to change pin assignments, and then recompile. > The assembler will fix the movlw automatically. Got it - thanks muchly! Cheers, Howard Winter St.Albans, England -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist