I am a novice hobbyist trying to learn to learn how to program a microcontroller. I am using Keil C51 ver 6.10 and UV2. After getting a project running, I read some application notes and decided that my code was not very professional (as expected) and tried to improve it. Now I can't get anything to work and I didn't save the working version. Here is the manifistation of my problem: A section of code calls a function that calculates a crc16 checksum passing two arguments -- a pointer to the message array and the length of the message. When I single step through the code I see that the information passed over with the function call has arrived properly. Then, the first two lines of code in the function are supposed to initialize two local variables to 0xFF. These two local variables are stored in data memory at D:0x06 and D:0x07. As I single step through the code, I note that the wrong memory locations are being written. After two steps, I have written 0xFF to memory locations D:0x0E and D:0x0F. That's an 8-byte offset! Later in the code, I assign the value in these local variables to another variable array to be returned to the calling routine. Here, the correct addresses are being used -- D:0x06 and D:0x07. To summarize: uchCRCHi = 0xFF writes to address D:0x0F (expected D:0x07) uchCRCLo = 0xFF writes to address D:0x0E (expected D:0x06) uchCRC[0] = uchCRCHi assigns the value from D:0x07 (as expected) uchCRC[1] = uchCRCLo assigns the value from D:0x06 (as expected) What have I done wrong?