0

Background:

A few days ago I received a 23LC1024 1Mbit SRAM chip, which works like a charm. However, before I ordered that one, I ordered a LP621024D-70LL which also is a 1 Mbit SRAM but in DIP32 format, meaning LOTS of pins.

Now I made a breadboard setup with 3 shift registers 74HC595 to be able to set the address (tested with LEDs but should work).

However, when trying use a shift register for the data which can be read or write, I don't think I can use a 74HC595 since it is only for output. However, I also don't think a 74HC165 (shift in register) would work (if I had one).

Questions:

  1. What kind of shift register would I need, one that can do both input and output? I read about I2C registers but that seems to be a bit of overkill.

  2. I only have 74HC595 shift registers for setting the address, would that slow down SRAM? I mean are there faster registers? Not that I want to buy it, but just curious.

Here is a picture of a working LP621024D-70LL ... too bad the chip is barely visible , on the left are 2 74HC595s and right are also 2 (right one not used), these 3 shift registers take care of the address (17 bits -> 3 bytes). The SRAM itself is hidden under the center of the cables.

enter image description here

  • Would any of 74LS194, 74LS195, 74LS395, CD4035B be relevant? – James Waldby - jwpat7 Apr 7 '17 at 23:48
2

since you already have input, use an 74HC165 8-bit parallel-in/serial out shift register. They are cheap.

another cheap option with I/O is an expander like the PCF8574, which are almost cheap

  • Are you sure that a 74HC165 would work? Because since I now do not have any multiple-input-ic I use 8 pins which I have to set in Write mode for writing a byte, and Read mode for reading a byte. I have the 'feeling' I would need a 74HC595 for writing and a 74HC165 for reading but of course that is not possible simultaneously. – Michel Keijzers Apr 7 '17 at 22:37
  • 1
    The 75HC595 has an Output Enable pin. Use that to disable the outputs of the 595 when you want to read from the 165. You don't care about what the 165 does while you're writing with the 595, it's high impedance. – Majenko Apr 7 '17 at 22:47
  • 2
    Personally though I'd use an MCP23017 or MCP23S17 (depending on what bus I was using elsewhere at the same time). – Majenko Apr 7 '17 at 22:48
  • I think I will try a MCP23017 or the other ... just to try :-) ... however, I already know why using a 32DIP is not a good idea (I will post a picture) – Michel Keijzers Apr 7 '17 at 23:28
1

From the web page about the 23LC1024:

The memory is accessed via a simple Serial Peripheral Interface (SPI) compatible serial bus.

Using the SPI hardware on your Uno will be a lot faster than using software-based shifting. See my page about SPI.

  • Yes and I can fully confirm it now. To give a bit of background: I ordered a 23LC1024 but these are like 4$ and this chip above was like 1,50$. But it seems it is not worth all the extra wiring and for my project I need faster memory anyway ... I was hoping it would both be more than fast enough. But even because of the wiring I probably will not use easily this SRAM chip anymore. But I learned a lot about timing measurements, SPI and shift registers. – Michel Keijzers Apr 9 '17 at 0:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.