Let's Make Robots!

Digital Pot with USB

Hi all. I want to control servo motor with AD5206 digital pot but i don't know how to do it. Just replace the analog pot with digital one in the servo controller schematic.How can i control the pot from pc via usb without using Arduino or PIC?Is it possible? Thanks.
AttachmentSize
ServoController.gif3.86 KB
AD5206.jpg23.12 KB
PIN_OUTS.jpg57.88 KB

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Thanks for all but i guess i didn't explain myself clear. I open the servo and made a kind of bypass on the pot which inside the servo; soldered 2 same resistance instead. Now servo can turn 360 degrees.

Than i build a controller that you can see in the attachment. I just want to change the pot inside the controller which is 100k

In the future i need to control wireless.

Two direct questions.

1-What is it that you are actually building(ie, what will it do, what function will it serve, is it refined to a particular environment and what will it look like-don't be misleading or vague, and if you're afraid someone is going to steal your idea you're looking for help in the wrong place.) ?

2–Why do you have a problem with using a microcontroller?

I think that some context would be helpful here. Why don't you want to use a microcontroller? You won't end up saving a lot of money by doing what you seem to be proposing here, however by using a microcontroller you will save yourself a lot of time and headaches.

In any case you should be able to just replace the regular potentiometer with an output pinset of the AD5206 fairly easily. It might not function the way you'd expect since the device is digital and the wiper connects back to one pole of the pot in the 555 circuit, but then again it might work just fine. It would simply be a matter of inserting the pins that make up one AD5206 output (eg, A1, W1 and B1) into the servo control circuit between pin 7 and the resistor attached to pin 8 with the wiper (W1 in our example) patched back to pin 7 as well.

The "fun" part is going to be trying to control the digital pot from USB. It looks like you'll need a USB to Serial converter-except the AD2506 doesn't seem to have an SDO. Usually that means it's "active high" but again, headaches-you might be looking at a wierd serial here. Let's say you get an FTDI chip for this-you'll have to do a whole lot of programming from scratch to control the virtual potentiometer (I'm assuming a sample program isn't provided for you since you're asking how to connect the chip to USB.)

I can almost guarantee you that using the 555 to control a servo will not give you great results. Chances are any servo you put on it will jitter continuously, and even if you are using a digitally controlled pot to set the pulse width frequency it probably won't guarantee positional consistency in the servo (in other words if you send the AD5206 the value sequence 128, 64, 128 the servo probably won't end up in the same place for each 128 value.)

If you replace the pot in the servo with a digital pot then all you have done is turn the servo into a continuous rotation servo. If you don't modify the gearbox then you will have a dead servo. Removing the standard pot removes the feedback in the motor control loop.

If you are trying to make a standard servo work from I2C instead of PWM then you are doing it completely wrong.

I don't think Ruby is talking about replacing the pot inside the servo here-rather that he/she wants to control the servo using a 555 timer and controlling the 555 clock using the digital pot (and controlling that digital pot using USB.)

I think you are right Maxhirez, he just wants to control a servo from the PC and for some reason insists in going:

PC USB -> "something" -> digital pot -> 555 timer -> servo :)

Why would you want to put a digital pot into a servo?

What you are trying to do can be done, but it is way more complex than needed and won't work all that well.  You would have to have a microcontroller to get data from USB and translate it then write it to the digital pot which then causes the 555 circuit to adjust it's pulse width for the servo.  A much better solution is to just have the microcontroller create the pulses for the servo directly.  An Arduino has everything you need: a USB interface and pins that can control servos directly.  There are quite a few robot projects on LMR that have done exactly that.  Another advantage is that the arduino can control several servos without any additional hardware..