This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

XBYTE [] Addressing Problem

HI,

How to specify a address while writing to EEPROM in 89c51ED2.

It is writing to EEPROM when I give the following code after setting the flags of EECON register.


  XBYTE[0x0050] = '1';

But if I declare a variable with following type and assign a value to it, it is not writing to EEPROM

  unsigned char xdata *addr;
  *addr = '1';

//after setting all the flags i write this code for assigning;

 *addr = '2';

But this is not writing to EEPROM.

Kindly provide the solution for this.

Parents
  • Dear,

    The problem is thar this device contains internal XRAM and EEPROM how to write at the specific location in the EEPROM.

    Actually I used seprate pointer variable which contains the address where the data has to be stored but it is not storing in the EEPROM.

    Kindly send the program which solves the above problem that would be great help form U.

Reply
  • Dear,

    The problem is thar this device contains internal XRAM and EEPROM how to write at the specific location in the EEPROM.

    Actually I used seprate pointer variable which contains the address where the data has to be stored but it is not storing in the EEPROM.

    Kindly send the program which solves the above problem that would be great help form U.

Children
No data