My team is using Victor 888s to control motors. My problem is that when ever I run the test method (which sets them all to 0.7 while the button is pushed and 0 when it is not) the motors either jump one at a time (randomly) or don’t move at all.
This is how I initialized the victors:
Victor left = new Victor(0);
Victor right = new Victor(1);
Victor liftMotor1 = new Victor(4);
Victor liftMotor2 = new Victor(5);
Victor liftMotor3 = new Victor(6);
Victor launchMotor1 = new Victor(7);
Victor launchMotor2 = new Victor(8);
This is the testPeriodic method:
public void testPeriodic()
{
LiveWindow.run();
left.enableDeadbandElimination(true);
right.enableDeadbandElimination(true);
liftMotor1.enableDeadbandElimination(true);
liftMotor2.enableDeadbandElimination(true);
liftMotor3.enableDeadbandElimination(true);
launchMotor1.enableDeadbandElimination(true);
launchMotor2.enableDeadbandElimination(true);if (Stick.getRawButton(2)) { left.set(0.7); right.set(0.7); liftMotor1.set(0.7); liftMotor2.set(0.7); liftMotor3.set(0.7); launchMotor1.set(0.7); launchMotor2.set(0.7); } left.set(0.0); right.set(0.0); liftMotor1.set(0.0); liftMotor2.set(0.0); liftMotor3.set(0.0); launchMotor1.set(0.0); launchMotor2.set(0.0);
}
Thanks so much for your help.