2
\$\begingroup\$

I am trying to add an SPI RAM to my ESP32D on my custom PCB.

On the first revision of the PCB, I screwed up, so I am trying to make it for the next revision.

The ESP32D already uses SPI to handle the Flash and others modules. As per my understanding, I could use remaining SPI 2 or SPI 3 for the RAM. But because I use the CANbus decoder, which shares some pinouts SPI 3 uses, I took the SPI 2.

My schematic is as follows:

enter image description here

As per my understanding, Quad SPI cannot be used as the ESP32 has not the required 2 extra SD lines to wire to, right? Therefore, should I wire the SPI RAM's SIO 2 and 3 pins to ground?

Additional advice and support by those experienced in the matter are very welcome, to help me avoid mistakes and improve the new design.

Data sheets:

\$\endgroup\$
0

2 Answers 2

1
\$\begingroup\$
  1. Have you considered instead the WROVER module, which already has integrated SPI RAM?

  2. Where did you get the idea QSPI isn't supported? The WROVER uses QSPI for its integrated SPI RAM, and both modules use QSPI for the integrated flash.

  3. Even if you really must stick with the WROOM and add your own SPI RAM, the WROVER is proof that it's possible to add your own SPI RAM with a quad link. (All the pins that connect to the WROVER's integrated SPI RAM are exposed externally on the WROOM, so you can wire the flash IC up in the same way the WROVER does.)

  4. I was under the impression pin selection is unrestricted for the SPI controllers other than the first one. You could use any available GPIOs for 1x, 2x, 4x or even 8x modes (if you had a chip that supported it).

  5. That said, I'm not actually sure that the memory-mapped mode (for SPI RAM) (1) works with SPI2 or SPI3, or (2) works in modes other than 4x/QSPI. If you really need to do this, please check the ESP32 Technical Reference manual (for the chip, not the module) to verify what's supported here.

enter image description here

\$\endgroup\$
2
  • \$\begingroup\$ WROVER: definitively, we are trying to make an alternative version by removing the peudo-SRAM module and replacing the esp32 with a WROVER. But the point is that we are struggling to fit it to our PCB, as the footprint of the WROVER is about 5 mm longer than the WROOM. \$\endgroup\$ Jan 20, 2022 at 13:26
  • 1
    \$\begingroup\$ @StéphanedeLuca Fair enough, if it won't fit (and you can still fit the external IC). Then I suggest you look at the WROVER's schematic (in its datasheet) to see how its SPI RAM is connected, and wire yours the same way. This is known to work, though you have to configure the SoC for it (there are menuconfig options in ESP-IDF if that's what you're using). Final note: SPI RAM is very slow compared to the internal RAM! Be prepared for that! \$\endgroup\$
    – TypeIA
    Jan 20, 2022 at 13:32
0
\$\begingroup\$

From the LY68L6400 datasheet based on Table 2 : Table 2 from datasheet

As you use the SPI mode I would leave SIO[2] and SIO[3] pins floating.

Worst case it should not you can solder a little wire to ground or VCC.

If you plan on making a 3rd "production" PCB you can put jumpers on the SIO[2] and SIO[3] pins and try different possibilities

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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