Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Technical Discussion (http://www.chiefdelphi.com/forums/forumdisplay.php?f=22)
-   -   Flywheels and Shooter Wheels (http://www.chiefdelphi.com/forums/showthread.php?t=104598)

Cal578 19-03-2012 23:18

Re: Flywheels and Shooter Wheels
 
Thanks for posting code, Baronep. How did you determine the constants for your PID?

Ether 20-03-2012 00:10

Re: Flywheels and Shooter Wheels
 
Quote:

Originally Posted by Cal578 (Post 1144967)
I understand the basic theory of PID control (I'm no expert, but I have a good idea of the general process). I'm looking for advice on how to obtain the constants for the controller. I figured that might be different for Jag-based PID v. cRIO.

Try this instead:

http://www.chiefdelphi.com/forums/sh....php?p=1146353



Cal578 20-03-2012 08:36

Re: Flywheels and Shooter Wheels
 
Thanks for the link to that thread, Ether. I especially liked the clear description of feed-forward, including your diagram.

We're heading to our second regional (Buckeye) tomorrow, and will implement some (wish we could do all) of the ideas in this thread. I'll let everyone know how it turns out.

Even if we don't have time to implement most of these improvements during competition, I now have more ideas for off-season projects for the team.

Ether 20-03-2012 13:53

Re: Flywheels and Shooter Wheels
 
Quote:

Originally Posted by Ether (Post 1146518)

This could very well be the ideal way to control a shooter wheel's speed.
  • Fastest possible spin-up and recovery time
  • No tuning necessary
  • Stable over a wide range of loads
  • Extremely simple to code in any language
Think about how this works. Whenever the measured speed is below the setpoint, full voltage is applied to the motor, providing the fastest possible spin-up and recovery. When the motor reaches the desired speed, the power is removed (voltage set to zero). Since we are controlling speed (not position), there is no overshoot due to "momentum". There is no "momentum" to carry it past the setpoint, since the setpoint is speed, not position. Once the power is removed from the motor, the acceleration goes to to zero immediately*, so there is no further increase in speed.

The only overshoot is caused by the sample time: since this is not a continuous (analog) but rather a discrete (digital) controller, the power to the motor is updated only once each execution cycle. But if the execution cycle time is 20ms (e.g. TeleOp), then the maximum overshoot in rpm would be 0.020*wheel_acceleration_in_rpm_per_second. At motor speeds typical for a shooter and with sufficient moment of inertia in the wheel, the wheel acceleration is low enough that when multiplied by 0.02 creates a very small maximum overshoot.

Once the wheel is at the setpoint speed and the power has been removed, the wheel will of course begin to decelerate (due to friction, windage, etc). But the moment it goes below the setpoint, maximum voltage is again applied* and the cycle repeats.


*subject to any voltage ramping that may be in use


All times are GMT -5. The time now is 04:32.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi