|
|
View previous topic :: View next topic |
Author |
Message |
jaikumar
Joined: 15 Dec 2006 Posts: 109
|
Which is faster eeprom write/read or program mem write/read? |
Posted: Mon Oct 12, 2009 1:58 am |
|
|
Need info. Which is faster, i2c eeprom write/read or writing/reading chip
program memory ? And this for 18f2550.
Thanks and Regards,
Jaikumar. |
|
|
Ttelmah Guest
|
|
Posted: Mon Oct 12, 2009 2:25 am |
|
|
More complex than it might seem...
Read, is basically instantaneous. The time involved is setting up what address to access.
What takes the longest time, is _erase_. Typically 4mSec.
When talking to the EEPROM, the a byte 'write' cycle, is an erase/write cycle, so takes normally 4mSec (some of the latter chips have a faster cycle than this).
For the program memory, the erase block, is normally larger than a byte, so you have a 'block erase time (typically the same as the EEPROM erase), and then a 'write' time, which is normally faster, at perhaps 1mSec to 2mSec. Writing a single byte, is then slower (erase a block, then write a byte), but writing a few bytes is faster than writing the same number of bytes on the EEPROM, since you will normally have only one erase.
You then have to look carefully at which function you are using. Using 'write_program_memory', with a _block_ of data, that is the same size as the chip's erase block, will be faster to move the whole block, than to move a similar sized block to the EEPROM, but writing a single _byte_ to the EEPROM, will be faster than moving a byte to the program memory.
Remember to 'beware' the shorter write life of the program memory...
Best Wishes |
|
|
jaikumar
Joined: 15 Dec 2006 Posts: 109
|
|
Posted: Mon Oct 12, 2009 3:43 am |
|
|
Thanks for the info Ttelmah.
for my particular application, which is to read a pre programmed time info from eeprom/program memory and compare with and then turn on a alarm.
Which will be faster, As you have said above i think it will be the program memory am i right. Also let me know if the no of write time for program memory is the same as eeprom which is 100,000 write cycle.
Regards,
Jai Kumar. |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|