Shop OBEX P1 Docs P2 Docs Learn Events
Switching speakers without relays — Parallax Forums

Switching speakers without relays

Mike GreenMike Green Posts: 23,101
edited 2006-01-23 15:23 in General Discussion
I have an application where I could use a reed relay to switch an audio source (1-10W) to one of several speakers, but I'd rather use something solid-state that could be switched by a Stamp output. The audio amplifier is a TDA2002 with a 2200uF capacitor in series with the output driving the speaker which is grounded. The signal at this point is AC in relation to ground and the load is very low impedance (<= 8 ohms). Any suggestions?

Comments

  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2006-01-12 15:35
    If you raise the AC signal so that it never crosses Zero [noparse][[/noparse]never changes polarity], you can use a FET device to switch it and preserve all the audio information. Then, you have to bring the signal back to its original AC status on the other side of the switch.

    I suppose someone has this all available in an IC as a solidstate audio switch.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    "When all think alike, no one is thinking very much.' - Walter Lippmann (1889-1974)

    ······································································ Warm regards,····· G. Herzog [noparse][[/noparse]·黃鶴 ]·in Taiwan
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-01-12 16:01
    Are you looking to switch line level signals or the amped signals? There are quite a few chips specially designed to do switching of line level audio, but the amped switching is a little more problematic.

    Goto www.digikey.com type: audio switch
    into the search box, click Integrated circuits, Switches (10 items) to see the chips digikey has.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-01-12 16:05
    I agree with Paul.· I build custom audio amplifiers myself for many years, and while I have experimented with many devices and methods for switching line-level audio, switching a powered AC circuit while preserving the signal and not introducing any noise would be a real design hassle.· I use standard Relays.· Never used a reed relay though.· I use those to switch the cooling fans on/off.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Mike GreenMike Green Posts: 23,101
    edited 2006-01-15 03:50
    Just to clarify ...
    I have two amplifiers with a maximum output of about 10 watts that use a single chip to amplify a headphone output (TDA2002). These have a commonly used configuration with a large capacitor in series with the output of the amplifier since the final stage is biased around 1/2 the supply voltage. The net result is AC at the speaker with a maximum amplitude of twice the supply voltage. The amplifiers are available from KitsRUs.com as their DIY47. In my application, they run off 6-12VDC from a regulated "wall wort". I also have 6 speakers rated for 10-20 watts. The speakers and the amplifiers use a common ground and I'm switching the "hot" side currently using small relays controlled by a Prop-1 at a time when the volume is quiet. For future projects, I'm more interested in eliminating the "clack" of the relays and avoiding the need for the Darlingon outputs than in not generating any clicks or pops in the speakers. My sound sources are conversational voices so, although there may be peaks with sibilants, there's not much average power used.
  • RickBRickB Posts: 395
    edited 2006-01-16 01:27
    Mike:
    Since you aren't looking for audiophile quality, consider using paralled N & P type power fets in series with common lead of ea. speaker. Putting them in the high side will require more attention paid to biasing. The gates need to be driven with opposite polarity levels. With both fets turned on they will have an effective resistance in the tens of milliohms for most low cost power fets. Haven't tried this, but it should work. You might even be able to get away with using 1 fet, since fets are resistive devices and not real polarity sensitive in apps like this.

    Rick
  • mediaprefectmediaprefect Posts: 31
    edited 2006-01-16 06:01
    Mike,

    As you are likely to spend about the same $ for building up a switching circuit for the speaker level signal, why not switch at the low level (-10db) before the amplifier and build up an amp for each speaker? TDA2002 are about $1.70 in the quantity you need. You can then switch the low level audio with CMOS switches (read multiplexers) such as a pair of CD4052, one for each channel, addressed in parallel by the STAMP. You would need to bias the switch inputs with perhaps a small DC bias to keep the signal swing from trying to go below ground. A pair of CD4051 would give you stereo to 8 amplifiers, a 2x8 switching matrix.

    If you then wanted to expand to have more sources to the 8 stereo destinations, you should investigate using a pair of 8x8 analog matrix switches. You could get by on just one 8x8 matrix switch IC and still use 4 stereo sources (or 2 stereo and 4 mono or some other combination) to 8 amplifiers and speakers, configured as singles or pairs as you desire. BTW, this IC will also pass RS170A video with proper buffering in and out if you desire to switch video the same way from 8 sources to 8 destinations. Smaller matrix sizes are also available. Find the matrix switch ICs here: http://www.maxim-ic.com/quick_view2.cfm/qv_pk/1931/ln/ and here: http://www.maxim-ic.com/quick_view2.cfm/qv_pk/1974/ln/. I hope this helps.

    Rick B (not RickB) just coincidence that we are both replying to you.
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-16 14:50
    Chris Savage (Parallax) said...
    I agree with Paul. I build custom audio amplifiers myself for many years, and while I have experimented with many devices and methods for switching line-level audio, switching a powered AC circuit while preserving the signal and not introducing any noise would be a real design hassle. I use standard Relays. Never used a reed relay though. I use those to switch the cooling fans on/off.
    Chris and all, I haven't seen it mentioned before, but if you need to switch a ground-referenced AC signal, a pair of back to back FETs (N channel, lowest Rdson you can afford, with the required voltage rating) work just fine. I've used it for things as small as uV sensor signals and as big as a 12kW 3 phase lighting dimmer. The important part is that the signal is ground referenced, and that the FETs are not lossy enough to impact the signal.

    It's like Kramer's idea, but compatible with bipolar stuff.

    -dave

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-01-16 16:48
    Dave,

    ·· I failed to mention this due to my lack of testing to see what effects this would have on an audio signal.· I wouldn't think you would get a linear signal back out, not to mention the possible effects of zero-crossing/bias.· Perhaps I am way off here, but that isn't something I have ever tried, just wouldn't have thought of for the above mentioned reasons.· Perhaps I misunderstand your implementation.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-17 14:56
    Chris-

    The trick works because of the way that FETs conduct. I dug it out from an old copy of Horowitz & Hill, which has the deep dark dirty reasoning why it works, but the short and mostly correct version is that when you nail a FET into the conduction state, it ceases to care what direction the current flows in, and the back-to-back topology prevents the body diodes from conducting when the pair should remain off (the normal thing people think of when someone uses a FET for bipolar control). There's a little loss because of the series resistance of the FETs, but assuming they're relatively well matched and that you raise the gates to a level sufficiently high that they're ON, not just on, the probelm goes away for signals of sufficient magnitude to swamp the series resistance. Once I get the layout program un-b0oked on my PC, I'll post a picture of the business end of the dimming module schematic I built like this.

    -dave

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-01-17 16:05
    Dave,

    ·· Thanks for the explanation.· Perhaps the OP could make use of this.· Myself, I will probably stick with a mechanical relay.· It won't be switching so much that it will be a problem.· But it is nice to know that you can use the FETs in this manner.· I just figured it would be more involved with support circuitry.· But I have only used FETs in automotive applications for switching 12V lights, so I am not the foremost authority on them.· =)

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-17 22:27
    No problem Chris.

    Attached are snippits of the schematic and PCB for the dimmer I mentioned. Patent pending stuff has been obfuscated to protect my own tail.

    -dave

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
    980 x 751 - 116K
    1019 x 493 - 117K
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-01-18 02:18
    Very nice.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-18 14:55
    Well, it will be if I can get the drivers to stop turning the FETs into a bunch of cratered plastic packages. I spent this morning pulling shrapnel out of the wallboard on the test bench after something went terribly wrong. My guess right now is inductive flyback, but I won't know for sure for a few more hours.

    To the OP (Mike Green), this isn't something you'll ever run into switching speaker loads. I'm working with some pretty crazy stuff to establish the upper performance limits of the system.


    The one thing I did forget to mention is that the FETs need to be switched with a voltage on their gates relative to the common sources. In the schematic, you'll see two lines running down the center of the pais of FETs. One is the common (to all parts) gate drive. The other is what I called FETGND, and it's the floating ground that's used as the reference for the gate drive. If you try to ground that center point and drive the gates from logic ground, you'll create a dead short to ground, and probably blow things up. It's required because the turn-on volatge for a FET is measured between gate and source (Vgs), thus we connect all the sources to a single, virtual ground. I'd suggest floating the circuit with a secondary power supply, and making FETGND real ground. Just make sure to use optocouplers for the switch interface to whatever is controlling it, to keep from shorting anything.

    -dave

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
  • Paul BakerPaul Baker Posts: 6,351
    edited 2006-01-18 18:48
    Dave Paton said (in part)...
    To the OP (Mike Green), this isn't something you'll ever run into switching speaker loads. I'm working with some pretty crazy stuff to establish the upper performance limits of the system.

    Actually if you are switching a subwoofer that is being driven hard at the wrong point in a signal, you most certainly could cause enough inductive flyback to damage the FET, to further complicate the issue regular flyback protection diodes don't work because you dont know which way the current is flowing (I think, my head is still muddy from all the cold medication Im on).

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·1+1=10
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-18 23:43
    Paul-

    That's correct, but the levels of flyback required to destroy the IRFP360s is much higher than the pulse generated by the pair of 12" overhung woofers I have. To put it in perspective, the shrapnel I referred to was the result of a load dump disconnect test for an 8kW 3ph purely inductive load. Yes, it was a torture test, and yes, I will be designing in load-dump protection in the next board rev.

    -dave

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2006-01-19 00:35
    Dave,

    Building LARGE tesla coils? .... Just kidding smilewinkgrin.gif

    What precision are the resistors you are using?
    Is there any possible way that your "cratered plastic packages" are a result of an imbalanced gate drive?
    In a way, thermal runaway?

    i.e. If one FET get's turned "on" slightly before the others, then THAT FET experiences the brunt of the demand.
    This can cause a chain reaction with all the other FETs.

    What would happen if you put all of the FETs in parallel using only 1 resistor per 8 FETs?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-19 00:46
    Beau-

    I narrowed it down to the complete and total meltdown of the protection module on the load, a COTS unit that the customer specified against our engineers requests. It's potted, so when it went, it went quietly, but shorted around the load, dumping the three phases together into the neutral and making a big mess. I'll see if I can take a picture of the puddle of silicon that formed where the die used to be in one of the parts that didn't vaporize.

    In other news, I have a really near Si and Cu sputtered plexi blast shield. I plan on hanging it on the wall of the shop as a reminder.

    The gate 'resistors' are left over from an earlier version of the driver circuitry that wasn't capable of directly driving the Qc of the gates at the speed we needed. The way around that is under the missing pixels in the PCB screencap wink.gif The FETs are all hand matched right now, so 'slower' parts get binned with their brethren, and all is well. The resistors that I'm using are actually cut up pieces of plated copper buss bar, so the driver sees the gates directly, no resistors, no anything. I've also worked out a way to get the power factor of the gate trace to be 1j0 under almost any condition. I'll post details if the patent aps are rejected, but that won't be until summer time. The next board revision is slated for next month, and will include a radically different layout designed to allow the dimmers to be unitized for a backplane (in addition to the 1j0 gate traces and the new gae drive system). The connectors the customer wants us to put on the edge of the board are so big they're just silly. I love it. I have a hunch the production units will end up with 8 layers of 4oz copper in a .375" thick Mil-spec layup. Beefy is the word for the day.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
  • Mike GreenMike Green Posts: 23,101
    edited 2006-01-19 21:46
    Thank you all for your suggestions. I think I'll stick with the reed relays. They are simple in this setup.

    Dave, You're way out of my league. I get really careful anytime I play around with more than a couple of amps at 12-14V.

    Mike
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-20 22:09
    Mike-

    I used to have a Vne (Voltage to Never Exceed) of about 12V too. Then I built a 30W amplifier. Then I built a 100W amplifier. Then I built a 1kW light controller. Then I got my degree. Then...

    smile.gif

    You can see how it snowballs. The reed relays may not be the best solution unfortunately, unless you can mute the amplifier for a half-second or so before you switch the coils. The reason has to do with both the risk of switching a speaker in the middle of a transient (generating a vertical voltage transition) and cooking a tweeter or welding the contacts of the relay. I know it seems unlikely, but I'd use beefier relays if you can. What are your supply rails for the amp? You'd be surprised how much current can flow at the top end of a kick drum thud or a good snare drum thwack.

    -dave

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
  • Mike GreenMike Green Posts: 23,101
    edited 2006-01-22 00:46
    Dave,
    I'm controlling the output of two MP3 players. I only switch the speakers attached to a channel when the current track has finished playing. The only audio going through the amplifier on that channel is the noise of the idle MP3 processor (essentially inaudible). The amp runs off 6V for now, but I'm going to increase that to 12V since we need a bit more volume without distortion sometimes. Usually the 6V is more than adequate in a quiet room, but, at the opening, there were too many people talking to hear the audio installation piece. There'll be a closing lecture in a couple of weeks and we expect a lot of people again.
    Mike
  • Dave PatonDave Paton Posts: 285
    edited 2006-01-23 15:01
    Mike-

    At those power levels, you can probably get away with some 500mA reed relays and not have a problem. Just remember, 12V across 8 ohms gives you a max. current of 1.5A. I'm not saying you'll ever get to that level, but it is possible, especially with higher bit-rate MP3s that (can) have more dynamic range. 4 ohms and 12V gives you 3A peak, which is worthy of some better relays. I could go on and on about peak power requirements for amplifiers and headroom values, since I'm a little crazy about audio (just ask Chris Savage smilewinkgrin.gif), but I won't bore you with it. I'll just say that if you want the system to live a long and happy life, where the relays will never be a point of failure, use units that are rated to switch something in excess of 3A. You'll never have to worry about them after that.

    -dave

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    This is not a sig. This is a duck. Quack.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2006-01-23 15:23
    Yes,

    ·· I would say Dave Paton is a little more serious about his audio than even I am, and I spent years building custom amplifiers in a business...Ah the good ol' days...· =)· Speaking of which, Dave, it seemed we were on a roll in our Audio Amplifier thread for ahwile...I think it got lost.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
Sign In or Register to comment.