Controlling a Servo using PID control.

Hi Guys,
Wonder if you could help me.
I am learning about Simulink and the Arduino. I am trying to use PID feedback control with PWM but I'm not sure that makes sense due to the results.
I have a continuous servo that reads a value from 0 to 180 and a pot as an analog in and they work fine together and it is calibrated nicely.
Now I am trying to improve the response time mimicking an experiment that I did at Uni to control a servo using PID control.
So I have my input value going into a sum through a PID controller to the servo with the input signal going to a scope. From the servo read, the signal goes into the sum as a minus, and that signal also goes to the scope.
But trying to tune the PID controller, the signal just goes from high to low as PWM of 5Hz.
I am clearly missing something here.
Sample rate is set to 0.01
P = 1 I = 0 D = 0
Let me know what other info I need to give. D

3 件のコメント

Robert
Robert 2013 年 4 月 16 日
Ok, I found my answer, and yes it was a stupid question, but if anyone stumbles upon this question and is stuck like I was. Servo motors have inherent feedback control in the form of a PID controller, but enerally for positional control it is only the 'P' proportional and 'D' derivative that used.
Gaurav Pipersaniya
Gaurav Pipersaniya 2013 年 5 月 27 日
can you tell me how can i do this project. actually i have to do project on pid controller similar to yours using simulink so if u can help in detail?
Steve
Steve 2014 年 11 月 9 日
Do you have a mathematical model for the servo you were using(assuming it was a hobby servo) ?
Did you get through Gaurav Pipersaniya ?

サインインしてコメントする。

回答 (0 件)

カテゴリ

質問済み:

2013 年 4 月 15 日

コメント済み:

2014 年 11 月 9 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by