Shop OBEX P1 Docs P2 Docs Learn Events
does the EEPROM pagesize 64 byte vs 128 byte matter? — Parallax Forums

does the EEPROM pagesize 64 byte vs 128 byte matter?

StefanL38StefanL38 Posts: 2,292
edited 2012-01-26 13:28 in Propeller 1
Hi I would like to use a 64 kByte EEPROM Microchip 24FC512-I/P instead of a 32kByte type Microchip 24AA256-I/P.

The technicial data says the 24AA256-I/P has a pagesize of 64 bytes, the 24FC512-I/P has a pagesize of 128 bytes.

Does this pagesize matter when using it with a propeller-chip?

If yes does anybody know of a 64kByte-EEPROM with pagesize 64bytes?

best regards

Stefan

Comments

  • MagIO2MagIO2 Posts: 2,243
    edited 2012-01-26 02:45
    I remember that once I changed the according constant in one of the drivers that write to EEPROMs ... currently I don't remember which one it was, propably the one from Mike Green.

    So, yes it somehow matters, but it's not a problem.

    The point is that the page-write mode should be preferred for multi-byte-continuous-access. Because in the byte-write-mode the EEPROM will erase the whole page writing back the content of all unchanged bytes by itself. So, byte-write-mode will erase the block 128 times if you do a continuous write of 128 bytes. This wears out the EEPROM much faster and of course takes longer.

    That's at least how I read the datasheet:
    http://ww1.microchip.com/downloads/en/devicedoc/21754m.pdf (page 10)
  • StefanL38StefanL38 Posts: 2,292
    edited 2012-01-26 03:58
    Hi MagIO2,

    thank you for your answer. Knowing to use the blockmode is important too. I should have been more precise about what I want to know.
    Does the pagesize matter for downloading code into the EEPROM ( I mean hitting F11 in the propeller-tool for writing the code into the EEPROM)?

    best regards

    Stefan
  • MagIO2MagIO2 Posts: 2,243
    edited 2012-01-26 04:52
    No ... I would not expect any problems and I'm pretty sure that I already used an EEPROM having a different pagesize. I also used RAMtrons FRAM in several setups which actually has no delay for write-operations and it works fine.

    Regards,
    Andreas
  • Dave HeinDave Hein Posts: 6,347
    edited 2012-01-26 06:11
    Software written for a 64-byte page size will work fine with devices that have a larger page size. The Prop's firmware is designed to work with a 24LC256, which has a page size of 64 bytes. It works fine with devices that have a page size of 128 bytes or even 256 bytes.

    However, if you write software that assumes a larger page size, it will not work properly with a 64-byte page size.
  • MagIO2MagIO2 Posts: 2,243
    edited 2012-01-26 06:42
    Hmmm ... I don't see the relation in 24LC256 and pagesize 64 bytes. If I remember right I once had a 24LC256 with a different pagesize. Pagesize for my understanding is not tied to the EEPROM size, but to the preference of the manufacturer. But I might be wrong with that and my internal memory plays tricks on me - this occurred to me when I started with the propeller some years ago.
  • Dave HeinDave Hein Posts: 6,347
    edited 2012-01-26 13:01
    You're probably correct that there are some 24LC256 chips with larger page sizes. The spec that I looked at had a 64-byte page size. The Prop manual and the spec sheet don't specify the page size. They only mention the use of the 24LC256 for the boot EEPROM.

    So you forced me to look at the source code for the booter that's stored in the Prop's ROM. It uses a page size of 64 bytes. As I said, this will work with EEPROMs that have page size of 64, 128, 256 or even larger. However, it would not work with an EEPROM that has a smaller page size, such as 32 bytes.
  • Duane DegnDuane Degn Posts: 10,588
    edited 2012-01-26 13:28
    FYI, most Propeller boards use the 64K EEPROMs. When I looked through my collection of Propeller boards, I could only find two that used 32K EEPROMs. They were the Demo Board and the Propeller Professional Development Board. (I've replaced the EEPROM on my PPDB with a 64K version.)

    I was surprised to learn a write byte command rewrote the whole page.

    So if you write 16 bytes, the EEPROM is erased 16 times?

    It seems like it would be a good idea to use a buffer in the Props RAM to read out the page and then write it back the edited bytes rather than writing multiple individual bytes.

    A couple of years ago, I used this technique to write to Winbond flash chips since the page had to be erased prior to being written. The chip (Winbond) itself didn't have an "edit" feature (IIRC).

    Do any of you know if any of the current EEPROM/I2C drivers use a buffer to save wear on the chip?
Sign In or Register to comment.