Circuit Design Patterns

Circuit Design Patterns #

Reusable circuit building blocks that every electronics designer should know. These patterns are proven solutions to common design challenges.

Pattern #1: Voltage Divider #

Purpose #

Reduce voltage level, create reference voltages, or provide feedback.

Circuit #

VIN ──┬── R1 ──┬── VOUT = VIN × (R2 / (R1 + R2))
      │        │
      │        R2
      │        │
     GND ──────┴── GND

Component Selection #

  • High impedance: R1 + R2 = 10kΩ - 100kΩ (minimal current draw)
  • Low impedance: R1 + R2 = 100Ω - 1kΩ (drive following stage)
  • Precision: Use 1% tolerance resistors

Breadpad Implementation #

1. Place Voltage Source (VIN)
2. Place Resistor (R1) from VIN to mid node
3. Place Resistor (R2) from mid node to GND
4. Add probe at mid node for VOUT

Common Uses #

  • Bias voltage generation (amplifier biasing)
  • Sensor signal conditioning
  • Reference voltage creation
  • Feedback networks

Pitfalls to Avoid #

  • Loading: Following stage resistance should be >10× R2
  • Power: P = V²/(R1+R2), check resistor ratings
  • Tolerance: Output varies with resistor tolerance

Pattern #2: Current Limiting Resistor #

Purpose #

Protect components (LEDs, transistor bases) from excessive current.

Circuit #

VCC ─── RLIMIT ─── Component (LED, Base, etc.) ─── GND

RLIMIT = (VCC - VCOMPONENT) / IDESIRED

Component Selection #

For LEDs:

  • VCC = 5V, VLED ≈ 2V, ILED = 10mA
  • RLIMIT = (5 - 2) / 0.01 = 300Ω → Use 330Ω (standard value)

For Transistor Base:

  • VCC = 5V, VBE ≈ 0.7V, IB = 100μA (for IC = 10mA, β = 100)
  • RLIMIT = (5 - 0.7) / 0.0001 = 43kΩ → Use 47kΩ (standard value)

Breadpad Implementation #

1. Calculate required resistance
2. Round to standard value
3. Place resistor in series with component
4. Verify with Operating Point analysis

Verification #

  • Measure voltage across resistor
  • Calculate I = V/R
  • Confirm current is as expected

Pattern #3: RC Low-Pass Filter #

Purpose #

Remove high-frequency noise, smooth signals, create time delays.

Circuit #

VIN ─── R ───┬─── VOUT
             │
             C
             │
            GND

Cutoff Frequency: fc = 1 / (2π × R × C)

Design Procedure #

  1. Choose cutoff frequency (fc)
  2. Select C (10nF to 100nF typical)
  3. Calculate R = 1 / (2π × fc × C)
  4. Round to standard value

Example: 1kHz Low-Pass Filter #

fc = 1kHz
C = 100nF (choose first)
R = 1 / (2π × 1000 × 100e-9) = 1.59kΩ → Use 1.5kΩ or 1.6kΩ

Breadpad Implementation #

1. Place Voltage Source with AC 1V
2. Place Resistor (calculated value)
3. Place Capacitor to ground
4. Probe at output
5. Run AC Analysis from 0.1×fc to 10×fc
6. Verify -3dB point at fc

Performance Characteristics #

  • Passband: DC to fc (flat response)
  • Transition: fc (gain = -3dB = 0.707)
  • Stopband: >fc (rolls off at -20dB/decade)
  • Phase shift: -45° at fc, -90° at high frequencies

Pattern #4: RC High-Pass Filter #

Purpose #

Block DC, pass AC signals, remove low-frequency noise.

Circuit #

         ┌─── R ───┬─── VOUT
         │         │
VIN ─── C         RLOAD (optional, to GND)
                   │
                  GND

Cutoff Frequency: fc = 1 / (2π × R × C)

Design Procedure #

  1. Choose cutoff frequency (fc)
  2. Select C (1nF to 10μF depending on fc)
  3. Calculate R = 1 / (2π × fc × C)
  4. Round to standard value

Example: 100Hz High-Pass Filter (Audio) #

fc = 100Hz
C = 1μF (choose first)
R = 1 / (2π × 100 × 1e-6) = 1.59kΩ → Use 1.5kΩ

Common Uses #

  • AC coupling between amplifier stages
  • Removing DC offset
  • Audio applications (remove rumble)
  • Differentiating circuits

Pattern #5: Voltage Follower (Buffer) #

Purpose #

Isolate high-impedance source from low-impedance load, prevent loading.

Circuit (Emitter Follower) #

