The Simplest Possible Mixer, using MOSFETs.

When a curious person searches the Internet for the circuit diagrams of (electronic) mixers, there is a certain complexity of what he or she will find. Just for people who might not know, the type of mixer I’m referring to is a component which does not add two signals together – which is what the naming might seem to suggest – but rather, which multiplies two signals. In certain cases the mixer will produce output, that contains an additive component as well as a multiplied component. But it’s the multiplied component circuit designers are interested in, because that can be used:

  1. In order to produce ‘mixed frequencies’, between two input frequencies, such as between a local oscillator and a Radio Frequency, resulting in an Intermediate Frequency,
  2. In order to act as a phase discriminator, the output of which will be maximally positive or negative, when two input signals are in-phase, but the output-voltage of which will be some neutral voltage, when the input waves are 90⁰ out-of-phase with each other. In this latter case, two reasonably constant input amplitudes are assumed.

What search results will often show, is somewhat complex mixers, that require either one or two balanced inputs – meaning inputs conditioned such, that they each appear differentially between two input electrodes – and which have as advantage for being designed that way, low distortion of the wave-form(s) supplied differentially in this way.

But sometimes, low distortion is not required. For example, in the case of a PLL – a “Phase-Locked Loop” – It’s assumed that the feedback voltage changes the frequency of a VCO – a “Voltage-Controlled Oscillator” – but with the intended result that two outputs lock in some phase-position, so that the two frequencies that are inputs to the phase-discriminator will be exactly the same frequency. This latter need often arises in the design of ICs. This latter application does not require that the phase-discriminator be particularly linear, nor that its output-voltages, that become feedback voltages, be in any range other than the range which the VCO requires as input.

And so the question can arise, what the simplest way might be to design a mixer, with the added detail that both inputs are unbalanced inputs – i.e., that each input appears at one terminal, and not in an opposing way, at two terminals – and for the sake of argument, our IC might be limited to using enhancement-mode, N-channel MOSFETs as the main active component. And this would be my solution:

Coinc-Det_1.svg

The concept is very simple. If Vin1 and Vin2 are at 180⁰, then M1 and M2 don’t conduct simultaneously. Therefore, R1 and Vcc (the supply voltage) achieve maximally positive average output-voltage. If Vin1 and Vin2 are at 0⁰ phase-position, the two transistors will become conductive in a way that coincides. Therefore, this is actually a Coincidence Detector. And the average  output-voltage will be maximally negative in that case. And, if Vin1 and Vin2 are at a 90⁰ phase-position, then the average output-voltage will be somewhere between the two values mentioned before.

I suppose it should be mentioned that, if the circuit designer knows ahead of time that one of the two inputs has a much higher amplitude than the other, or a more predictable amplitude, then this usually stronger input should be fed to Vin1.

As part of a feedback loop, the output needs to be followed by a low-pass filter, that emulates an integrator over the time-constant which is the fastest, with which that feedback loop is supposed to be able to react to a change in one of the frequencies. The simplest low-pass filter consists of a resistor followed by a capacitor… (:1)

And so, when looking for a way to implement a phase-discriminator, the curious person needs to choose which of the following has greater priority:

  • The simplest circuit-design, or
  • The lowest amount of distortion.

The circuit above will certainly give the highest amount of distortion. :-P

(Updated 7/9/2019, 16h55 … )

Continue reading The Simplest Possible Mixer, using MOSFETs.

My Opinion on the Opinion of Chris “Monty” Montgomery

Chris Montgomery is the Audio Expert, who invented the OGG Vorbis codec. That gives enough reason to accredit him with good advice. I recommend that my readers read his advice here.

I did read the whole thing, but have three comments on it:

  1. The Author suggests that 16-bit sample-depth offers a de-facto solution to the limits in dynamic range, simply due to the correct application of dithering. If I cannot trust my hardware to perform correct low-pass filtering, why on Earth would I trust it to perform correct, 16-bit, audio dithering?
  2. The Author explains the famous loudness curves, that define threshold of perceptibility, as well as the higher threshold of pain. What he fails to point out is that these curves assume, that the sound being tested for, is the only sound being played over the headphones. If there is another, background sound being played – i.e. the current loudness-level already higher than zero – then the threshold of perception for a given test-sound, is higher – requires a higher level, for that test-sound itself to be heard. Yet, this level is still lower, than the peak level of the background sound. People who design codecs know this, as I am sure the author does. It is the threshold of perceptibility next to a background sound – not the absolute threshold – which gets used in the design of codecs.
  3. The Author suggests it would be a misuse of his codec, to encode discrete multi-channel sound. And one reason he states, would be the waste in file-size, while the next reason he states, would be the fact that sound jumps to the nearest speaker, when they are all encoded that way.

This last observation strikes a cord with me. I have already noticed, that OGG Files do allow numerous channels to be encoded in parallel, but that if we exceed 2, we lose the benefits of Joint Stereo. By itself, this does not really count against this Author, whose codec therefore does not offer explicit surround-sound. But the possibility is very real, that the localization of sound will jump to the nearest speaker, if the listener moves and the sound was encoded that way. It is entirely possible, that purposeful encoding of surround-sound by the (competing) AC3 or the AAC codecs, reduces this risk.

But then I would suggest an alternative approach, to people who do not want to use the proprietary codecs, yet who wish to encode their movies with surround.

There exists the Steve Harris LADSPA plug-in library, which includes a matrix encoder for Pro Logic. This matrix encoder accepts 4 input channels, one of which is the surround channel, and outputs 2 stereo channels.

Further, the circuitry must exist someplace as well, to accept 2 stereo, 1 center and 1 surround-channel, and to encode those in real-time, so that the surround-effect can be played back over 6 speakers.

  • In principle, it should be possible to OGG-compress 4 channels and not 6, so that these channels can be used as inputs, to a matrix surround-system, like to the LADSPA plug-in, so that listenable surround will emanate from all speakers. Does Audio Software exist, which applies the LADSPA plug-in in real-time?
  • Alternatively, it might be possible to mix down Pro Logic sound into Stereo using the Steve Harris plug-in, and then to use FLAC on the resulting stereo.

BTW: What the Author mainly writes, is how incorrect it would be for pure listeners, to download their music in 24/192 format. He does not actually write, that Music / Sound Authors should avoid recording in this format. And so one fact which I have observed, is that there exists a lot of Audio Software – such as – that stores its sound in some higher, internal format, but which, when instructed to Export that to a 16-bit format, offer Dithering as an option.

This is possible because the Application is numeric and not physical. Thus, If I had used my USB-sound-device to record in 24-bit, I could next Export the finished sound tracks to 16-bit:

ardour_klystr_6

 

But, It would also seem that Chris Montgomery equates the use of such technology, as only being suited for Professionals. I am not a professional, and do not have the extremely expensive tools they do. Yet, I am able to author sound-projects.

Dirk