Circuit Library: Introduction

This is a collection of small circuits I have built to test out an idea or fill a need I had during building another project. I hope you can find something useful here.

Motor H-Bridge Driver

This is a simple motor driver I wanted to play with after observing a fuel pump layout at work. It used 4 valves and a compressed gas powered pump that could only spin in one direction to both fill and drain the fuel tanks.

Seeing this valve layout in front of me, made the concept I had briefly heard about an “H-Bridge Driver” for motors, suddenly make sense to me. When I got home I build a few different versions of this circuit. Some used MOSFETS, some BJTs, this circuit is the one I had the best results with, however the MOSFET one probably would have worked better if I had more suitable parts available.

The circuit works by opening “valves” on opposing sides, to change the direction current flows through the motor in the middle. To spin the motor forwards, pin A and pin D are pulled high. To run the motor in reverse, pin B and pin C are pulled high.

Swipe the Image from Left To Right to Reverse Current Flow

Logic Table for the H-Bridge Driver

This logic table shows the control required for operation. It shows that as well as forward and backwards, there is an additional Brake mode available, as well as two logical inputs that produce dangerous results. This happens if we bring A and C high, and/or B and D high, as in either of these cases there is effectively a short circuit between Vcc and GND.

H-Bridge Driver – Illegal Logic Condition

We need to ensure that we allow some time between alternately driving pins to ensure we do not have a short circuit condition as shown above.

Implementation

This is the layout I made using the schematic above, I also added in a master speed control using a low side MOSFET, although this could probably be done by applying PWM to pins A, B, C & D, this would have significantly increased the complexity of the code required to control the circuit, and I wanted to keep things simple. Ideally this circuit would have some isolation between the Control pins, PWM pin and the microcontroller. Shorting the pads in black takes the speed controller out of circuit to make it function as the schematic above.


NAND-Gate Schmitt Trigger Oscillator

This is a fun little noise maker. 4 controls that interact to produce a huge range of output waveforms. I have had a lot of fun recreating vintage Sci Fi sound effects with this circuit, and it works brilliantly as a waveform generator to play with some subtractive synthesiser ideas. I like running it through a filter to emulate some D&B bass sounds.

If this circuit is sharing common power with other audio equipment, you may wish to add decoupling caps across the power rail, as close to the IC as possible. This will help stop signal bleed through on the power supply. I used a 100n and a 100p soldered directly to the power pins on the IC, as it was only after building it I discovered the issue.


9v Voltage Inverter

This circuit outputs the inverse of the voltage input. Useful for supplying inverted voltage for Positive Ground vintage guitar FX, or for bi-polar power supply requirements for op-amps or synthesiser style circuits.


This layout is adapted from the power supply section of a Mastro: Filter, Sample & Hold.

I included two options for Vin, as some circuits may require as close to Vin as possible for correct function, and the voltage drop over the diode might reduce the voltage too much for some use cases. The 12.1v Zener was documented on the M:F/S&H schematic, and provides some additional overvoltage protection, but removing it will not affect the function of the circuit.


6v Lead Acid Battery Charger

To make sure this circuit is adjusted for the battery it is charging, we need the following information:

Input:
Battery Voltage (Vb)6 v
Battery Capacity (Cb)4.5 Ah
Outputs:
Charging Voltage (Cv)No more than 1.5 x Vb6 v < Cv <= 9 v
Max Charging Current (Cc)10% Battery Capacity0.45 A / 450 mA

The trimpot should be adjusted until the output roughly matches the values in the table.
A multimeter can be inserted in series with the battery to keep track of the current, which will drop off as the battery increases in voltage.

If I wanted to make this standalone, I could use the small 7 segment display Volt/Amp meters available from online stores for a few pounds.

This circuit should also be capable of charging 12v Lead Acid Batteries by replacing the 5.1v zener with an 11.1v zener diode.


9 Way Stratocaster Wiring Scheme

Wiring scheme for an SSS Stratocaster with 2 push pull tone pots. Gives a total of 9 unique pickup selection options, including some Parallel and some Series options. I particularity like option (B)2 for psychedelic clean sounds.

(A) Both Push-Pull Pots Down:Normal Strat Wiring
(B) Tone 1 Push-Pull Up:
1Neck & Bridge (Parallel)
2All Pickups (Parallel)
3Middle
4Middle & Bridge (Parallel)
5Bridge
(C) Tone 2 Push-Pull Up:
1Neck
2Middle & Neck (Parallel)
3Middle
4Neck & Bridge (Series) & Middle (Parallel)
5Neck & Bridge (Series)


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.