   digitalWrite(rightMotorPin1, LOW);
   digitalWrite(rightMotorPin2, HIGH);
 }
+
+boolean ultraCheck(){
+  /* Utilisation du capteur Ultrason HC-SR04 */
+
+long lecture_echo;
+long cm;
+
+  digitalWrite(ultraTrig, HIGH);
+  delayMicroseconds(10);
+  digitalWrite(ultraTrig, LOW);
+  lecture_echo = pulseIn(ultraEcho, HIGH);
+  cm = lecture_echo / 58;
+  Serial.print("Distancem : ");
+  Serial.print(cm);
+  Serial.println("cm");
+  delay(10);
+  }
 
 void stopRight() {
   digitalWrite(rightMotorPin1, LOW);


void loop() {
  // TODO Script to win here ;)
}

// Serial


void setup() {
  // Motor Right
  pinMode(leftMotorPin1, OUTPUT);
  pinMode(leftMotorPin2, OUTPUT);

  // Motor Left
  pinMode(rightMotorPin1, OUTPUT);
  pinMode(rightMotorPin2, OUTPUT);
  
  // Ultrason
  pinMode(ultraTrig, OUTPUT);
  digitalWrite(ultraTrig, LOW);
  pinMode(ultraEcho, INPUT);

  // Serial
  Serial.begin(9600);