VCC
 │
 R (collector load, optional)
 │
 ├─── Collector
 │
VIN ───┤ Transistor (NPN)
 │      │
 R      ├─── Emitter ─── VOUT
(base)  │
 │      R (emitter resistor)
GND     │
       GND

VOUT ≈ VIN - 0.7V

Characteristics #

  • Voltage gain: ≈ 1 (unity gain)
  • Current gain: High (β of transistor)
  • Input impedance: High
  • Output impedance: Low

Component Selection #

  • Base resistor: 10kΩ - 100kΩ
  • Emitter resistor: 100Ω - 1kΩ
  • Choose for desired output current capability

Use Cases #

  • Buffer sensor signals
  • Drive low-impedance loads
  • Impedance matching
  • Prevent loading of voltage dividers

Pattern #6: Common Emitter Amplifier #

Purpose #

Amplify small AC signals with voltage gain.

Circuit #

        VCC
         │
         RC (collector resistor)
         │
         ├─── VOUT (inverted)
         │
VIN ─C1──┤ Base
         │
    R1 ──┴── R2 (voltage divider bias)
    │        │
   VCC      RE (emitter resistor)
             │
            CE (bypass capacitor)
             │
            GND

Voltage Gain: Av ≈ -RC / RE (without bypass)
Voltage Gain: Av ≈ -RC / re (with bypass, where re ≈ 26mV/IC)

Design Procedure #

  1. Choose operating point: VCE ≈ VCC/2, IC = 1-10mA
  2. RE = (VCC/2) / IC
  3. RC = (VCC/2) / IC
  4. Design voltage divider: VB = VE + 0.7V
  5. R2 such that IR2 = 10×IB, then R1 from Thevenin
  6. C1 = large enough for low-frequency coupling
  7. CE = large enough to bypass RE at signal frequencies

Typical Values (VCC = 5V, IC = 1mA) #

  • RC = 2.2kΩ
  • RE = 1kΩ
  • R1 = 47kΩ
  • R2 = 10kΩ
  • C1 = 1μF
  • CE = 10μF
  • Gain ≈ -100 (with bypass)

Pattern #7: Pull-up / Pull-down Resistor #

Purpose #

Define default logic level when input is floating.

Pull-up Circuit #

VCC
 │
 R (10kΩ typical)
 │
 ├─── Signal (default HIGH)
 │
SW ──┘ (to GND when closed)

When switch open: Signal = VCC
When switch closed: Signal = GND

Pull-down Circuit #

Signal (default LOW) ───┬─── Switch to VCC
                        │
                        R (10kΩ)
                        │
                       GND

Component Selection #

  • Weak pull: 47kΩ - 100kΩ (minimal current, slow switching)
  • Standard: 10kΩ (most common)
  • Strong pull: 1kΩ - 4.7kΩ (fast switching, higher current)

Use Cases #

  • Microcontroller inputs
  • I²C bus (requires pull-up)
  • Button/switch interfaces
  • Enable/disable pins

Pattern #8: Transistor Switch #

Purpose #

Control high current/voltage loads with low-level control signal.

Circuit (NPN Low-Side Switch) #

VCC ─── LOAD ─── Collector ┐
                            │ NPN
       RBASE ─── Base ──────┤
       │                    │
    CONTROL                 │
                  Emitter ──┴─── GND

When CONTROL = HIGH: Transistor ON, load energized
When CONTROL = LOW:  Transistor OFF, load off

Design Procedure #

  1. Determine load current (ILOAD)
  2. Choose transistor with IC(max) > ILOAD
  3. Calculate required base current: IB = ILOAD / β
  4. Calculate base resistor: RBASE = (VCONTROL - 0.7V) / (IB × 10)
    • Factor of 10 ensures saturation

Example: 100mA LED Load, 5V Control #

ILOAD = 100mA
β = 100 (typical for 2N3904)
IB(required) = 100mA / 100 = 1mA
IB(actual) = 10mA (for saturation)
RBASE = (5V - 0.7V) / 10mA = 430Ω → Use 470Ω

Protection #

Add flyback diode across inductive loads (motors, relays):

        VCC
         │
    LOAD (motor/relay)
         │
         ├─── Collector
        ╱│
       ╱ │ Diode (cathode to VCC)
         │

Pattern #9: Decoupling Capacitor #

Purpose #

Filter power supply noise, provide local energy storage for ICs.

Circuit #

VCC ───┬─── To IC VCC pin
       │
       C (100nF typical)
       │
GND ───┴─── To IC GND pin

