Inserting digipot with arduino instead of control nob

HI all,

I am trying to manipulate old dc motor circuit, which has two mode controlled by resistance. It is current controlled by the resistor (where I marked) at pin 5.

So I am trying to use digipot instead of switch as original circuit but I have no idea how to really wire them together. I have MCP4132 / MPC4131 now but all the reference I found describe using middle port with ground(or Vcc) as below example.

Assuming arduino circuit shares ground with external system(motor circuit), I have no idea how to combine these two because the place (R232) where digipot has to be inserted shouldn't be ground either side?

schem.JPG

schem.JPG

Okay, it seems I can get variable resistance from pin 5/6 while below setting of pin 5,6,7

Pin5 - port A (directly onto targeted circuit area, instead of 5V)
Pin6 - port B (wiper)
Pin7 - GND

I am not sure if it is proper way to use, but leave the answer to get confirmed by others and for archiving..

That circuit diagram shows two wires leading out to something in that circuit - what do they lead to?
I think its just a switch to select an alternate speed setting - is this right?

If you are replacing a single resistor you only connect two of the digipot's terminals, ie
connect as a variable resistor (2 terminal), not a potentiometer (3 terminal).

Digipots can only work if the voltages on the terminals are within the supply range of the digipot
chip itself, otherwise it will be fried. In particular this means the digipot chip must be powered up
whenever the the circuit it is connected to is powered up, and the voltages on the controlled
circuit need to be low enough.

MarkT:
That circuit diagram shows two wires leading out to something in that circuit - what do they lead to?
I think its just a switch to select an alternate speed setting - is this right?

If you are replacing a single resistor you only connect two of the digipot's terminals, ie
connect as a variable resistor (2 terminal), not a potentiometer (3 terminal).

Digipots can only work if the voltages on the terminals are within the supply range of the digipot
chip itself, otherwise it will be fried. In particular this means the digipot chip must be powered up
whenever the the circuit it is connected to is powered up, and the voltages on the controlled
circuit need to be low enough.

Thank you for your answer, I appreciate it.
Yes, it is correct. That terminal is for alternative speed and I want to control by arduino. So I am trying to use it as 'rheostat'
Thanks to point out terminal voltage. I haven't thought about it indeed. I measured only current it was enough in the spec(2-5uA), and terminal voltage is around 1.0V so I guess it is okay too. now I am trying to make two series circuit of those as unfortunately resistance seems not enough for my use.

  1. The MCP4132 comes in different resistance options. You have not indicated the full part number of the ic you have. What is the number on the chip ?
  2. The image posted is blurry and it is not possible to read the value of the circled resistor R232 . What is the value?
    If it is 61.9k, then you will need the 100k version of the MCP4132, and actually only need the rheostat version.
  3. The issue you mention of the resistor not being connected to ground on either side may be addressed by using
    an analog switch IC to switch different value resistors in parallel with R232. The ADG511 has a minimum Vdd (positive supply rail) of 4.5V The image posted does not indicate the power supply voltage for the chip in question
    shown in the image. I see 3.3V in red but don't see that going to a power pin. Is that the chip power voltage ?
    If so is that something that is fixed or can you run the chip off 4.5V ? If that's possible you can have a bank of resistors bussed together on one side and control the other sides with the analog switch. You would have to
    figure out what values you want to use based on what your need is.

Hi again,

I followed the diagram from the datasheet to use it as rheostat, I found it working strangely..
My diagram is like below, and between AB, A'B' respectively expected max 100k ohm. But somehow only one works properly up to 100K, the other works only about 80K maximum.

The idea was I make these two as serial resistance as 100k seemed not enough to attach the system. But when I attached it to controller, my circuit seems not really function as 180K resistance. Is this somehow related with different voltage between two circuits? (One with arduino, the other with motor controller circuit)

Any hint would be appreciated..

