Author Topic: Optimizing a 3:1 analog audio switch circuit to reduce clicks  (Read 1412 times)

0 Members and 1 Guest are viewing this topic.

Offline microviaTopic starter

  • Regular Contributor
  • *
  • Posts: 102
  • Country: fr
Optimizing a 3:1 analog audio switch circuit to reduce clicks
« on: December 09, 2024, 09:19:30 am »
[ Specified attachment is not available ]Hi,

I'm new to this forum and have been designing an audio circuit which requires a 2-channel 3:1 analog switch.
The target pcb is small and already well fitted (smd parts, 0402 Rs & Cs), and I want to avoid changing its dimensions for the moment.
For this reason, I want to avoid using bias resistors between the switch IC and the bypass capacitors (that would make 16 of them). I thought about using a clickless device such as Maxim's MAX4908, which features make-before-break (MBB) and internal shunt resistors, but this part is quite expensive compared to similar ones.
I consider using the STG3856QTR as shown in the schematic below. It features break-before-make (BBM), which is still useful, but won't suppress clicks completely.
How would you avoid those 16 bias resistors to (almost) completely suppress clicks at minimal cost ?
Any help appreciated. Thanks in advance.

« Last Edit: December 09, 2024, 09:31:18 am by microvia »
 

Offline moffy

  • Super Contributor
  • ***
  • Posts: 2709
  • Country: au
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #1 on: December 09, 2024, 09:34:20 am »
To avoid clicks when switching audio, you need to switch at the zero crossings of both signals, first off then next on, or preferred is a crossfade between the two signals. When using analogue switches, they should also be low charge injection.
 
The following users thanked this post: tooki

Offline microviaTopic starter

  • Regular Contributor
  • *
  • Posts: 102
  • Country: fr
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #2 on: December 09, 2024, 09:56:19 am »
The STG3856 is powered at 3.3V and its On-Resistance is 1.3 Ohms.
Typical charge injection (CL=100pF, RL=1MO, VGEN =0V, R GEN=0Ω) is 40pC as per datasheet.
Which analog switches handle zero-crossing detection ?
 

Offline Buriedcode

  • Super Contributor
  • ***
  • Posts: 1895
  • Country: gb
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #3 on: December 10, 2024, 05:01:26 pm »
Interesting as I was just thinking about a project yesterday as a way to A/B audio to compare the two sources - switching them without (noticable) delay, and without artifacts.

Moffy is spot on - wait for the zero cross of the current source (source 1), then disable source 1, wait for the zero cross of the next source (source 2) then enable that.  Given its audio there really won't be a long time between the zero crossings of two different sources, so there shouldn't be any noticable delay.

Zero crossing  detection would have to be fairly quick, and, once again as Moffy said, you'll need two, or four if you're switching stereo sources.

A cheaper way to redice clicks/pops is to ramp down/up sources, this is often used in commerical gear, but I dismissed this idea as even though it happens very quickly, it could sitll create a noticable drop, which isn't ideal for my application.  If you're just switching sources to an amplifier - manually switching, rather than trying to switch active sourcesduring playback, then that could be easier.
 
The following users thanked this post: moffy

Offline edavid

  • Super Contributor
  • ***
  • Posts: 3717
  • Country: us
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #4 on: December 10, 2024, 05:15:26 pm »
I disagree, zero cross switching is not practical and not needed for a simple audio switch.

Charge injection is not important.

As OP points out, the real problem is the uncontrolled DC levels on the multiplexer inputs.  They should all have a high value resistor to analog ground (DC midpoint). 

Since it's a break before make switch (not that you need that), it would also be a good idea to have a bias resistor on the outputs.

This only requires 8 resistors and a capacitor, not 16 resistors.
« Last Edit: December 11, 2024, 03:10:56 am by edavid »
 

Offline microviaTopic starter

  • Regular Contributor
  • *
  • Posts: 102
  • Country: fr
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #5 on: December 10, 2024, 05:29:39 pm »
Thanks for your suggestion.
Would 100K resistors be sufficient ? I could use a network to add a ground resistor at each input of the IC, and a pair of 100K bias resistors at each output. Unless the resistors need to be higher.
 

Offline edavid

  • Super Contributor
  • ***
  • Posts: 3717
  • Country: us
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #6 on: December 10, 2024, 06:25:11 pm »
Thanks for your suggestion.
Would 100K resistors be sufficient ? I could use a network to add a ground resistor at each input of the IC, and a pair of 100K bias resistors at each output. Unless the resistors need to be higher.

100K should be OK, try it and see.

I think it would be better to connect them to a bias divider instead of ground, but again, you can try it.
 

Offline David Hess

  • Super Contributor
  • ***
  • Posts: 18811
  • Country: us
  • DavidH
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #7 on: December 10, 2024, 08:31:46 pm »
Resistors to control the leakage which charges the capacitors are the way to fix it, however the outputs could also be muted later in the signal path during switching.
 

Offline moffy

  • Super Contributor
  • ***
  • Posts: 2709
  • Country: au
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #8 on: December 11, 2024, 12:39:30 am »
The STG3856 is powered at 3.3V and its On-Resistance is 1.3 Ohms.
Typical charge injection (CL=100pF, RL=1MO, VGEN =0V, R GEN=0Ω) is 40pC as per datasheet.
Which analog switches handle zero-crossing detection ?

Low charge injection like the ADG1236 is of the order of 1pC : https://www.analog.com/media/en/technical-documentation/data-sheets/ADG1236.pdf
The STG3856 is lower resistance but probably larger area/capacitance/charge injection.
 

Offline microviaTopic starter

  • Regular Contributor
  • *
  • Posts: 102
  • Country: fr
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #9 on: December 11, 2024, 09:11:18 am »
Looks interesting but the types of power supply it requires aren't compatible with my design.
 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 22007
  • Country: gb
  • 0999
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #10 on: December 11, 2024, 11:23:37 am »
Just to be clear: the biasing resistors should be connected to the inputs of the analogue switch and should go to the analogue ground, which is normally half the supply voltage. Without them, the inputs of the analogue switch are floating and might exceed the supply rails, which will cause problems such as distortion by the internal diodes conduction.
 

Offline SCSKITS

  • Regular Contributor
  • *
  • Posts: 109
  • Country: us
  • Retired electrical engineer
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #11 on: December 13, 2024, 02:43:25 pm »
Are the outputs driving the switch biased at the same point as the amplifier connected to the output of the switch?
Maybe eliminate the caps on the input to the switch if the input signals plus the DC bias are between 0V and 3.3V.
If not, why not a switch that can work from the main supply rails. There are a lot of dual 4 to 1 switches out there.
Then maybe no caps needed on the inputs.

Set up as-is, a resistor network is needed on the input to the switch to get a DC bias of 3.3V/2.
A single resistor to ground would result in half the signal being below the ground level.

Not knowing enough about the rest of the circuit makes it hard to determine the best solution.
SCS, DIY upgrades for older test equipment
 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 22007
  • Country: gb
  • 0999
Re: Optimizing a 3:1 analog audio switch circuit to reduce clicks
« Reply #12 on: December 13, 2024, 06:26:15 pm »
Here's an example of how to use bias resistors.

R1 & R2 set the AC reference voltage, with C1 acting as a power supply filter. R3 & R4 bias both sides of the analogue switch to the AC reference voltage.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf