Compare commits
2 Commits
9aa7018812
...
bdffb48ece
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
bdffb48ece | ||
|
|
5f44d5304a |
@@ -46,22 +46,12 @@ public class BougerGaucheAuto extends Command {
|
|||||||
// Called every time the scheduler runs while the command is scheduled.
|
// Called every time the scheduler runs while the command is scheduled.
|
||||||
@Override
|
@Override
|
||||||
public void execute() {
|
public void execute() {
|
||||||
if(alliance.get() == Alliance.Blue){
|
if(timer.get() < 1.25){
|
||||||
if(timer.get() < 0.75){
|
|
||||||
drivetrain.setControl(drive.withVelocityY(1.5));
|
drivetrain.setControl(drive.withVelocityY(1.5));
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
drivetrain.setControl(drive.withVelocityY(0));
|
drivetrain.setControl(drive.withVelocityY(0));
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else{
|
|
||||||
if(timer.get() < 0.75){
|
|
||||||
drivetrain.setControl(drive.withVelocityY(1.5));
|
|
||||||
}
|
|
||||||
else{
|
|
||||||
drivetrain.setControl(drive.withVelocityY(0));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Called once the command ends or is interrupted.
|
// Called once the command ends or is interrupted.
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ public class GrimperReservoir extends Command {
|
|||||||
x = 15.6;
|
x = 15.6;
|
||||||
angle = 180;
|
angle = 180;
|
||||||
if(pigeonAngle< 190 && pigeonAngle> 170){
|
if(pigeonAngle< 190 && pigeonAngle> 170){
|
||||||
drivetrain.setControl(drive.withVelocityY(MathUtil.clamp((-(y-boty)*5.5), -2, 2)).withVelocityX(MathUtil.clamp((-(x-botx)*5.5),-2,2)));
|
drivetrain.setControl(drive.withVelocityY(MathUtil.clamp((-(y-boty)*6.5), -2, 2)).withVelocityX(MathUtil.clamp((-(x-botx)*6.5),-2,2)));
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
if(pigeonAngle>180){
|
if(pigeonAngle>180){
|
||||||
|
|||||||
@@ -68,6 +68,7 @@ public class LEDSubsystem extends SubsystemBase {
|
|||||||
*/
|
*/
|
||||||
public Command updateLEDs() {
|
public Command updateLEDs() {
|
||||||
double temps = DriverStation.getMatchTime();
|
double temps = DriverStation.getMatchTime();
|
||||||
|
System.out.println(temps);
|
||||||
return run(() -> {
|
return run(() -> {
|
||||||
if(Equipe()){
|
if(Equipe()){
|
||||||
if(temps > 110){
|
if(temps > 110){
|
||||||
|
|||||||
Reference in New Issue
Block a user