frc5687 / 2019-robot

Main robot code for the 2019 Deep Space season
1 stars 1 forks source link

Elevator: pure proportional control #184

Open BenBernardCIS opened 5 years ago

BenBernardCIS commented 5 years ago

Instead of using our ramping both to accelerate and decelerate the elevator, we use the built-in sparkmax current ramping to accelerate. We'd then use a proportional-only PID to determine the desired speed. Assuming we want to run at full speed most of the way and ramp down to .3 over the course of the last 500 ticks, the speed would be .3 + distance * K, where K is .7/500 or 0.0014.