??? 03/24/10 16:22 Modified: 03/24/10 16:26 Read: times |
#174477 - No compiler support for EEPROM Responding to: ???'s previous message |
The 5131 has several different memory areas.
You have the 8051 standard DATA and IDATA. If you have external memory as XDATA. You also have some on-chip RAM that you can access as XDATA if you set the sfr's appropriately. Most 8051 compilers will handle the DATA, IDATA, XDATA and CODE memory accesses. They may use different names. I am not aware of any 8051 compiler handling the EEPROM transparently like say an AVR compiler might. You will need to write an EEPROM_read(ads) and EEPROM_write(ads, value) function to access the on-chip eeprom. You can extend these functions to write integers or longs. Just write your program to call these access functions. Then write the actual functions and place in a library. They will come in handy for other projects. Your 1k of eeprom is very handy for configuration data. You won't store many novels in this amount of space. But hey-ho, you have written your program to access some arbitrary non-volatile memory via standard functions. If you need more memory, you add SPI or I2C eeprom to your pcb, and access via the same API. David. |
Topic | Author | Date |
Atmel 89C5131A-UM Internal memory programming | 01/01/70 00:00 | |
compiler specific | 01/01/70 00:00 | |
Reply | 01/01/70 00:00 | |
Sample code? | 01/01/70 00:00 | |
Timers | 01/01/70 00:00 | |
Timers Reply | 01/01/70 00:00 | |
Have you looked at the tutorials yet? | 01/01/70 00:00 | |
it's all for assembler - but that doesn't matter! | 01/01/70 00:00 | |
Huge amounts of data | 01/01/70 00:00 | |
disregard the large numbers | 01/01/70 00:00 | |
No compiler support for EEPROM | 01/01/70 00:00 | |
compiler handling the EEPROM transparently | 01/01/70 00:00 | |
I did not know Keil helper functions. | 01/01/70 00:00 | |
It's part of the "xdata banking" support | 01/01/70 00:00 | |
Previously, on 8052.com...![]() | 01/01/70 00:00 |