On May 16, 2007, at 11:54 AM, Lee Marshall wrote: > wouldnt clearing pclath modify the program counter and > before i could move to to address 0. > This seems to be a common misunderstanding. PClatH is NOT part of the program counter. Changing PClatH does not have any effect upon the PC, and changing the PC (ie Call, Goto, Ret) does not change PClatH. The "lat" part of PClatH stands for "LATCH"; this register (or these bits in some other register) latch the bits that will be moved into PCH (the ACTUAL PC register, high bits) the next time an instruction modifies the PC (but doing something to PCL directly.) So "goto" takes 8 low bits from the instruction itself, and the remaining bits from the latch, while "ret" restores all (>8) bits of the PC but doesn't do anything to PClatH. BillW -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist