This commit is contained in:
samuel desharnais 2023-03-21 18:06:33 -04:00
commit 6608330374
2 changed files with 6 additions and 6 deletions

View File

@ -31,21 +31,21 @@ public class PivoteBrasBas extends CommandBase {
// 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(brasTelescopique.distance()>-13.5){ if(brasTelescopique.distance()>-8.5){
brasTelescopique.AvanceRecule(-0.2); brasTelescopique.AvanceRecule(-0.2);
brasTelescopique.fermer(); brasTelescopique.fermer();
} }
else if(brasTelescopique.distance()<-15.5) { else if(brasTelescopique.distance()<-9.5) {
brasTelescopique.AvanceRecule(0.2); brasTelescopique.AvanceRecule(0.2);
} }
else { else {
brasTelescopique.AvanceRecule(0); brasTelescopique.AvanceRecule(0);
brasTelescopique.ouvrir(); brasTelescopique.ouvrir();
} }
if (pivot.distance()<8.5){ if (pivot.distance()<12.5){
pivot.monteDescendre(0.4); pivot.monteDescendre(0.4);
} }
else if(pivot.distance()>10.5) { else if(pivot.distance()>13.5) {
pivot.monteDescendre(-0.4); pivot.monteDescendre(-0.4);
} }
else{ else{

View File

@ -29,11 +29,11 @@ public class PivoteBrasMilieux extends CommandBase {
// 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(brasTelescopique.distance()>-16.5){ if(brasTelescopique.distance()>-12.5){
brasTelescopique.AvanceRecule(-0.15); brasTelescopique.AvanceRecule(-0.15);
brasTelescopique.fermer(); brasTelescopique.fermer();
} }
else if(brasTelescopique.distance()<-17.5) { else if(brasTelescopique.distance()<-13.5) {
brasTelescopique.AvanceRecule(0.15); brasTelescopique.AvanceRecule(0.15);
} }
else { else {