Hi, I am using keil C compiler using AT89S8252 as target device. I am good at assembly but a beginer for C language. Using C language, I need to know how do we store and retrive the data in code and eeprom area as we can do in assembly language for the look up tables like 'movc a,@dptr' Thanks for the help. -arun
"I am good at assembly but a beginer for C language." You should start with the sample projects in the uVision Getting Started Guide. "Using C language, I need to know how do we store and retrive the data in code and eeprom area" This is not standard 'C' - you need to use the special language extensions provided by Keil - see the C51 Manual for details: http://www.keil.com/support/man/docs/c51/c51_le_memareas.htm http://www.keil.com/support/man/docs/c51/c51_le_memtypes.htm
You declare variables in the program store (code) memory by using the extension keyword code, e.g. U8 code someByte; I don't know what kind of EEPROM you have. If it's a parallel interface and the address decoding logic maps it into data store, you'd most likely want to declare the data xdata and const. U8 const xdata someEepromByte; As Andy says, the compiler manual has all the details. The data sheet for your particular part will describe how to access its built-in EEPROM (assuming it has one).