//Activates motors required to vertically move //@param encoderCounts change in counts void driveEncoderVertical(int encoderCounts){ int direction = (encoderCounts > 0) ? 1 : -1; int initialEncoder = getMotorEncoder(backRight); while (abs(getMotorEncoder(backRight) - initialEncoder) < abs(encoderCounts)){ verticalMotors(direction); } stopDrive(); }
void postProcessCommand() { // send coordinates to motors horizontalMotors(hx, hy, hgear); verticalMotors(vx, vy, vgear); }