0-5v output from pwm

I have a motor driver that has a 0-5v control input. I would like to drive it with an arduino pwm pin. Is it just as simple as putting a cap on the line to smooth the signal? And if so, how do I determine the capacitor size? Thanks! Bryan

Is it just as simple as putting a cap on the line to smooth the signal?

No, a minumum is an RC pwm filter. http://electronics.stackexchange.com/questions/34843/how-determine-the-rc-time-constant-in-pwm-digital-to-analog-low-pass-filter

You need to have a transistor as well as you can't get enough current to drive a motor from a pin.

This is the motor driver I want to control ... http://dx.com/p/dc-6v-90v-15a-pwm-motor-speed-control-switch-governor-green-black-160094

It has a pot controlling a 0-5v input, but I would like to use an arduino to control the input.

Show us the schematics..

pito:

Is it just as simple as putting a cap on the line to smooth the signal?

No, a minumum is an RC pwm filter. http://electronics.stackexchange.com/questions/34843/how-determine-the-rc-time-constant-in-pwm-digital-to-analog-low-pass-filter

From looking at the link, I am thinking that an R/C circuit would be sufficient. This is the motor driver I want to control ... http://dx.com/p/dc-6v-90v-15a-pwm-motor-speed-control-switch-governor-green-black-160094 Does it look like an R/C circuit would work?

You need a digital pot to control that, unless the schematic of it shows the pot is just a voltage provider.

..or a servo.. :) We need to see the schematics of the controller to discuss the possible solution..

unfortunately the site does not provide any schematics. There is a +5v, Gnd, and 0-5v signal wires to the pot (remotely wired).

What is a digital pot?

What is a digital pot?

A chip that acts like a pot but you control it digitally. It has connections for both ends and a wiper. See if there is a dead short between the ends of the pot and the power rails. If not you need a digital pot.

Grumpy_Mike:
See if there is a dead short between the ends of the pot and the power rails.

The center tap on the pot measures 10.4k to the +5v wire when turned one way and 6 ohms when turned the other way.

Grumpy_Mike:
You need a digital pot to control that, unless the schematic of it shows the pot is just a voltage provider.

Well the product description link he posted had this as a bullet point:

  • Control voltage: 0~5V (voltage-controlled, with a PLC can control the motor speed directly)

So I would think a simple R/C low pass filter might work. Worst case he might have to wire the R/C filter output to a opamp buffer stage depending on the input impedance of that motor controller control voltage input wire/pin.

Lefty

bryanb334:

Grumpy_Mike: See if there is a dead short between the ends of the pot and the power rails.

The center tap on the pot measures 10.4k to the +5v wire when turned one way and 6 ohms when turned the other way.

Looks like a standard 10k pot. I'd tinker with a capacitor, high value resistor, and possibly a diode to smooth the arduino analog PWM. Might do what you want without getting too complex. Otherwise, you probably can study the circuit board and tap the arduino PWM in at the same place on the board as the pot controlled PWM generator.

zoomkat: Looks like a standard 10k pot. I'd tinker with a capacitor, high value resistor, and possibly a diode to smooth the arduino analog PWM. Might do what you want without getting too complex. Otherwise, you probably can study the circuit board and tap the arduino PWM in at the same place on the board as the pot controlled PWM generator.

How do I determine the cap and resistor values? Thanks for the help guys!

bryanb334:

zoomkat:
Looks like a standard 10k pot. I’d tinker with a capacitor, high value resistor, and possibly a diode to smooth the arduino analog PWM. Might do what you want without getting too complex. Otherwise, you probably can study the circuit board and tap the arduino PWM in at the same place on the board as the pot controlled PWM generator.

How do I determine the cap and resistor values? Thanks for the help guys!

The first thing to find out (I don’t know) is what state the arduino analog PWM is in when it is low, probably either high impedance or tied to ground. If the pin goes to ground, then a diode might be needed to help charge the capacitor, possibly reducing the final voltage by .7v.

zoomkat:

bryanb334:

zoomkat: Looks like a standard 10k pot. I'd tinker with a capacitor, high value resistor, and possibly a diode to smooth the arduino analog PWM. Might do what you want without getting too complex. Otherwise, you probably can study the circuit board and tap the arduino PWM in at the same place on the board as the pot controlled PWM generator.

How do I determine the cap and resistor values? Thanks for the help guys!

The first thing to find out (I don't know) is what state the arduino analog PWM is in when it is low, probably either high impedance or tied to ground. If the pin goes to ground, then a diode might be needed to help charge the capacitor, possibly reducing the final voltage by .7v.

What are you trying to say? Diode?

A simple low pass filter of a arduino pwm analog output pin would be a series resistor from the pin to the device being sent the filtered voltage, then a capacitor wired from resistor output to ground. I've used 5K ohm with 10 ufd cap with good results if I recall correctly.

Lefty

what state the arduino analog PWM is in when it is low,

I think you need to read how PWM works, it is a digital output not an analogue output. http://www.thebox.myzen.co.uk/Tutorial/PWM.html

pito:
Show us the schematics…

Nature path. I chatted with one of my friend at Shenzhen this weekend and show the image of this motor driver.

Here is what he told me;-

The driver is overly popular in industry lately, there are a little of hundreds if not thousands manufacture to produce it.
among them, there are a lot of two persons operation; - one for sales, one for design clone and QA. It is much like Apple Computer in 1976. “The original Apple Computer, also known retroactively as the Apple I, or Apple-1, is a personal computer released by the Apple Computer Company (now Apple Inc.) in 1976. They were designed and hand-built by Steve Wozniak. Wozniak’s friend Steve Jobs is only salesman during that time.” and all the part for build will be easily to obtain in days if not hours at local. The physical build is take place here;-

He told me the schematics is not available to his company even they are using a lot of them. if you look it carefully IC name is erased
by sandblasting or sand paper. He indicated all three power mosfet name name is erased as well. of course if I need schematics he could get it for me, but I told him no, not until I start same manufacture business.

Here is perfect example of four know;-

“Know-how” (practical knowledge), “know-what” (facts), “know-why” (science), or “know-who” (communication).

Know-how: manufacture confidentially held.
know-why: what pito asked, and not available.
know-what: use the driver. before I forget he told me driver could works either directly feed 5 V PWM 13~15Khz or DC 0~5V.
know-who: is most important, once u know who, u could forget about all previous three.

The driver could works either directly feed 5 V PWM 13~15Khz or DC 0~5V. is unconfirmed and untested method, YMMV

It is church time (know-who time), everyone have nice weekend!

sonnyyu: The driver could works either directly feed 5 V PWM 13~15Khz or DC 0~5V. is unconfirmed and untested method, YMMV

Thanks Sonnyyu! I will test the direct PWM input this afternoon and let everyone know the results but I have another question. And according to GrumpyMike's tutorial on PWM, the arduino PWM output is at 490Hz. How do I change the frequency of the arduino PWM?

Thanks again all!