Archive May 2026

Low quiescent current, high side, NMOS timer delay off switch circuit and Ltspice model

When it comes to switching timer modules, most designs are either based on the good old 555 timer, or some kind of 8 bit MCU that performs supervisory functions (like turning a relay off and keeping track of time), with the advantage for the later to allow for various timing and delay on/off programs. Most designs however, draw hundreds of microamperes up to several milliamperes while idling. Since one common use of these timers is to power a load for a given time in off grids setups where stored battery energy must be conserved, a low quiescent current solution would be a preferable design. Most designs are also relay based. Sturdy relays have an advantage of providing NC/NO modes natively, tolerate inductive kickback from loads such as motors, and are immune to spurious turn-ons.

Here we present a fully solid state timer delay off high side NMOS switch, thus with low Rds ON. The power to the load is turned on through a pulse (such as one supplied by a spring loaded pushbutton), latches, and turns off based on the timing constant of a RC network.

Giving the maximum rating of the CD40106 Schmitt trigger used here, the maximum switched voltage is around 18V. A higher voltage rated Schmitt trigger inverter would allow 24V operation, and using MOSFET rated above Vds of 30V would push operation voltages into 48V or more.

Download

Operation.

The transient connection of the switch S1 discharges the capacitor C3 through D3 to ground, bringing temporarily the schmitt trigger input to ground potential. output of the trigger goes to logic 0V, while the inverting input goes to logic high. A CD40106 schmitt trigger can be used to implement complementary outputs, by daisy chaining two stages as shown in the schematic (A1 and A3). The operational parameters of the CD40106 at 12V have been calculated from the datasheet and added to the model.

In the low voltage state, the first inverting output of the schmitt trigger A1 is in logic high, sinking current into Q3 base, which has the effect to lower gate potential of PMOS M2, turning it on, and supplying bootstrap capacitor voltage to M4, which turns it on and performs the intended high side switching function, While schmitt trigger A3 output voltage goes 0V, turning M3 firmly off and preventing fast discharge of C1.

When the RC network charges back above Vhigh threshold, M2 is turned off, which has the effect of stopping the supply of voltage from the bootstrap capacitor to M4, and bringing the gate of M4 to ground through the turn on of M3. This effectively turns off M4.

Giving the low gate charge and leak of modern NMOS, the bootstrap capacitor C1 can supply voltage to the gate of M4 over a time far longer than the time constant of the RC network made with U4 + R3 and C3.

Note that M2 does not handle large currents in that circuit. A smaller footprint PMOS could be used, rated for logic Vgs levels (such as -5V)

Note that the transition Vhigh and Vlow voltage of the CD40106 used are linear functions of supply voltage, Which means that a higher or lower Vcc operation as supplied from a battery should not change the minimum and maximum delays achieveable significantly.

Resistor R7 acts as a current limiting resistor for gate current but also during switching of M2 and M3, which could temporarily provide a low impedance path to ground. Note that CD40106 propagation delay using two stages in a daisy chain have the effect of introducing a small dead time between M2 and M3 switching, thus mitigating that unwanted effect.

Do you require bespoke functionality ? We can help !

We can offer assistance and task offloading in audio projects, power electronics and metrology projects, MCU firmware development assistance and consulting. Feel free to contact us by mail at

and provide us a general description of your project and how you think we can help, so we can discuss further.

Our current areas of expertise :

  • Ltspice modelling for analog and mixed signals, and general drafting of circuits.
  • NXP iMXRT1060 based MCUs firmwares and rapid prototyping as well as EDA sketching
  • Assistance in coding for Steinberg VST3 plugins.
  • USB host and device modes for aforementioned MCU
  • DAC / ADC interfacing.
  • Proof-reading and review of LLM generated documentation.
  • Prompt engineering for general purpose electronic projects.

Standard rates :

From 40 EUR/hour depending on area of expertise, project complexity, and timing constraints.

Simplified Ltspice model of an electric guitar : magnet, vibrating string and pickup with core saturation.

Following is a Ltspice model of a vibrating ferromagnetic guitar string with a AlNiCo magnet and a coil pickup.

Model Download :

Dependencies :

TL072 Op-Amp model or any other Audio grade suitable op-amp

Explanation :

It assumes a single pickup with a copper wire wound around a Nickel Steel alloy core. Saturation is modeled.

In a realistic model, the magnetic excitation of the coil is as follows :

  • A) Magnet generates (magnetostatic equation) magnetic field. (2)
  • B) Vibrating string is magnetized. Creates a time varying magnetic field according to motion equations (1) & (4)
  • C) Time varying magnetic field is picked up by the coil wrapped around the pickup pole cores.

Because of the limitations of integration in Ltspice (time integral support, but not space integrals), the model of B) has been simplified – As if the magnet was vibrating like a string at a distance of the pickup, but taking into account geometry. A better model would be possible using “C++ black boxes” as it is possible now with QSpice, as the DLL engine is Turing complete which allows to render space integrals easily. The model of B) excited by A) is doable in QSpice and is explained in the paper (4). So B) has been simplified to a simple coupling parameter int the form of a factor “chi_wire” (or wire magnetic susceptibility).

Note that the code for such a model of B) has been explored as such, but not validated. It may be added here in a future release.

Finally the core Mechanical model is simplified and according to (1) :

It assumes a string displacement along the Z axis only, and bridge reaction is not modeled.

Bias magnetic field is modelled and as a notable contribution if the pickup core saturation is modelled.

Note that the coil is assumed to be wrapped around a single pole (as just one string is modeled), number of turns has been decreased to take into account the tighter magnetic coupling.

Pickup flux is the sum of self inductance times current + induced flux from time varying magnetic field. Since the preamp is very high impedance the current is negligible and only the EMF from the magnetic field has sensible contribution.

Finally a preamp has been added. (5)

References :

(1) Solving the Sound of a Guitar String
Jason Pelc
December 10, 2007
(Submitted as coursework for Physics 210, Stanford University, Fall 2007)

http://large.stanford.edu/courses/2007/ph210/pelc2/

(2) Magnetic Field of a Cylindrical Bar Magnet – Wolfram Demonstrations Project

https://demonstrations.wolfram.com/MagneticFieldOfACylindricalBarMagnet

(3) Analytical Functions of Magnetization Curves
for High Magnetic Permeability Materials

Mehran Mirzaei1 , and Pavel Ripka1
Faculty of Electrical Engineering, Czech Technical University, 16627 Prague, Czech Republic

https://ieeexplore.ieee.org/document/8356239

(4) Exact expression for the magnetic field of a finite cylinder with arbitrary
uniform magnetization
Alessio Caciagli 1, Roel J. Baars 1, Albert P. Philipse, Bonny W.M. Kuipers ⇑

(5) ELECTRIC GUITAR PREAMPLIFIER by EFI Bureau

https://www.electronicsforu.com/electronics-projects/electric-guitar-preamplifier