servo control via pid

hello all,

I am controlling a dc motor via a servo and I am using a PID a controller as my controller. The servo position at 600 is when I achieve the max speed of the motor and at 2900 is when the motor is stopped. How do I handle this in the implementation? Any ideas?

Reply to
bxa132203
Loading thread data ...

So when you command 600 whatevers to the servo the motor is going maximum speed, and when you command 2900 whatevers to the servo the motor is going at minimum speed? What ever is your unit of measure?

The conceptually easy way to handle this is to translate your motor speed commands into servo commands, e.g. if your maximum speed is

12000RPM then you calculate the offset and slope using good old y = ax + b:

y1 = 2900, x1 = 0 y2 = 600, x2 = 12000

Then b = 2900, and a = (600 - 2900) / (12000 - 0) ~ -0.192. Then make a regular old controller.

The least-processing way to handle this is to operate your controller in reverse -- bring your speed (or position) command to the subtracting port of your summing junction, bring your speed (or position) feedback to the adding port, and have at it. All the signals in your controller will be negative of what intuition says they should be, but the system will work fine.

Reply to
Tim Wescott

Reply to
bxa132203

Thanks much for the info. I'll try it.

Tim Wescott wrote:

Reply to
bxa132203

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.