I am making a remote volume control for my TV, as my amplifier only as a physical button. My idea is to control a digital potentiometer with an microcontroller. I have build the circuit shown on the follwing figure:


simulate this circuit – Schematic created using CircuitLab

The potentiometer shown is a MCP42100, controlled with the microcontroller. As it is for stereo, two of the circuits is used.

When the volume is full, the signal is as it needs to be, when feeding it a sine signal. enter image description here

However, when i use the potentiometer for attenuation the signal, i get a signal like this:

enter image description here

I do not understand why i get something like this, as it is just passive components and a voltage follower.

The parts: C1, R1 and R2 was added, because i had a signal like this: enter image description here

This is clearly some kind of clipping, so i added some biasing, which works. Even through it works, i do not understand why, or even why it is needed as the only component the biasing is connected to is the potentiometer.

I suspect that this is coursed for the same reason as the other problem.

I start to belive that the potentiometer is at fault, but i dont know how. This is the datasheet i am using for the potentiometer: http://ww1.microchip.com/downloads/en/DeviceDoc/11195c.pdf

Can anyone tell me what i might fail to see?

  • 1
    \$\begingroup\$ The voltage range for your digipot is supposed to be limited to a range of 0-Vcc, so if you're running the digipot off a 5V supply, you shouldn't be putting anything outside of 0-5V on any of its pins. \$\endgroup\$ – brhans Aug 23 '18 at 19:13
  • \$\begingroup\$ Well, it will be the reason then. I will try to attenualt the input signal, and bias it at 2.5 V. I suspect it will work then. \$\endgroup\$ – keffe Aug 23 '18 at 19:15
  • 1
    \$\begingroup\$ Remove R2 and change R1 to 100k. Connect the 'top' end of R1 to your digipot's 5V supply. \$\endgroup\$ – brhans Aug 23 '18 at 19:21
  • \$\begingroup\$ I did that, and it works exactly as expected. Very much thank you. \$\endgroup\$ – keffe Aug 23 '18 at 19:41

Here's one potential reason:

Absolute maximum

You're sending an audio signal with a +12 V DC offset into an IC that is designed for much lower voltages.

EDIT: Here is brhans' solution:


simulate this circuit – Schematic created using CircuitLab

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.