I have two audio signals and I want to fade in one signal in just as the other signal fades out and repeat the process backwards and so on... I want to control the circuit using some digital means or voltage control, however the actual circuit should be analog. Any suggestion for an affordable solution?
4 Answers
Or you can use digital pot chips like AD5242
series dual I2C digital pots, coupled with some op amps.
Here is a reference design for you:
simulate this circuit – Schematic created using CircuitLab
The two pots there is the digital pot chip AD5242BRUZ10
commanded by the Arduino. You can program the Arduino to handle MIDI interface and plug this into your professional audio system rack.
OPA4134
is a proper audio grade op amp but it is expensive. You can experiment with orders of magnitude cheaper but pin compatible LM324
, or get rid of the two voltage followers and use the cheaper OPA134
audio op amp that is pin compatible with 741
.
TL431
is a 2.5V reference chip used as a virtual ground here.
-
\$\begingroup\$ There's no zero crossover detection in this circuit so isn't there a click in the audio whenever you change the volume? \$\endgroup\$– PkPJan 4, 2015 at 23:39
-
\$\begingroup\$ @PkP I have a virtual ground voltage at 2.5V so if you reference the signal to that point you have no zero crossing issue at all. \$\endgroup\$ Jan 5, 2015 at 1:43
Updated answer 01/23/2017:
Maybe this is an answer: Digital Optical Volume Control with LED and photoresistor (light to seperate circuits, optical pot)
Using light to control the 'fades'/volume of each channel by using a LED and photoresistor(s). You can simply control the LED with an Arduino. Because of the LED is driven by PWM, you need to change the PWM frequency. See also example at my answer (and the reason why).
I made some drafts/examples at my question, my question is about if there is component that combines the two. There is, called vectrols but they are very expensive. You can make your own, it's cheap! More info and pictures at my question and answer.
Changed and simplified schematic:
More info at my question: Digital Optical Volume Control with LED and photoresistor (light to seperate circuits, optical pot)
Use a digital signal processor (DSP). Convert both inputs from analog to digital, multiply them with values ranging from 0 to 1, sum them together and feed to the DAC.
You can also use digital volume control ICs, such as CS3310 (http://www.cirrus.com/en/products/cs3310.html) but a DSP might even be cheaper in the end. Depends on the number of channels and what kind of ICs you can find.
-
\$\begingroup\$ I was looking for an analog approach here - analog circuit with digital control. I have a very basic 8bit MCU in the system and I would like to keep it that way. \$\endgroup\$ Jan 4, 2015 at 13:24
-
\$\begingroup\$ @user: The point is a small DSP will be smaller, simpler, and quite possibly cheaper if you have it do all the digital stuff, compared to adding analog fading to a smaller processor. \$\endgroup\$ Jan 4, 2015 at 14:15
-
\$\begingroup\$ @OlinLathrop - Can you direct me to a solution that would be under $3 and won't require investing in development tools or software? \$\endgroup\$ Jan 4, 2015 at 14:24
-
\$\begingroup\$ @user: Low end DSPs for uder $3 are certainly available. You already have a processor in there, so you gain a little more budget by replacing it with the DSP and having the DSP perform the existing processor's function too. As far as firmware development, that's part of engineering just about any meaningful electronic product. You are already doing it anyway. Doing it in a upgraded processor instead doesn't change that much. \$\endgroup\$ Jan 4, 2015 at 14:28
-
\$\begingroup\$ @OlinLathrop - Can you give me just a single example? \$\endgroup\$ Jan 4, 2015 at 14:41
PT2259 is an 8-pin 2-channel volume controller which utilizes CMOS technology and incorporates the I2C interface control. The controller features an
attenuation range of 0 to -79dB, low noise output, a high degree of stereo separation and requires only a small number of external components. PT2259 is an essential component for modern audio visual systems.