Skip to the content
PCBKitNew board
2 layers40 × 85 mmESP input, the printed circuit board in 3D

Analog seven-band spectrum bargraph with op amps.

Size
40 × 85 mm
Copper layers
2
Thickness
1.6 mm
Parts
30
Nets
42
Pads
154
Tracks, vias
200, 47
Pours
2
Routed
Yes
KiCad
KiCad 6 (file 20211014)
Created
25 Sep 2022
Updated
20 Oct 2023

Overview

ESP input is an open-source printed circuit board by BasementCircuits, from the BasementCircuits/Sonus7 repository on GitHub. It is a 2-layer board of 40 × 85 mm with 30 parts on 42 nets, routed with 200 tracks and 47 vias.

It is built around the ESP32-WROVER-I and PCM5100PW. Its parts include 13 capacitors, 3 resistors, 3 connectors, 2 ICs and 2 switches. It belongs with the ESP32 boards of this library.

Main components

2

README

README.md

Sonus7

Sonus7 is an analog seven-band spectrum bargraph with op amps. It consists of seven VU-meters, each being fed with a bandpass filter and peak detector circuit.

Each band has a spacing of 1.25 octaves. The bands are: 63 Hz, 160 Hz, 400 Hz, 1.25 kHz, 2.5 kHz, 6.25 kHz, 16 kHz.

The filters are second-order Multiple Feedback bandpass filters using TLC272 opamps. The VU-meters consist of a logaritmic comparator array, also using TLC272 opamps. The project is inspired by a reel of 2000 TLC272 bought cheaply at an auction.

Features

  • Fully analog (Except input stage)
  • Seven frequency bands
  • 10 levels per band
  • 1.25 octave spacing
  • 63 Hz to 16 kHz frequency range

Filters

The filters were chosen to be Multiple Feedback filters since they allow independent adjustment of the gain $A_m$, filter quality $Q$ and mid frequency $f_m$. The transfer function and equations for calculating component values are taken from TI's design reference SLOD006B (16-31).

The gain and filter quality were set to $A_m = -10, : Q = 6$ while capacitor values were chosen in the range of 33 to 0.33 nF to end up with reasonable resistor values. A MATLAB script is provided to calculate the exact resistor values and then round to nearest corresponding value from the E-24 series. The frequency responses are then simulated for the exact and rounded resistor values.

bode

A final calculation is done to ensure the filter gains do not exceed the unity gain bandwidth (GBW) of the op amps. The actual amplification from the op amps is obtained from the noise gain. The noise gain is then multiplied with the corresponding mid frequency of each filter to obtain the (highest) GBW. This is also provided in the same MATLAB script. The calculation shows that all filters have a GBW below 2 MHz (TLC272), although the 16 kHz filter is close at 1.1 MHz. Thus, variations in temperature or other factors might limit the gain for 16 kHz filter and cause distortions.

The filtered signals are fed into peak detectors to obtain the audio level for each. The audio levels are then fed into the comparators which control the LEDs.

Comparators

The comparators are built from open loop op amps. Reference voltage levels are generated from a logarithmic resistor divider (3 dB per step) and fed into the non-inverting inputs, essentially a logarithmic Kelvin divider. The inverting input is fed with the audio level. The op amp output can now function as a current sink for the LEDs. Any time the audio level exceeds the reference voltage level, the output is pulled low, allowing current flow for that level. Each op-amp drives one level, resulting in 70 op amps in total for the comparator stage.

Construction

PCBs

The Sonus7 consists of three boards (types).

Input Stage

The input stage consists of a custom board with an ESP32 and PCM5100. The ESP32 recieves the audio wirelessly through snapcast, using the port by @CarlosDerSeher. The audio data is then sent to the PCM5100 DAC over I2S. The input stage is connected to the next stage using a 4pin JST EH connector (VCC, GND, MONO, GND). The Kicad files for the input stage are available in /PCBs/ESP-input/.

Filter and Comparator stage

The filter and comparator stage is the main board and contains all the filters and the comparator arrays. This board also contains the input power DC-jack (9V) along with a simple reverse input protection (PMOS) and thus powers the rest of the boards.

LED bar

The final stage are the display boards. These are very simple boards with only LEDs, resistors and connectors on them. There is a small cutout on each level for the acrylic diffusers. There are seven of these boards, each one is connected to the main board using an ribbon cable (10p IDC) and a 2p JST cable (9V + GND).

Mechanical

Improvements

Less cables

There is currently a 10p IDC for signal and a 2p JST for power. Combining power and signal into one connector (12p IDC) would tidy up the design.

More stable supply voltage

Due to varying current draw (LEDs), the Drain-Source resistance of the PMOS causes to a varying voltage drop of 0-22 mV ( $R_{DS}$ = 32 mOhm, $I_{DS}$ = 0.7 A). This can cause issues for the op amps, which need a stable supply voltage. A simple fix could be adding a power regulator after the reverse input protection.

GBW

The 16 kHz filter is quite close to the rated GBW of the TLC272. There is only a margin of $\frac{2}{1.1} \approx 1.8$ in gain before the limit. This can be solved by using cascaded filters which results in the individual gain of each op amp being smaller. Replacing the TLC272 with higher bandwidth op amps also works.

Variable brightness

Currently the brightness of the LEDs are set by series resistors. Some brightness control using PWM or some other method could be good for the next version.

Bill of Materials

Contributors

Daniel Quach (Muoshy)
Main Contributor

  • Filter design & Simulations
  • PCB Design and assembly

Johan Wheeler (johanwheeler)

  • Mechanical design
  • Mechanical assembly

Adam Anderson (adand00)

  • ESP input stage
  • PCB Design and programming

Parts

30
QtyValueFootprintReferences
510uFCapacitor_SMD:C_1206_3216Metric_Pad1.33x1.80mm_HandSolderC2, C4, C10, C14, C15
4100nFCapacitor_SMD:C_0603_1608Metric_Pad1.08x0.95mm_HandSolderC3, C5, C7, C13
3470RResistor_SMD:R_0603_1608Metric_Pad0.98x0.95mm_HandSolderR1, R2, R3
22.2nFCapacitor_SMD:C_0603_1608Metric_Pad1.08x0.95mm_HandSolderC11, C12
22.2uFCapacitor_SMD:C_1206_3216Metric_Pad1.33x1.80mm_HandSolderC8, C9
2SW_PushButton_Switch_SMD:SW_Push_1P1T_NO_6x6mm_H9.5mmSW1, SW2
1AudioJack3Connector_Audio:Jack_3.5mm_CUI_SJ-3523-SMT_HorizontalJ1
1Conn_01x04_MaleConnector_JST:JST_EH_S4B-EH_1x04_P2.50mm_HorizontalJ2
1Conn_01x04_MaleConnector_PinHeader_2.54mm:PinHeader_1x04_P2.54mm_VerticalJ3
1ESP32-WROVER-IESP-sound:ESP32-WROVER-IA1
1NCP1117-3.3_SOT223Package_TO_SOT_SMD:SOT-223-3_TabPin2U2
1PCM5100Package_SO:TSSOP-20_4.4x6.5mm_P0.65mmU1
1SolderJumper_2_OpenJumper:SolderJumper-2_P1.3mm_Open_TrianglePad1.0x1.5mmJP1

The 25 most common of 30 parts.

Questions

How big is the ESP input PCB?

It measures 40 × 85 mm and has 2 copper layers, 1.6 mm thick.

What parts does the ESP input use?

30 parts, built around the ESP32-WROVER-I and PCM5100PW. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the ESP input KiCad files?

From the BasementCircuits/Sonus7 repository on GitHub, at the commit this page was made from: the board is PCBs/ESP-input/ESP-input.kicad_pcb and its schematic PCBs/ESP-input/ESP-input.kicad_sch. PCBKit opens the board in the browser, with nothing to install.

Can I use the ESP input design in my own project?

Its repository states no licence, so its author keeps all rights: ask BasementCircuits before reusing the design.

More from BasementCircuits/Sonus7

3
  • 2 layers200 × 87.8 mmSonus7 rev1, the printed circuit board in 3D

    Sonus7 rev1

    BasementCircuits/Sonus7

    Analog seven-band spectrum bargraph with op amps.

    263 parts6
  • 2 layers60 × 285 mmLed bar, the printed circuit board in 3D

    Led bar

    BasementCircuits/Sonus7

    Analog seven-band spectrum bargraph with op amps.

    82 parts6
  • 2 layers45 × 85 mmInput stage, the printed circuit board in 3D

    Input stage

    BasementCircuits/Sonus7

    Analog seven-band spectrum bargraph with op amps.

    21 parts6

Similar boards

  • 2 layers263.5 × 63.5 mmTobor, the printed circuit board in 3D

    Tobor

    evezor/tobor_v00

    Tobor (robot spelled backwards), was built to be the most versatile open-source robotics system

    124 parts126CERN-OHL-P-2.0
  • 4 layers65.8 × 77.2 mmVtx scanner pcb, the printed circuit board in 3D

    Vtx scanner pcb

    deets/deets-fpv-vtx-scanner

    39 parts5
  • 2 layers155 × 60 mmEsplay, the printed circuit board in 3D

    Esplay

    andykarpov/karabas-esplay

    A custom PCB with 3.2" TFT screen for the ESPlay project

    123 parts1
  • 4 layers100 × 100 mmAll boards, the printed circuit board in 3D

    All boards

    ChicoLiebl/pressure-acquisition-system

    Pressure acquisition system for a piezoelectric sensor

    154 parts1
  • 4 layers26.5 × 57.4 mmMotorDriver, the printed circuit board in 3D

    MotorDriver

    Kmshanley/MiniRobots

    Firmware and PCB desgin for mini robots with UWB localization and lidar mapping

    50 parts1
  • 2 layers104.3 × 65.1 mmTes0, the printed circuit board in 3D

    Tes0

    mekatronik-achmadi/wahyu-job

    This example test toolkit for various RF module.

    56 parts
  • 2 layersStreamBoy, the printed circuit board in 3D

    StreamBoy

    possan/gb-cart

    References: ESP32 DEVKIT V4 Schematic CMOD S6 Schematic ESP32 SD Card ESP32 PMOD

    94 parts
  • 2 layers89 × 76.1 mmGSRT Badge, the printed circuit board in 3D

    GSRT Badge

    ril3y/GSRT-ATL-Badge

    GSRT Badge - 2018 Atlanta

    62 partsMIT