Closed jcorcoran closed 9 years ago
Yes, that would cause undesirable behavior, and the controller to jump trying to compensate, the abrupt error delta.
I think a way to avoid this is to have a command which zeros the lift. And we call that as the first command in every auto routine. Which drives down and then sets the encoder value to zero. This will happen before the lift controller ever gets used, so as avoiding the scenario above.
I don't plan to zero continuously, just at the beginning of a match.
I thought you wanted to avoid zeroing. Change of heart?
At the beginning of auto*
yea, my avoidance was due to the mechanical team stating the nominal position of the lift would be some height > 0. But as the lift is finally installed, I don't think that is true, and I am sure we can start an auto with the lift all the way down, making the zero process faster.
In either case, if we start with the lift up or down, I am okay with the first command driving down open loop to zero, and then the controller picking up from there. With our first competition 2 days away, I will live with it, its the fastest, cleanest solution.
Modify the lift subsystem to zero itself when the lift has reached its fully lowered position.
@NotInControl @ExcelledProducts Could step changes in position occurring while there's an active position controller cause weird things to happen? e.g. you approach the lowered position thinking you're at 2.2" of travel, you're actually at 0.0" of travel, the lower hall effect sensor trips, the encoder position is reset to zero... what would the controller do? Maybe it depends on what your destination position was...