Linear Slides
Commonly Used Extension Mechanism
Prerequisites
Resources:
Implementation
Programming linear slides is usually as simple as setting a viable target position to your motors that control the slides. Note that encoders are required to do this.
When operating two motors together, we highly recommend that you remove any modules from the motors and test your positioning functions first. This will ensure that your motors are moving in the desired direction. Not doing this may lead to you risking breaking your motors or the slides! If one motor is not moving the correct way try setting another target position or reversing its direction.
Exercise (One Encoder, Two Slides)
Due to a lack of encoder slots you may only have one encoder spot left to control both of your slides. To work around this issue you can use the encoder readings from one motor to control both slides via a custom PID loop. Note that this may not be as accurate as using two separate encoders.
Inside your opMode loop, implement the following psuedocode:
Case Study
Take a look at the code of FTC Freight Frenzy world championship winning team, Delta Force!
Last updated