Teensy 4.1 PSRAM and flash

To add another potential failure source of the PSRAM chips, in my case it was Lyontek bought few years ago at LCSC: if the chips were stored for a longer period of time and not backed to remove any moisture they can fail while reflowing, either with hotair or in an oven.
I've had this happen a few times this year. Not a single case if the chips are hand soldered with an iron without heating up the chip's body.
 
I conducted tests with the following setup (see picture):
  1. Teensy 4.1 powered standalone at 5V via the Vin and GND pins using a stabilized power supply.
  2. USB connection to PC with a cable that only carries D+ and D- signals, along with GND (with +5V from the PC removed).
  3. Adafruit IC PSRAM 64Mbit SPI 133MHz 8-SOIC (Digikey code: 1528-4677-ND) soldered onto the smaller bottom pad.
  4. Winbond W25Q128JVSIC flash (Digikey code: W25Q128JVSIQ-ND) soldered onto the larger bottom pad.
  5. Firmware: A simple program that checks the presence of both PSRAM and Flash (attached to this post).

Observed Behavior (I have the video but it is too large to be attached here):
  1. The board draws 100mA for a few seconds.
  2. After some time, the current starts to increase gradually up to 140-150mA.
  3. Eventually, the current fluctuates unpredictably, jumping between 120mA and 140mA.

I conducted the same test using a Teensy 4.1 without PSRAM and flash, and the current consumption remained perfectly stable at 100mA.

When I mount the Teensy on my custom board, using a dedicated firmware, a similar but slower behavior is observed:
The current starts at around 150mA and gradually rises to about 220mA.

I suspect that this phenomenon is due to the quality of the PSRAM chip and may be temperature-related, as the behavior seems to worsen with time.
 

Attachments

  • test_PSRAM_flash.ino
    1.1 KB · Views: 15
  • setup.jpeg
    setup.jpeg
    489.3 KB · Views: 18
I soldered a brand new flash chip onto a new Teensy and it is working absolutely fine absorbing a constant current = 106mA. I'll add the PSRAM and see what happens
 
I added the PSRAM. The board drew approximately 107 mA for about half an hour, during which the Teensy successfully recognized both the PSRAM and the flash memory. After that period, the current gradually increased to around 130 mA, and the flash memory was no longer recognized. The issue definitely originates from the PSRAM. I have contacted DigiKey to inform them of the problem.
 
Sounds like good sleuthing on your part.

An increase in current could indicate that the chip is going into latch-up. If that happens it would probably get warm or hot due to the increased current flow. If it doesn't destroy the chip, that condition can only be cleared by a power cycle.

If that is in fact what is happening, that could lend some credibility to @h4yn0nnym0u5e theory that they might actually be 1.8V parts that are running on the edge at 3.3V.
 
I'm running a quick test here on the board with both chips. Monitoring current with the simple display on my bench power supply.

Here's a photo when I started. The current has increased slightly over about an hour, now showing 0.111 and sometimes 0.112.

1766165303377.png
 
I added the PSRAM. The board drew approximately 107 mA for about half an hour, during which the Teensy successfully recognized both the PSRAM and the flash memory. After that period, the current gradually increased to around 130 mA, and the flash memory was no longer recognized. The issue definitely originates from the PSRAM. I have contacted DigiKey to inform them of the problem.
Is the problem still there after hard wiring a pullup resistor, say 100k, from VDD to Adafruit IC PSRAM /CS?
Reason for asking: when Teensy boots and searches for what might be soldered in the optional PSRAM and Flash, it may not have pulled high the other unit /CS pin. The EMC_22 might still be an undefined floating input while EMC_24 is already used with Flash traffic on the shared 4bits bidirectional bus. If floating EMC_22 aka /CS for PSRAM is deemed low at that time then PSRAM may be initialised to a state where it drives the 4bit bus to something else than what Flashrom is driving it to. One output says high, the other says low, so high current starts to flow…
Note also from datasheet that when powering up, Adafruit IC PSRAM /CS pin shall follow VDD. Without pullups that will not happen. This might be another cause for trouble.
 
