Community

Reading and Writing to EEprom

Reading and writing to EEprom has many pitfalls when using the read and write buffers. I needed to save less than 50 strings that I could read and write to EEprom. The unique part of my application is that strings of any length can be written and read. I posted the code here:

Coincidence, I’ve just written a basic library for the AT24Cxx (specifically, the AT24C32). I took the approach of dealing with raw byte arrays with the idea of expanding the number of data types in the future.

Regards,
Mark

I’ve been using Microchip 25AA1024 EEPROMs (1 Mbit) over SPI with my Netduino Mini (and GHI Cerb 40) using the fine class and documentation from Dave Van Wagner:
http://techwithdave.blogspot.com.au/2012/03/eeprom-shield.html
https://github.com/davervw/DVW.MCP.MCP25AA1024

A key note from my experience:
GPIO_PIN_13 on the Netduino Mini DOES NOT WORK for SPI chip select. In fact, that pin may not work FOR SPI CS for any .NETMF device as of .NETMF 4.3. I ended up using GPIO 17.

John

Hey Mark,

Curious if the library you wrote for the AT24Cs could be used as a base or tweaked for AT28Cs…and if it would be possible for me to work through the differences. Wondering if maybe the core differences might just be the pin layout.

Best regards,
Jon Rothlander

Assuming you are talking about chips like the Atmel AT28C256 then there are fundamental differences between the two types of chip.

The AT24C series use I2C as a communication protocol. Address and data are sent to the chip as serial data over 2 pins.

The AT28C use a number of address and data pins in parallel to transfer data between say a microcontroller and the memory chip.

Regards,
Mark