Lance, what is the real purpose for using the diode in the first place?
Seems to me a diode-mixing solution for power supplies
Correct, hippy. Ok, Tex, you asked for it.
It may be too xmas-tree-like, belts and suspenders plus an additional belt.
I want to have a motion sensor plus DS18B20 outside the door to my porch, and inside another DS18B20 and 60-LED dollar store light, monitored by a picaxe 14M2 with connection to my network using an ESP8266 D1 mini module (sending UDP messages).
The problem is, what happens if mains goes out (I've looked a many aspects of this problem over the last dozen or more years). The D1 mini draws a fair amount of current for a few seconds as it is turned on with a low-side switch when the picaxe has something to report. There's a nice Wemos 18650 battery shield (
https://www.ebay.com/itm/Micro-USB-Wemos-ESP32-18650-Battery-Shield-V3-ESP-32-LED-for-Arduino-Raspberry/183458100976 ) (dual battery module for me), but as Andreas Spiess says here (
), and as my testing has shown, if the battery is run down, it won't recharge if the draw is too great upon the return of mains power.
I propose 3 power sources--5V from a 2A mains power supply, 5V from the 18650, and 4V5 from 3-AAs. These are diode-mixed and run through a 5V-3V3 DC-DC converter. I monitor each of the 5V sources and variously throttle back on reporting if mains or 18650 is absent. If only 4V5 is present, maybe only transmit daily "I'm alive" messages and motion alarms and no LED.
If mains returns after the 18650 is drawn down low enough to switch off, there should be no draw on the 18650 battery, so the low-current charge should work until the battery develops enough voltage for the high-current charge to start up.
Here's the circuit (for some reason, all my icons at the top of this window are greyed out, so I can't insert links or images as I have in the past--only attachments) (ignore the 2-pin 3V3 battery connector on the left--it's gone from my plan, but not yet from the PCB, so I can't remove it without there being some traces removed which I want to keep):
And the dollar store light, which draws about 1.5A @ 5V.
It's a nice, bright light. A different type burned out for me after a few minutes at 5V. A different one of this type has been always on for me for two months, so it seems fine at 5V.
Suggestions for improvements will be much appreciated.