SPI Serial EEPROM design

Hello:

I'm starting up a new desing using 4 Atmel AT25HP512 devices connected to a 4 wire SPI interface.

My question is does anyone have an over view (pseudo code) of hew to Initialize Read Write Enable Write

These devices. I've got all the C code writen but I'm missing something

Thanks In Advance. George

Reply to
GMM50
Loading thread data ...

Doesn't the data sheet explain it?

I'm using Atmel IIC EEPROMs at the moment, so I don't have the SPI version data sheets handy, but the last time I used Atmel SPI EEPROMs, the data sheet explained exactly what you needed to do.

--
Grant Edwards                   grante             Yow!  "THE LITTLE PINK
                                  at               FLESH SISTERS," I saw them
                               visi.com            at th' FLUROESCENT BULB
                                                   MAKERS CONVENTION...
Reply to
Grant Edwards

It helps to have a logic analyzer hooked up so that you can check your signals against the datasheet.

Reply to
Jim Stewart

A 4-channel digital scope will works just as well. A 2-channel scope is a bit more cumbersome, but will do in a pinch.

--
Grant Edwards                   grante             Yow!  I wonder if I ought
                                  at               to tell them about my
                               visi.com            PREVIOUS LIFE as a COMPLETE
                                                   STRANGER?
Reply to
Grant Edwards

Well I'm more stuck in how to unlock the device. It powers up with writes disabled. I've read the data sheets and it metions that I need to set the control register and issue a write enable command. But the details are vague. And the order of these in not at all clear.

These are relative new devices so perhaps I should look at the previous versions data sheet for clues.

george

Reply to
GMM50

SST have similar SPI parts.

SST25xxxx

There is example C code commands available from

formatting link

Here's the driver

formatting link

JG

Reply to
Joe.G

Also check out

formatting link

Reply to
Joe.G

1) make sure you have the /WP pin pulled or strapped to VCC. 2) send WRSR,0 to enable writing to all blocks (BP0,1). 3) send the WREN instruction. that sets the WEN bit in the status reg.

you can read the status reg to see if is setup correctly. BP0,1 should all be low to write-enable all blocks. WEN should be high to enable writing.

Hope that helps.

- Richard

Reply to
Richard Willis

Forgive me for being slightly off topic but have you not thought about replacing the eeprom with serial flash ?

Regtards Spen

Reply to
Spen

These EEPROMs store system information and are constantly changing. So I need the 100K writes of EEPROM.

What is Serail FLASH???

george

Reply to
GMM50

I think I'm doing this but...

To write enable the devices, should I do a WREN (write enable 8 bit command) then WRSR (write Status Reg 16 bit command) or in the opposite order?

I don't always see the WEN bit set in the statyus registers????????? Some days yes today no.

I can see the status going busy after the above sequence.

I read all ones.

THanks george

Reply to
GMM50

If you need lots of frequent updates, you might investigate the SPI Ferro-Electric RAM (FRAM) from RAMTRON.

Mark Borgerson

Reply to
Mark Borgerson

I found my problem. THis device only supports 128 byte writes. One needs to get to a 128 byte boundary and then send 128 bytes of data. Unsent bytes will be undefined.

Actually Atmel support guided me through all this. Good Job Atmel.

And thanks to all who replied.

gm

Reply to
GMM50

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.