Package edu.wpi.first.wpilibj

Examples of edu.wpi.first.wpilibj.PIDController


        canGyro.start();
        leftEncoder.start();
        rightEncoder.start();

        turnControl = new AsynchronousPIDController(new PIDController(turnP,
                turnI, turnD, canGyro, this));
        leftDriveControl = new AsynchronousPIDController(new PIDController(
                driveP, driveI, driveD, leftEncoder, this));
        rightDriveControl = new AsynchronousPIDController(new PIDController(
                driveP, driveI, driveD, rightEncoder, this));
        pointTurn = true;
        leftDriveControl.addPIDListener(this);
        rightDriveControl.addPIDListener(this);
        turnControl.addPIDListener(this);
View Full Code Here


    canGyro.start();
    leftEncoder.start();
    rightEncoder.start();

    turnControl = new AsynchronousPIDController(new PIDController(turnP,
        turnI, turnD, canGyro, this));
    leftDriveControl = new AsynchronousPIDController(new PIDController(
        driveP, driveI, driveD, leftEncoder, this));
    rightDriveControl = new AsynchronousPIDController(new PIDController(
        driveP, driveI, driveD, rightEncoder, this));
    pointTurn = true;
    leftDriveControl.addPIDListener(this);
    rightDriveControl.addPIDListener(this);
    turnControl.addPIDListener(this);
View Full Code Here

        leftWheelX = -ROBOT_WIDTH / 2;
        rightWheelX = ROBOT_WIDTH / 2;
        leftWheelY = rightWheelY = 0;

        turnControl = new AsynchronousPIDController(new PIDController(turnP,
                turnI, turnD, gyro, this));
        leftDriveControl = new AsynchronousPIDController(new PIDController(
                driveP, driveI, driveD, encodDT1, this));
        rightDriveControl = new AsynchronousPIDController(new PIDController(
                driveP, driveI, driveD, encodDT2, this));
        pointTurn = true;
        leftDriveControl.addPIDListener(this);
        rightDriveControl.addPIDListener(this);
        turnControl.addPIDListener(this);
View Full Code Here

        encoder = new Encoder(encoderAChannel, encoderBChannel, false, CounterBase.EncodingType.k4X);
        encoder.setDistancePerPulse(ENCODER_RPM_PER_PULSE);
        encoder.setPIDSourceParameter(Encoder.PIDSourceParameter.kRate); // use e.getRate() for feedback
        encoder.start();

        controller = new PIDController(KP, KI, KD, encoder, victor);
        controller.setOutputRange(-1, 1);
        controller.enable();
    }
View Full Code Here

TOP

Related Classes of edu.wpi.first.wpilibj.PIDController

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.