Placement Rules #

  1. Physical: Place as close as possible to IC power pins
  2. Value: 100nF ceramic for high-frequency noise
  3. Additional: 10μF electrolytic for bulk storage
  4. Multiple ICs: One capacitor per IC

Typical Configurations #

  • Simple: 100nF ceramic
  • Standard: 100nF ceramic + 10μF electrolytic
  • High-speed: 100nF ceramic + 10nF ceramic (parallel)

In Breadpad #

1. Place capacitor from VCC node to GND
2. Keep wire lengths minimal
3. Simulate with transient analysis showing supply stability

Pattern #10: LED Driver #

Purpose #

Safely drive LED with proper current limiting and voltage protection.

Circuit #

VCC ─── RLIMIT ─── Anode[LED]Cathode ─── GND

RLIMIT = (VCC - VLED) / ILED

Design by LED Color #

LED ColorVF (typical)ILED (typical)RLIMIT @ 5V
Red1.8V10-20mA160-330Ω
Yellow2.0V10-20mA150-300Ω
Green2.2V10-20mA140-280Ω
Blue3.3V10-20mA85-170Ω
White3.3V10-20mA85-170Ω

Multiple LEDs #

Series (same current through all):

VCC ─── R ─── LED1 ─── LED2 ─── LED3 ─── GND
R = (VCC - (VF1 + VF2 + VF3)) / ILED

Parallel (each LED needs own resistor):

VCC ──┬─── R1 ─── LED1 ─── GND
      ├─── R2 ─── LED2 ─── GND
      └─── R3 ─── LED3 ─── GND

Pattern #11: Current Mirror #

Purpose #

Copy reference current to multiple loads, provide constant current source.

Circuit #

VCC ──┬─── RC ───┬─── Collector ── IREF (sets reference)
      │          │                   │
      │      Base├──────── Base      Q1 (diode-connected)
      │          │           │       │
      │          ├─── Collector      Emitter
      │          │     │             │
     IOUT    Emitter   └─────────── GND
              │         Q2
             GND

Characteristics #

  • IOUT ≈ IREF (if transistors matched)
  • Can create multiple output currents
  • Temperature stable if transistors at same temperature

Use Cases #

  • LED current regulation
  • Biasing circuits
  • Active loads in amplifiers
  • Precision current sources

Pattern #12: Differential Pair #

Purpose #

Amplify difference between two signals, reject common-mode noise.

Circuit #

        VCC                    VCC
         │                      │
         RC1                    RC2
         │                      │
         ├─── VOUT1      VOUT2 ─┤
         │                      │
VIN1 ────┤ Base          Base ├──── VIN2
         │ Q1                Q2 │
         ├─ Emitter ── Emitter ─┤
         │                      │
         └────── ITAIL ─────────┘
                  │
                 GND

Performance #

  • Differential gain: High
  • Common-mode gain: Low (ideally zero)
  • CMRR: Common-Mode Rejection Ratio = Ad / Ac

Applications #

  • Op-amp input stages
  • Analog comparators
  • Balanced amplifiers
  • Instrumentation amplifiers

Combining Patterns #

Real-World Example: Audio Amplifier Input Stage #

          VCC
           │
      Decoupling (100nF)
           │
      Voltage Divider ─── Bias voltage
           │
     C_coupling ─── Common Emitter Amp ─── C_coupling ─── Output
           │              │
    Audio Input      Emitter bypass
           │              │
          GND            GND

Patterns Used:

  1. Decoupling capacitor (power supply filtering)
  2. Voltage divider (bias generation)
  3. High-pass filter (input coupling)
  4. Common emitter amplifier (voltage gain)
  5. Bypass capacitor (AC gain boost)
  6. High-pass filter (output coupling)

Quick Pattern Reference #

PatternPurposeKey ComponentTypical Use
Voltage DividerReduce voltage2 resistorsBias, references
Current LimiterLimit currentSeries resistorLED, base protection
RC Low-PassRemove HF noiseR + C to GNDPower filtering
RC High-PassRemove DCC + R to GNDAC coupling
BufferIsolationTransistorImpedance match
CE AmplifierVoltage gainTransistor + RCSignal amplification
Pull-up/downDefault logicR to railDigital inputs
SwitchON/OFF controlTransistorLoad control
DecouplingLocal filteringC across powerIC power pins
LED DriverSafe LED driveSeries RIndicators
Current MirrorCopy current2 transistorsBiasing
Diff PairDiff amplification2 transistorsLow noise amp

See Also #


Tip: Start with these patterns and combine them to create complex circuits. Understanding these building blocks is key to efficient circuit design!