This circuit works well.
It's not pretty, but it works superbly.
You could adapt the shown regulator to suit your own system, or could create a simpler one based on the same principle.
Example only: A zener diode fronm the output to the oscillator gate input would pull up the oscillator input when Vout exceeded the zener voltage "plus a little". This turns off the transistor.
![enter image description here](https://cdn.statically.io/img/i.sstatic.net/CEoZekrk.png)
Here is a related post from "The PICList in 2010"
I did something extremely similar* some years ago - even extending to the LDO with one Vbe drop which I used to
drive the SMPS feedback.
I guess in retrospect that I expected the drive clamp to work on whole cycles when regulation was reached BUT what actually
happened was that it adjusted the length of the drive pulses to maintain very smooth cycle by cycle regulation.
Intuitive in hindsight but a pleasant discovery at the time.
... It was used to provide a stable local supply for the logic core in the face of widely varying battery voltage** and
sudden very large and noisy electromechanical battery loads. AFAIR the CD40106 smps and 2 x LDOs quiescent
current loads and some logic idled "in regulation" at slightly under 100 microamps. (** 4 x C cells and some logic rated
at nominal 5 volts. Not a marvellous design initially).
Here we are. Seemed worth digging up.
Y' don't buy no ugly SMPS!
I hacked this out of the middle of a jpg with other irrelevant stuff
in it and cut and pasted it into left to right alignment using
Irfanview so the result is even less beautiful than the ugly original.
LH inverter is an oscillator with 2 x R + diode providing asymmetric mark/space.
RH inverter (RHI) drives transistor to provide drive to L21 which
"rings" to > Vbattery when Q21 is turned off.
When voltage on C22 at input of LDO regulator rises a Vbe drop =about
0.5 Volt above regulator output then Q22 starts to turn on.
If Q22 is turned partially on it will pull input of RHI high thereby
stopping drive to Q21.
The squeamish may wish to put a resistor betwixt Q22c and RHI pin 3.
If Q22 was turn hard on the drive would cease suddenly until C22
voltage fell far enough to turn Q22 off.
In practice Q22 turns on enough to be "modulated" by rising V_C22 to
reduce the effective length of the drive pulses to Q21. Look at it too
too hard and the logic begins to fail, but in practice this is what
happens.
The arrangement with Q22 and IC22 means that the LDO regulator is
always supplied with a voltage about 0.5 volt above its output. As
long as the LDO does not drop out with this delta-V it works well.
I show an LM2950, which is good enough for this, but the final version
used a superb and approx zero cost Taiwanese sourced LDO.
Frequency, mark space ratio and inductor values can be arranged to
suit. This would work well enough at milliWatts to Watts.
The 40106 allows very low Iq with no load.
I left R26 in, although its purpose is obscure - presumably it snubbed
a slight transient. Inductor value is high, reflecting low power level
here.
Note that the oscillator is loaded by the modulation but not stopped
and that right hand inverter only needs a sniff of signal SO this
system could 'borrow" a clock from anywhere available and us only a
single inverter. OR replace RH inverter with a MOSFET and pullup and
get a discrete parts add on smps.
1 x MOSFET, 2 x bipolar, L, C, LDO.