Sign In / Join Cloud 360
Engineering • Innovation • Learning
Electronics Fundamentals Advanced 22 min

4th-Order Sallen-Key Active Butterworth Filter for Sensor Anti-Aliasing

Design, simulate, build, and sweep a 4th-order active Butterworth low-pass filter providing -80dB/decade roll-off prior to ADC sampling.

2. Prerequisites & Background Theory:

Operational amplifier feedback analysis, complex Laplace s-domain poles, and Bode magnitude plots.

STEP 1

Goal & Engineering Objectives

Synthesize a 1 kHz 4th-order active low-pass anti-aliasing filter with maximally flat passband response and -80 dB/decade attenuation in the stopband.

STEP 2

Governing Mathematical Formulation & Physics

Cascaded 2nd-Order Sallen-Key Sections: $$H(s) = H_1(s) \times H_2(s) = \frac{\omega_0^4}{(s^2 + \frac{\omega_0}{Q_1} s + \omega_0^2)(s^2 + \frac{\omega_0}{Q_2} s + \omega_0^2)}$$ Butterworth Q-Factor Synthesis (4 Poles on Unit Circle): $$Q_1 = \frac{1}{2 \cos(67.5^\circ)} \approx 0.541, \quad Q_2 = \frac{1}{2 \cos(22.5^\circ)} \approx 1.306$$ Equal-Resistor Sallen-Key Section Design (R1 = R2 = R): $$\omega_0 = \frac{1}{R \sqrt{C_1 C_2}}, \quad Q = \frac{1}{2} \sqrt{\frac{C_1}{C_2}} \implies C_1 = 4 Q^2 C_2$$
STEP 3

System Architecture & Block Flow Diagram

[Sensor Raw Analog Signal] --> [Section 1 (Q=0.541, fc=1kHz)]
                                         |
                                         v
                              [Section 2 (Q=1.306, fc=1kHz)]
                                         |
                                         v
                              [-80dB/dec Filtered Signal] --> [Microcontroller ADC]
STEP 4

Required Hardware Bill of Materials (BOM)

Hardware Component Qty Engineering Specification
OPA2134 Precision Audio Dual Op-Amp 1 Ultra-low distortion (0.00008%), 8MHz GBWP, FET inputs
Precision Resistors (0.1% Metal Film) 8 15.8 kΩ and 10.0 kΩ values
C0G/NP0 Ceramic Capacitors (1% tolerance) 4 10 nF and 4.7 nF values
Decoupling Capacitors 2 100 nF ceramic X7R close to IC power pins
STEP 5

Wiring, Pinout & Schematics Mapping

• Connect Pin 8 to +12V rail and Pin 4 to -12V rail (or single supply with virtual ground bias). • Stage 1 Op-Amp A: Input resistor R1 into node with C1 feedback and R2 to non-inverting input. • Stage 1 Output (Pin 1) fed directly into Stage 2 Op-Amp B Input resistor R3. • Bypass pins 8 and 4 directly to ground plane with 100nF ceramic capacitors. • Route input and output analog signal traces far away from digital switching rails.
STEP 6

Firmware Implementation & Algorithms

// Python / Scipy: 4th-Order Butterworth Frequency Response Sweep
import numpy as np
import scipy.signal as signal

fc = 1000.0 # 1 kHz cutoff
order = 4

# Generate 4th-order Butterworth transfer function
b, a = signal.butter(order, 2 * np.pi * fc, analog=True)
w, mag, phase = signal.bode((b, a))

print("Frequency (Hz) | Attenuation (dB)")
for freq_hz in [100, 500, 1000, 2000, 5000, 10000]:
    w_eval = 2 * np.pi * freq_hz
    _, mag_at_f, _ = signal.bode((b, a), [w_eval])
    print(f"{freq_hz:14d} | {mag_at_f[0]:16.2f} dB")
STEP 7

Bench Testing & Waveform Verification

1. Connect function generator to input: Apply 100 Hz 1.0 Vrms sine wave; verify output reads 1.0 Vrms (0 dB). 2. Sweep frequency to 1000 Hz: Verify output drops to exactly 0.707 Vrms (-3.01 dB). 3. Sweep frequency to 10 kHz (one decade beyond): Verify output drops below 0.0001 Vrms (-80 dB).
STEP 8

Troubleshooting & Common Failure Modes

• Problem: Frequency response shows sharp resonant spike (+4dB) at 900 Hz. Solution: Section 2 capacitor ratio C1/C2 is too large, inflating Q2 beyond 1.306. • Problem: Filter passes high frequency signals above 500 kHz. Solution: Op-amp output impedance rises at high frequencies. Add a simple passive 1st-order RC post-filter. • Problem: Cutoff frequency changes when ambient temperature rises. Solution: Low-quality dielectric capacitors (Y5V/Z5U) were used. Replace with temperature-stable C0G/NP0 capacitors.
STEP 9

Extensions & Undergraduate Research Challenges

1. Convert low-pass topology to Bessel-Thomson filter alignment to preserve linear phase and prevent audio pulse distortion. 2. Build digital biquad IIR equivalent filter in microcontroller software for real-time comparative bench validation.
All Engineering Guides
Closed-Loop Discrete PID Control & Inverted Pendulum Balancing
Control Systems & Robotics • 25 min
CAN-Bus 2.0B Telemetry Node with Industrial Sensor Fusion
Embedded Systems & Automotive • 20 min
Precision Dual-Axis Stepper Motion Controller with S-Curve Acceleration
Mechatronics & Motion Control • 22 min
IoT Environmental Monitoring Station with OLED & Secure Telemetry
Internet of Things (IoT) • 18 min
Closed-Loop DC Motor Velocity Control with Optical Quadrature Encoder
Power Electronics & Motion • 20 min
Astable 555 Timer & 74HC595 Shift Register Digital Sequencer
Discrete Electronics & Digital Logic • 16 min
Field-Oriented Control (FOC) & Space Vector Modulation for BLDC Motors
Power Electronics & Motors • 28 min
High-Efficiency Synchronous Buck DC-DC Converter Design
Power Electronics & Energy • 24 min
Discrete Kalman Filter IMU Sensor Fusion for Tilt & Orientation
Control Systems & Robotics • 26 min
Industrial Modbus RTU Slave Node over Galvanically Isolated RS-485
Industrial Automation • 22 min
4th-Order Sallen-Key Active Butterworth Filter for Sensor Anti-Aliasing
Electronics Fundamentals • 22 min
Mobile Robot Differential Odometry with 4X Hardware Quadrature Decoding
Robotics & Automation • 24 min
Discrete N-Channel MOSFET H-Bridge with Bootstrap Gate Drive
Electronics & Motor Control • 25 min
High-Speed SPI NOR Flash Black-Box Flight Data Logger
Embedded Systems & IoT • 22 min
MPU-6050 Digital Motion Processor (DMP) Quaternion Spatial Tracking
Sensors & Embedded Algorithms • 24 min
Deterministic Multitasking Architecture with FreeRTOS Kernel
Embedded Systems & Software • 25 min
Ask LUNA About This Lab

Ask LUNA for circuit calculations, state-space equations, tuning parameters, or component substitutes.

Hardware Catalog

Inspect verified electrical specs, voltage rails, and pinouts across all 10 component categories.

Browse Components →