Engineers Garage

  • Projects and Tutorials
    • Electronic Projects
      • 8051
      • Arduino
      • ARM
      • AVR
      • PIC
      • Raspberry pi
      • STM32
    • Tutorials
    • Circuit Design
    • Project Videos
    • Components
  • Articles
    • Tech Articles
    • Insight
    • Invention Stories
    • How to
    • What Is
  • News
    • Electronic Products News
    • DIY Reviews
    • Guest Post
  • Forums
    • EDABoard.com
    • Electro-Tech-Online
    • EG Forum Archive
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • EE Resources
    • DesignFast
    • LEAP Awards
    • Oscilloscope Product Finder
    • White Papers
    • Webinars
  • EE Learning Center
    • Design Guides
      • WiFi & the IOT Design Guide
      • Microcontrollers Design Guide
      • State of the Art Inductors Design Guide
  • Women in Engineering

How to design and build a digital stereo volume and balance controller

By EG Projects

By Nazar Sliunchenko, Technical Documentation Manager, Dialog Semiconductor, A Renesas Company

This article describes how to design and build a digital stereo volume and balance controller with mute function. It is possible to design a fully functional cost-effective digital stereo volume control circuit using only one SLG47004 IC with a very low external components count. Figure 1 shows a simplified schematic diagram of such a device. For the full circuit diagram refer to Figure 2. The device has the following features:

  • Three push-button interface
  • 0 to -60 dB volume regulation (can be changed in the design)
  • ±30 dB balance regulation
  • Mute function
  • Enable pin
  • Very low power consumption (0.6 mA @ VDD = 5 V)
  • Extremely low quiescent current when disabled (0.01 mA)
  • Suitable for connecting to an external remote controller circuit
  • Using single SLG47004 IC

Figure 1: Simplified Schematic Diagram. One Channel

Figure 2: Full Schematic Diagram

Design operation
As previously mentioned, only one chip is used in this design. The SLG47004 IC combines all necessary analog and digital macrocells in a tiny 3 x 3 mm STQFN-24 package. See Figure 3 for a complete schematic diagram in the GreenPAK Designer project. The complete design file is available under this link. It was created in free GUI-based GreenPAK Designer software (a part of the Go Configure Software Hub).

Analog part
Since the SLG47004 contains only rheostats as opposed to potentiometers, it is impossible to make a fully functional volume control circuit. But the IC also has two OPAMPs suitable for audio applications. Figure 1 shows a simple solution how to design a signal attenuator using the rheostat and not sacrificing any gain or linearity. The circuit is an inverting amplifier with an adjustable feedback resistor. Using an input resistor equal to the maximum rheostat resistance (100k) the maximum gain is 0. According to the datasheet minimum rheostat resistance is 100 Ohm, which makes the minimum gain of -60 dB.

One of the benefits of using the SLG47004 is the internal voltage reference, which can be set to ½ of the power supply voltage. That eliminates the need for a bipolar power supply, so the device is powered from a single supply of 2.7 to 5 V, which is perfect for battery-powered applications.

The capacitors C6 and C7 are optional and are placed parallel to the negative feedback loop to reduce the bandwidth higher than 20 kHz. This makes the circuit more stable and reduces the high-frequency noise.

Another benefit of the IC is two analog switches on board. They allow implementation of the Mute function. Connected parallel to the rheostat when engaged the switch shortens the negative feedback loop thus instantly reducing the gain to even less than -60 dB.

Figure 3: Digital Stereo Volume and Balance Controller Project

Digital part
The Digital Stereo Volume and Balance Controller described in this paper is operated by three buttons: Volume Up, Volume Down, and Balance (see Figure 2). All button inputs are active Low and have pull-up resistors to the VDD. This should be kept in mind when connecting to an external controller for the remote-controlled operation. Also, the device has the Enable input which is active High. It must be connected to VDD when not used. It should be noted that when the Enable pin is Low, the device is in an idle state, the OPAMPs are disconnected from the pins internally. This means the signal will go through even though the volume was down or muted before.

All button inputs go through a 32 ms delay, which serves as a debounce, thus eliminating any external RC filters.

Using the device
The Digital Stereo Volume and Balance Controller is typically connected in between the signal source and the power amplifier. The Enable pin is active High, so to start operating it must be pulled up externally. The default gain is set in the design to about -12 dB (can be set to any value in the range of 0 to -60 dB in the design).

All buttons have a built-in debounce of 32 ms. Any signal shorter than that will be filtered out.

To increase the volume the button «Volume Up» must be pressed. The volume will keep rising until the button is released or the maximum level is reached. The button «Volume Down» works the same way but with the opposite result.

To shift the balance to the right or left channel, the button «Balance» must be pressed and held. At the same time, one of the buttons «Volume Up» or «Volume Down» must be pressed. In the first case, the volume will increase in the left channel and decrease in the right one panning to the left. In the second case, the volume will be panned to the right. If the volume is turned all the way up or down, the balance (panning) will be set to the center.

To activate Mute both «Volume Up» and «Volume Down» buttons must be pressed simultaneously. To deactivate Mute any of the three buttons can be pressed.

Some modern audio applications do not require balance regulation, for example, Bluetooth speakers or other low-budget or mono devices. In this case, Pin12 can be left unconnected or pulled up to VDD. Or balance regulation function can be deleted from the design. Either way, this will not affect any other functionality.

Macrocell configuration

Table 1: PIN settings

Table 2: OPAMP settings

Table 3: Vref settings

 

Table 4: Oscillator

Table 5: Digital Rheostat Settings

Table 6: Analog Switch Settings

Table 7: LUT Settings

Table 8: DFF Settings

Table 9: CNT/DLY Settings

