Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations IDS on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Current control of DC motor using PI controller 1

Status
Not open for further replies.

Gabbbar

Electrical
Oct 2, 2014
6
Hi everybody!

I am trying to implement current control of a DC motor using a PI controller and was having a few questions.

I am supplying 19V as input voltage (and capable of supplying current upto 2A) to the H- bridge and the controlling is done via a microcontroller using PWM.
When I connect 19V (100 % duty )directly to the motor (with a small mechanical load) I measured the current through the DC motor to be 15mA. Does this mean that I can control the current only upto 15mA.
If for this same load and supply voltage, I now give a reference current of 25mA will the controller be able to take power current from the source and give it to the motor. If so, how? (as it was giving 15mA for 100% duty at 19V.)
If not, does it mean that there can be no PI control above 15mA for this case?
Is it possible to make a PI controller for any range of loads connected to the motor ?

Thanks!
 
Replies continue below

Recommended for you

Motor current is proportional to shaft torque. So, if no load - only very Little current.

Try braking the shaft with something and you will get the current you have set.

Best way (if the motor can take it) is to clamp the shaft so motor stands still. Then adjust your current controller for optimum performance (fast and stable step response) then let the shaft run and adjust the speed loop, if you have one.

Gunnar Englund
--------------------------------------
Half full - Half empty? I don't mind. It's what in it that counts.
 
Being so small a dc motor, and you not saying, I will assume it a permanent magnet motor with no field other than permanent magnets. Assuming this, then:


The answer is simple: MAYBE

V=IR+N*Kb <- google how dc motor works.....
-V=volts
-I=current
-R=resistance
-N=speed
-Kb=volts/speed

If you lock the motor shaft so it cannot turn, then you will have V=IR and you will see what the max current will be into that motor at 19v; if you have little load, most of the 19v will instead go into the N*Kb term instead and the current will be very low due to IR.

Googling, you will see I=T/Kt where I=current, T=torque output, and Kt=torque/amp.

 
Thanks a lot guys for the replies!

I did as you suggested and found the current in stand still condition to be around 180mA. I also adjusted the proportional and integral gain such that I have 100% duty cycle at this condition.
Now, when I give a reference less than 180mA and stop it, the dc motor current tracks it. For example, if I give a reference of 50mA and stop it, the motor current, stays around 50mA and does not shoot to 180mA. I tried this for different reference values and observed the same response.
I hope this is PI control of a DC motor current!
 
"I hope this is PI control of a DC motor current!

It sure is.

Gunnar Englund
--------------------------------------
Half full - Half empty? I don't mind. It's what in it that counts.
 
Thanks a lot for all the help!
I deeply appreciate it!
 
I hope that you use correct control for high-/low-side switches of H-bridge and correct current feedback. Can you share us with more details?
 
I am using PWM to control the motor current. First I calculate the duty cycle by the error between the reference and actual value.
This signal goes to the top switch. I invert the first PWM and give it to the lower switch.
The current sensor is in series with the motor and gives actual current value to the micro-controller.
I hope you wanted this info!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor