On a mechanical regulator, the cut-out contact allows current both ways. The cut-in voltage and reverse current system is to prevent the battery being drained by the dynamo at low revs.
You don't have that problem with the the electronic version.
I don't know enough about batteries to know if there's any harm in flowing current to a battery at a voltage less than that at which it can accept a charge. It could be that's a bug, not a feature: e.g., maybe it would help to warm up a cold battery. I was thinking I could kinda emulate the original regulator and cut in at a specified voltage, but once cut in, stay cut in until the Hall effect sensor shows a reverse current (but I would cut out at any reverse current, not wait for -2-5.5A). But that's all a "simple matter of programming" and could be configured later (if I add a second FET).
If the MCU could force total isolation (cut out), that might be useful in other ways: e.g., fault scenarios.
I'd run the regulator switch from the MCU; the ignition & voltage sense signals are there regardless, so you can control the whole thing as needed then.
(Plus the regulator would turn off when you force the ignition lamp on, as shown).
D'oh! I didn't really think that all the way through, did I? But, if I control the MCU's power supply regulator from the MCU, don't I have a bootstrap problem? Maybe I need to do both, with a diode OR at the ON switch of the 5v regulator. When the ignition switch is turned on, the power supply turns on and powers the MCU, and the MCU can then use a digital I/O pin to latch the power supply ON until it is done with it. (Bonus: allows for some kind of orderly shutdown sequence, if needed.)
Unless I stick a LiPo battery or something in there...
Re. the protection you mentioned earlier, you could add relatively large VDRs (eg. Zenamics) at each external terminal to help suppress transient spikes.
I will have to educate myself about those. I've been looking at
Transient Voltage Suppressor (TVS) diodes, e.g.: ON Semiconductor
500 Watt Peak Power MiniMOSORB Zener Transient Voltage Suppressors (one example of many).
I also just realised R7 is now in the wrong place, I only glanced at it last time. R7 should be to ground to hold the Q2 off with no signals,
Thanks, I'll fix that.
and the FET needs a resistor between gate and source to hold that off unless turned on.
I think that's what I had until I flipped source and drain to avoid the current drain problem. So, R7 just needs to move, right?
EDIT: Oh, I need to add another resistor so I have one between the FET gate and source, and another pulling Q2 base to ground.
You could add overvoltage protection there, to prevent a spike damaging the FET gate; a low value series resistor between Q2 and the gate and a zener across gate & source to clip the gate voltage; eg. 10V.
Sounds like a very good idea. Say, 100Ω? Maybe a TVS zener?
Also, I've been thinking that the D+ power must be dirty, dirty. I can watch the sparks fly from the carbon brushes on the commutator. And talk about inductive... I wonder if adding a capacitor or two from D+ to ground would help that situation? And maybe a TVS?
I remember from somewhere than 12V vehicle electronics are supposed to be rated to stand 60V transients!
I think a common problem is the "current dump", which happens then the car is going down the highway and the battery decides to open up (or the terminal falls off, etc.) The alternator regulator is slow to respond and there is a big, long, high-voltage, high-current surge. Luckily, my generator is pretty anemic and can barely raise 25v on an open circuit with DF shorted to ground. And, from the point of view inside the regulator, we're in charge of regulating any surges!