Reason for asking: when Teensy boots and searches for what might be soldered in the optional PSRAM and Flash, it may not have pulled high the other unit /CS pin. The EMC_22 might still be an undefined floating input while EMC_24 is already used with Flash traffic on the shared 4bits bidirectional bus.
All of the pins are assigned to the FlexSPI module at the same time. It only pulls one low at any time.
(They also have their weak internal pull-ups turned on which would be active even if the module wasn't driving them.)
 
Ok, but reset state for the pin weak internal pullup is ‘off’. So what is it in the hardware that assures us that in between power on (or any) reset and executing the quoted initialisation code the /CS levels are really high? And follow VDD when booting?
 
Ok, but reset state for the pin weak internal pullup is ‘off’. So what is it in the hardware that assures us that in between power on (or any) reset and executing the quoted initialisation code the /CS levels are really high? And follow VDD when booting?
It doesn't matter what state they are before FlexSPI is initialized. When it does take over it drives the select pins for inactive devices high and that should be enough to prevent them from driving the bus - if they don't respect that they are faulty.
 
Have any alternate source PSRAM been acquired or seen to work?

After some years of PSRAM use this is the first note where this type of issue was reported.
The only occasionally recurring issue was due to unclean soldering where good soldering and removed flux showed them to function.
 
It doesn't matter what state they are before FlexSPI is initialized. When it does take over it drives the select pins for inactive devices high and that should be enough to prevent them from driving the bus - if they don't respect that they are faulty.

The datasheet says it does matter…

And what about the 150 us? Is that respected?
And keeping CLK low while /CE remains high - does it really do that? I mean how can it do that when pullups or pulldowns are still off?
Think also what might happen after a soft Teensy reset, these pins may float for a while, when they float they may see random patterns as they pick up noise from nearby pins or pcb traces.
Same datasheet says something on max CLK frequency and how that can/must be way below 133 MHz. Does the code really respect also that?


IMG_0598.png
 
The datasheet says it does matter…

And what about the 150 us? Is that respected?
And keeping CLK low while /CE remains high - does it really do that? I mean how can it do that when pullups or pulldowns are still off?
Think also what might happen after a soft Teensy reset, these pins may float for a while, when they float they may see random patterns as they pick up noise from nearby pins or pcb traces.
These potential problems simply don't fit the symptoms; the PSRAM and flash chips wouldn't identify themselves when requested if they hadn't finished initializing or were stuck in some other sort of undefined mode.

Same datasheet says something on max CLK frequency and how that can/must be way below 133 MHz. Does the code really respect also that?
Read the code and find out.
 
These potential problems simply don't fit the symptoms; the PSRAM and flash chips wouldn't identify themselves when requested if they hadn't finished initializing or were stuck in some other sort of undefined mode.


Read the code and find out.
I connected a scope and checked if the Teensy 4.1 PSRAM power-up initialization timing is as per Adafruit IC PSRAM 64Mbit SPI 133MHz 8-SOIC 'shoulds' in datasheet, ref datasheet page above. It does not. I see ~20 ms in between VDD active and CE# going high. Only 4 us after CE# went high, it goes low again.

I'd say that there's a 20 ms window after power on where all PSRAM digital input pins could be anything depending on where the wind blows from. If it sits nearby to a cell phone or any other RF noise source then it will likely see all sorts of possible instructions, it may not finish its 150us self reset/init steps, and may thereafter behave 'out of spec'.

(I don't have flash or PSRAM chips fitted, I was just curious to see).
 
it may not finish its 150us self reset/init steps, and may thereafter behave 'out of spec'.
If it was in some "out of spec" / uninitialized state it wouldn't respond with a valid ID (which includes a self-test pass/fail result) when interrogated by the Teensy.
 
Back
Top