The PCB was designed using the easyeda.com service. See the full schematic diagram, PCB design, and PCB 3D model in Figure 2 and Figure 4. The size of the board is 21 x 17 mm.

Figure 4: PCB Design and 3D Model

 

Suggestions for future design

Figure 5: Attenuator with Logarithmic Characteristics

Figure 6: Attenuator with Inverse Logarithmic Characteristics

Figure 7: Using Two Rheostats in Potentiometer Mode

Figure 8: Instrumentation Amplifier with Controlled Gain

Figure 9: Adjustable 2nd Order High Pass Active Filter

Figure 10. Adjustable 2nd Order Low Pass Active Filter

 

Conclusions
As can be seen, designing and building a digital stereo volume and balance controller with a mute function using the OPAMP PAK is very easy. The SLG47004 turned out to be the perfect IC for the design containing all necessary analog and digital macrocells. The design shown in this document is one of many versions of the device that can be built based on the SLG47004. There are some unused macrocells that can be used to design additional functions. And vice versa, if some features are not required, they can be easily deleted from the design.

 

You may also like:


  • Audio Filters: Designing a two-way audio crossover – Part 6

  • Designing a low power amplifier for headphones using 741 OPAM…

  • Designing a Stereo Power Audio Amplifier using TDA2822H – 7/9

  • Basics of Audio Amplifier – 1/9

  • Arduino audio player

  • MP3 Format: Understanding the basics of digital music

Filed Under: Electronic Projects
Tagged With: balance controller, digital stereo, SLG47004
 

Questions related to this article?
👉Ask and discuss on EDAboard.com and Electro-Tech-Online.com forums.



Tell Us What You Think!! Cancel reply

You must be logged in to post a comment.

HAVE A QUESTION?

Have a technical question about an article or other engineering questions? Check out our engineering forums EDABoard.com and Electro-Tech-Online.com where you can get those questions asked and answered by your peers!


Featured Tutorials

  • Introduction to Brain Waves & its Types (Part 1/13)
  • Understanding NeuroSky EEG Chip in Detail (Part 2/13)
  • Performing Experiments with Brainwaves (Part 3/13)
  • Amplification of EEG Signal and Interfacing with Arduino (Part 4/13)
  • Controlling Led brightness using Meditation and attention level (Part 5/13)
  • Control Motor’s Speed using Meditation and Attention Level of Brain (Part 6/13)

Stay Up To Date

Newsletter Signup

Sign up and receive our weekly newsletter for latest Tech articles, Electronics Projects, Tutorial series and other insightful tech content.

EE Training Center Classrooms

EE Classrooms

Recent Articles

  • What are the battery-selection criteria for low-power design?
  • Key factors to optimize power consumption in an embedded device
  • EdgeLock A5000 Secure Authenticator
  • How to interface a DS18B20 temperature sensor with MicroPython’s Onewire driver
  • Introduction to Brain Waves & its Types (Part 1/13)

Most Popular

5G 555 timer circuit 8051 ai Arduino atmega16 automotive avr bluetooth dc motor display Electronic Part Electronic Parts Fujitsu ic infineontechnologies integratedcircuit Intel IoT ir lcd led maximintegratedproducts microchip microchiptechnology Microchip Technology microcontroller microcontrollers mosfet motor powermanagement Raspberry Pi remote renesaselectronics renesaselectronicscorporation Research samsung semiconductor sensor software STMicroelectronics switch Technology vishayintertechnology wireless

RSS EDABOARD.com Discussions

  • Pull up via GPIO
  • Code Optimization
  • Poly Spacing Effect
  • Thyristor Gate Drive
  • Passive Harmonics Filter

RSS Electro-Tech-Online.com Discussions

  • Someone please explain how this BMS board is supposed to work?
  • HV Diodes
  • Question about ultrasonic mist maker
  • DIY bluetooth speaker
  • Disabled son needs advice please
Engineers Garage
  • Analog IC TIps
  • Connector Tips
  • DesignFast
  • EDABoard Forums
  • EE World Online
  • Electro-Tech-Online Forums
  • Microcontroller Tips
  • Power Electronic Tips
  • Sensor Tips
  • Test and Measurement Tips
  • 5G Technology World
  • About Us
  • Contact Us
  • Advertise

Copyright © 2022 WTWH Media LLC. All Rights Reserved. The material on this site may not be reproduced, distributed, transmitted, cached or otherwise used, except with the prior written permission of WTWH Media
Privacy Policy | Advertising | About Us

Search Engineers Garage

  • Projects and Tutorials
    • Electronic Projects
      • 8051
      • Arduino
      • ARM
      • AVR
      • PIC
      • Raspberry pi
      • STM32
    • Tutorials
    • Circuit Design
    • Project Videos
    • Components
  • Articles
    • Tech Articles
    • Insight
    • Invention Stories
    • How to
    • What Is
  • News
    • Electronic Products News
    • DIY Reviews
    • Guest Post
  • Forums
    • EDABoard.com
    • Electro-Tech-Online
    • EG Forum Archive
  • Digi-Key Store
    • Cables, Wires
    • Connectors, Interconnect
    • Discrete
    • Electromechanical
    • Embedded Computers
    • Enclosures, Hardware, Office
    • Integrated Circuits (ICs)
    • Isolators
    • LED/Optoelectronics
    • Passive
    • Power, Circuit Protection
    • Programmers
    • RF, Wireless
    • Semiconductors
    • Sensors, Transducers
    • Test Products
    • Tools
  • EE Resources
    • DesignFast
    • LEAP Awards
    • Oscilloscope Product Finder
    • White Papers
    • Webinars
  • EE Learning Center
    • Design Guides
      • WiFi & the IOT Design Guide
      • Microcontrollers Design Guide
      • State of the Art Inductors Design Guide
  • Women in Engineering