eeprom programming

Go To Last Post
2 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi All,

I'm working on a project that require a lookup table. The table is in eeprom.

I'd like to program the eeprom with the following for example:
address content
10 55
11 54
12 63
13 47

20 21
21 98
22 125
23 115
24 66
etc.
How can I accomplish this in C (CodeVision)? Quick and easy way offcourse :-)

Thanks.
Yungky

admin's test signature
 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

In CodeVisionAVR it's very simple:
Example:

eeprom int table[5]={1,2,3,4,5};

main() {
int j;
// read data from EEPROM
j=table[2];

// write data to EEPROM
table[3]=100;

// stop here
while (1);
}

Cheers

Pavel Haiduc
HP InfoTech
http://infotech.ir.ro