spansion S25FL132K flash module finally working... learnt some lessons

http://www.farnell.com/datasheets/1756776.pdf

:o Wrote the library while waiting for the chips and the breakout to arrive… and finally got to start testing.

The module itself really tested me as even with a magnifying glass and overhead light I was struggling to see the pin marker on the chip. Came in a SOIC-8 package which I have decided is as small as I will attempt.

1st lesson… flux flux and more flux. As the youtube demo showed… can’t have enough flux and this was correct. Also… for the first time I got the multi meter out to test each leg with the breakout pin and too my surprise… what visually looked like a good solder joint wasn’t.

So 2nd lesson… use a multimeter to check those IC → breakout solder jobs. (Also make sure one probe is on the top of the chips leg… and not on the bottom of the circuit board).

The wiring was straight forward and after some fiddling with code got values out of the chip for the JEDEC code which corresponded to what I expected… Success! Least I thought so.

To verify other functions I wrote data 0-255 to a single page and read it back to verify. I ended up with crap back…(about 50% of the data was different to what I expected) and after 1 day of hunting around and each one being a dead end I resorted in lowering the sclk rate until… with 15uS it read correctly. However this rate was no where near the 108Mhz on the data sheet. Given the Arduino Due is 84Mhz I should be able to toggle the clock full speed without problems. The other mystery was it only seemed to effect the read speed as I had found my initial page write did write successfully.

Another few hours elapsed and by this time I shortened all the data wires and … it was the same.

So… I could get it to work if I slowed the rate to a snails pace… or have a bit faster with errors when reading back :frowning:

I ended up shortening the vcc and gnd cable as well as they were still long for convenience while testing. The result… no glitches. I took the delays out and… it still worked.

I have no idea why but the long lead on the vcc/gnd only seemed to effect the read and only if the bus was fast.

Unlike a few other libraries on-line this uses low level bit-banging and utilizes the quad speed read using 4 data lines.

It's working in Quad mode for read/write operation?

Regards,
TJ

Hoek:
http://www.farnell.com/datasheets/1756776.pdf

:o Wrote the library while waiting for the chips and the breakout to arrive... and finally got to start testing.

The module itself really tested me as even with a magnifying glass and overhead light I was struggling to see the pin marker on the chip. Came in a SOIC-8 package which I have decided is as small as I will attempt.

1st lesson... flux flux and more flux. As the youtube demo showed... can't have enough flux and this was correct. Also... for the first time I got the multi meter out to test each leg with the breakout pin and too my surprise... what visually looked like a good solder joint wasn't.

So 2nd lesson... use a multimeter to check those IC -> breakout solder jobs. (Also make sure one probe is on the top of the chips leg... and not on the bottom of the circuit board).

The wiring was straight forward and after some fiddling with code got values out of the chip for the JEDEC code which corresponded to what I expected... Success! Least I thought so.

To verify other functions I wrote data 0-255 to a single page and read it back to verify. I ended up with crap back...(about 50% of the data was different to what I expected) and after 1 day of hunting around and each one being a dead end I resorted in lowering the sclk rate until... with 15uS it read correctly. However this rate was no where near the 108Mhz on the data sheet. Given the Arduino Due is 84Mhz I should be able to toggle the clock full speed without problems. The other mystery was it only seemed to effect the read speed as I had found my initial page write did write successfully.

Another few hours elapsed and by this time I shortened all the data wires and .. it was the same.

So.. I could get it to work if I slowed the rate to a snails pace... or have a bit faster with errors when reading back :frowning:

I ended up shortening the vcc and gnd cable as well as they were still long for convenience while testing. The result... no glitches. I took the delays out and... it still worked.

I have no idea why but the long lead on the vcc/gnd only seemed to effect the read and only if the bus was fast.

Unlike a few other libraries on-line this uses low level bit-banging and utilizes the quad speed read using 4 data lines.

Does your breakout board have deCoupling caps? 100nf at the chip?
Running it at full speed would tend to make long VCC,GND lines act as inductors, Depending on exact length and 3D shape you could have browned out the memory at high speed.

Chuck.