@Bill, Thanks for confirming these chips don't wear out.
I just reread your FlexMem thread. You mentioned reading/writing a long at a time. I think I ought to consider adding read/write long methods to my driver. Since I can only address the SRAM in groups of eight bytes, I could treat these as two longs and probably gain some speed.
@Jazzed, Wow, our schematics are practically identical. (Not that there are very many options of wiring these chips.)
Code:
Vdd(3.3V)
23K256 │
│
┌────────────────┐ │ 10µF Capacitor is used to keep power clean.
┌──────┤1 !cs Vcc 8├───╋───── Vss
│ ┌────┤2 SO !HOLD 7├───┫
│ │ │3 NC SCK 6├───┼─┐
│ │ ┌──┤4 Vss SI 5├──┳┼─┼──── io
│ │ │ └────────────────┘ ││ │
│ └─┼────────────────────┘│ │
│ │ 100Ω │ │
│ │ 23K256 │ │
│ │ ┌────────────────┐ │ │
┣───┼──┤1 !cs Vcc 8├───┫ │
│ ┌─┼──┤2 SO !HOLD 7├───┫ │
│ │ │ │3 NC SCK 6├───┼─┫
│ │ ┣──┤4 Vss SI 5├──┳┼─┼──── io + 1
│ │ │ └────────────────┘ ││ │
│ └─┼────────────────────┘│ │
│ │ 100Ω │ │
│ │ 23K256 │ │
│ │ ┌────────────────┐ │ │
┣───┼──┤1 !cs Vcc 8├───┫ │
│ ┌─┼──┤2 SO !HOLD 7├───┫ │
│ │ │ │3 NC SCK 6├───┼─┫
│ │ ┣──┤4 Vss SI 5├──┳┼─┼──── io + 2
│ │ │ └────────────────┘ ││ │
│ └─┼────────────────────┘│ │
│ │ 100Ω │ │
│ │ 23K256 │ │
│ │ ┌────────────────┐ │ │
┣───┼──┤1 !cs Vcc 8├───┫ │
│ ┌─┼──┤2 SO !HOLD 7├───┫ │
│ │ │ │3 NC SCK 6├───┼─┫
│ │ ┣──┤4 Vss SI 5├──┳┼─┼──── io + 3
│ │ │ └────────────────┘ ││ │
│ └─┼────────────────────┘│ │
│ │ 100Ω │ │
│ │ 23K256 │ │
│ │ ┌────────────────┐ │ │
┣───┼──┤1 !cs Vcc 8├───┫ │
│ ┌─┼──┤2 SO !HOLD 7├───┫ │
│ │ │ │3 NC SCK 6├───┼─┫
│ │ ┣──┤4 Vss SI 5├──┳┼─┼──── io + 4
│ │ │ └────────────────┘ ││ │
│ └─┼────────────────────┘│ │
│ │ 100Ω │ │
│ │ 23K256 │ │
│ │ ┌────────────────┐ │ │
┣───┼──┤1 !cs Vcc 8├───┫ │
│ ┌─┼──┤2 SO !HOLD 7├───┫ │
│ │ │ │3 NC SCK 6├───┼─┫
│ │ ┣──┤4 Vss SI 5├──┳┼─┼──── io + 5
│ │ │ └────────────────┘ ││ │
│ └─┼────────────────────┘│ │
│ │ 100Ω │ │
│ │ 23K256 │ │
│ │ ┌────────────────┐ │ │
┣───┼──┤1 !cs Vcc 8├───┫ │
│ ┌─┼──┤2 SO !HOLD 7├───┫ │
│ │ │ │3 NC SCK 6├───┼─┫
│ │ ┣──┤4 Vss SI 5├──┳┼─┼──── io + 6
│ │ │ └────────────────┘ ││ │
│ └─┼────────────────────┘│ │
│ │ 100Ω │ │
│ │ 23K256 │ │
│ │ ┌────────────────┐ │ │
┣───┼──┤1 !cs Vcc 8├───┫ │
│ ┌─┼──┤2 SO !HOLD 7├───┘ │
│ │ │ │3 NC SCK 6├─────┫
│ │ ┣──┤4 Vss SI 5├──┳──┼──── io + 7
│ │ │ └────────────────┘ │ │
│ └─┼────────────────────┘ │
│ │ 100Ω │
│ │ │
│ │ │
csn Vss sck
I'm not sure if the 100Ω resistors are required.
They just seemed like a good idea.
What value of resistors are you using? I think individual capacitors on each chip is a better alternative to my single capacitor. The stack of DIP chips didn't lend itself to individual capacitors. The chips seem to work fine sharing the one capacitor.
I hope you do try my code on your SpinSocket-SRAM boards. Hopefully my code will be useful to you (and others). I'm always glad when I hear others are using my code. I feel like the time I spent writing the code was even more productive.
BTW: The 23K256 chips cost $1.14 each (when buying 25 at once from Digi-Key). The stack of eight chips cost $9.12.
Duane
PS I just hit "Preview Post". The schematic in the code block doesn't look very good in the preview. Hopefully it will look better in the actual post.
Bookmarks