raschemmel:

  1. The MCP4132 comes in different resistance options. You have not indicated the full part number of the ic you have. What is the number on the chip ?
  2. The image posted is blurry and it is not possible to read the value of the circled resistor R232 . What is the value?
    If it is 61.9k, then you will need the 100k version of the MCP4132, and actually only need the rheostat version.
  3. The issue you mention of the resistor not being connected to ground on either side may be addressed by using
    an analog switch IC to switch different value resistors in parallel with R232. The ADG511 has a minimum Vdd (positive supply rail) of 4.5V The image posted does not indicate the power supply voltage for the chip in question
    shown in the image. I see 3.3V in red but don't see that going to a power pin. Is that the chip power voltage ?
    If so is that something that is fixed or can you run the chip off 4.5V ? If that's possible you can have a bank of resistors bussed together on one side and control the other sides with the analog switch. You would have to
    figure out what values you want to use based on what your need is.

Hi raschemmel, thanks for the comment.

  1. my chip is MCP-4132-104E, so 100K ohm
  2. Yes, initially I thought that one of 100k rheostat would be enough (after I manually tested with variable resistance) but somehow it doesn't fully function 0-to-100k range in the circuit. I have no idea why so that's why I tried to use two chip instead to achieve 200k..Maybe I am heading wrong way?
  3. Sorry for the blurry picture, that was only what I could get. But yes you are right it is 61.9k-ish and the controller chip is TCA955 which use supply voltage 12v-13v.
    Originally R225(21.5K)/R232(61.9K) thus it has two modes of resistance in total respectively (21.5k / 15.9k). I am not sure if your suggestion meant to install different resistance with switches..If so, that was what I played with variable resistors so far. Now I want to control the resistance by arduino around 10k to 150k more programmable way.

Now I want to control the resistance by arduino around 10k to 150k more programmable way.

I believe it has already been mentioned that the MCP4132 would only work if one side was grounded, whereas the
analog switch method I proposed does not have that limitation. It will work with the same power supply you have
for the TCA 955. If you proceed with the MCP4132 do not expect it to work correctly because one side is not grounded.

Voltage on all other pins (PxA, PxW, PxB, and SDO) with respect to VSS ............................ -0.3V to VDD + 0.3V

The ADGS1414D analog switch will work up to +15V + 10% (16.5V), plus the Vss can be negative up to **-**16.5V,
although, I believe for your application you would want to use 0V. (the TCA 955 GND)
You can connect a bank of resistors together on one side and connect that to one end of R232 and connect the
other end to the switch inputs and bus the other side of the switches together only one switch is activated at a time
or you could go the other route where each switch is a parallel circuit and operating more than one switch at the same time results in parallel combinations of resistors. It is a SPI controlled chip . You would need to post on the
Programming Topic forum for help with the SPI code as software is not my area of expertise, although based on
some SPI code I looked at for the MCP4162 it is similar. You have to look up the address of the register and send
that as the command byte and follow it with a value to store in that register. For example, the SW_DATA register
is 0x01 , and writing the value 0x02 would turn on only switch 2. The registers are in Table-12 of the ADGS1414D
on page 25.

raschemmel:
I believe it has already been mentioned that the MCP4132 would only work if one side was grounded, whereas the
analog switch method I proposed does not have that limitation. It will work with the same power supply you have
for the TCA 955. If you proceed with the MCP4132 do not expect it to work correctly because one side is not grounded.The ADGS1414D analog switch will work up to +15V + 10% (16.5V), plus the Vss can be negative up to **-**16.5V,
although, I believe for your application you would want to use 0V. (the TCA 955 GND)

Thank you very much raschemmel, I think now I get what you said. I appreciate very much.
Yes it seems analog switch is the way to go. But it seems usually analog switch has 4 to 8 channels, right? I didn't think about it because I was dreaming to control the motor smoothly 1-128 step of resistance(digipot) so I may need to think how I can this with analog switch..
And I really like to ask last question too. Sorry, you seem really the person know the circuits properly I should take a chance. You've been talking about operating voltage and different models. So I wonder what would be the rule for you choosing proper device. (yes, it's broad question!) In my case, as I was considering to run my component with Arduino so basically I assumed those will share the power supply. (+5V/GND) I've noticed your consideration based on more target system, I was wondering what would be better choice specially like this case that I want to build something to engage other system. Maybe it is sensible to start from target system (12V or higher DC V) to within arduino spec(5-12V) and components?

I was dreaming to control the motor smoothly 1-128 step of resistance(digipot)

Sorry, I missed that part . I don't think it was in your OP (Original Post).
I will have to rethink this. I can't think of a solution at the moment. I'm not even sure your current circuit can be modified to do that.