Re: >As I said before, am I missing something or am I just fighting a >recalcitrant compiler? It may be worth your while to write the equivalent function directly in C, and look at the compiler's assembly-language output. or, put another way, write some C code that causes the compiler to uses movwf, and then copy that style. My success with PIC C when writing assembly routines (I do it only rarely) is to mimic exactly what I see in the .LST outputs of the compiler. I believe you'll find that _all_ movwf instructions that are compiler-generated apply a mask to the argument -- without the "exact same thinking" the compiler won't be happy with your assembly-level stuff. Out of curiosity, why write this in assembly at all? -- ______________________________________ Andrew E. Kalman, Ph.D. aek@pumpkininc.com -- http://www.piclist.com hint: The list server can filter out subtopics (like ads or off topics) for you. See http://www.piclist.com/#topics