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

How to reset 24c01

How to reset all the bytes of AT24C01 to 0xFF using assembler language?

Thank you for your help

Parents
  • How you do it is independent of the language. You've read the datasheet, right? So you iterate through each of the 128 byte addresses, writing 0xFF to each address. That, or you iterate through each of the 128/8 page addresses, writing 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF to each page.

Reply
  • How you do it is independent of the language. You've read the datasheet, right? So you iterate through each of the 128 byte addresses, writing 0xFF to each address. That, or you iterate through each of the 128/8 page addresses, writing 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF to each page.

Children
  • Thank you very much.
    But what does the Memory Reset mean in the datasheet?
    Quoted from the datasheet:
    MEMORY RESET: After an interruption in protocol, power loss or system reset, any 2- wire part can be reset by following these steps:
    1. Clock up to 9 cycles.
    2. Look for SDA high in each cycle while SCL is high.
    3. Create a start condition.

    Reset to the former status.

  • "But what does the Memory Reset mean in the datasheet?"

    You might be misinterpreting "Memory Reset" to mean some kind of "Memory Erase". It is not. It refers to resetting the device's I2C state machine back to a known state so I2C transactions can resume in case they had been perturbed in some way.

    Oh, and my apologies, that device has 4-byte pages, not 8-byte pages.