Open hasibkyau opened 1 year ago
void goRight() {
LeftMotor.setSpeed(SPEED);
RightMotor.setSpeed(SPEED);
delay(200);
LeftMotor.forward();
RightMotor.backward();
LeftMotor.setSpeed(SPEED-10);
RightMotor.setSpeed(SPEED-10);
if(front<25){
while(front<25){
readSonar();
DisplayStatus();
}
}
else{
while(left<25){
readSonar();
DisplayStatus();
}
}
}