On Mon, Dec 31, 2001 at 01:20:05AM -0000, Benjamin Bromilow wrote: > Hi all, > > Can I just check my thinking on something? I've checked the archives and the > datasheets and I can't get a straight answer.... > If I want to write to EEPROM on a 16F877, the data memory starts at 0000h, > doesn't it? Well yes and no. The data memory starts at address 0 of the data memory space. However in order to combine program and data memory in a single hex file, the data memory is shifted to a new address by convention. Only by agreement of the development tools does this convention work. > I ask because I want to use the [de] command to define some EEPROM data and > the only example I can find which uses it is in the MP-ASM help files... > which states > > org 2100h > de ".... Address 2100H is the new address by convention. It doesn't actually write to address 2100H. It simply tells the device programmer that this data is destined for the data EEPROM and to program it accordingly. > > That really confuses me! Would that write something in the program memory of > the EEPROM?? Bt convention, yes. > Or can the de command only be used to write to program memory (ie flash in > 16F877)? No. That directive is designed to write in the data EEPROM memory. > > Ben > > ps Merry Christmas to all and a happy 2002! Let's hope its better than > 2001....... Hope springs eternal..... Same to you and your, BAJ -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body