- Wed Jan 29, 2020 1:48 pm
#85469
Don't despair, most probably your chip is OK.
This crashloop happens when the normal chip initialization fails for some reason, and so a reset occurs, then again, and again, and so on. But this means that the CPU is OK and the flash is most probably OK.
The most probable cause for this is a weak power supply. At initialization, when the wifi transceiver is being powered on, it consumes a hell lot of power, so if you have a weaker power supply (like a partially drained battery), it can draw so much current that the voltage drops from the nominal 3.3V below the minimal 2.5V, an there you have a power glitch. If this happens with the module in some circuit, try to power it up separately.
Another probable cause is a noisy power supply, like most switching mode buck-converter voltage regulators. Try to add two capacitors in parallel the power line, as near to the ESP8266 as possible: a 10-50 uF electrolytic and a 20..100 nF ceramic. The big one helps buffering out the bigger power surges, the smaller one reduces the noise somewhat.
A third possibility is a slowly rising power. The ESP8266 powers on at 2.5V, but the serial eeproms usually start at 2.7V, so if the power rises so slowly that the CPU tries to access the eeprom but it's not yet ready, that can cause trouble. When you try to power on the module separately, pull the CHIP_EN input to high with a 10k resistor (as usual), but initially short it to ground (I mean manually), and only remove this after you switched on the power.
And last the phenomenon I encountered, after doing all those above
.
When I leave the ADC pin just floating, the board boots up fine every time. When I connect the ADC pin to some analog input (in my case, between 0.5V and 1V, clamped below 1V by diodes for safety), then it doesn't boot and produces a crashloop similar to your case.
Now, the ADC can be used for measuring the voltage of this pin, but also for measuring the Vcc, and about this case the ESP8266EX Datasheet says (at "4.9 ADC"):
"...
Measure the power supply voltage of VDD3P3 (Pin3 and Pin4).
Hardware Design: TOUT must be floating.
...
When vdd33_const = 0xff, the power voltage of Pin3 and Pin4 will be tested by the internal self-calibration process of ESP8266EX itself. RF circuit conditions should be optimized according to the testing results.
..."
So, my suspicion is that either during this internal self-calibration, or somewhere in the framework code I use (PlatformIO) there is a Vcc measurement, and then it causes a failure if the ADC pin isn't floating freely.
I'll do some more investigating about what are the exact conditions of the ADC pin that causes my crashloop, but yours can easily be because of another cause.
Anyway, check your power supply and try to power up the module separately. It's much easier to pinpoint a problem if you can find a 'known-good' setup and then try to change it towards the real environment step-by-step
.
Good luck!