diff --git a/arduino/sketchdistanceSerial.ino b/arduino/sketchdistanceSerial.ino index 6fa38c4..a40adb7 100644 --- a/arduino/sketchdistanceSerial.ino +++ b/arduino/sketchdistanceSerial.ino @@ -1,5 +1,5 @@ #include "Ultrasonic.h" -Ultrasonic ultrasonic(8,9); // Trig et Echo +Ultrasonic capteur(8,9); // Trig et Echo void setup() { Serial.begin(9600); @@ -8,9 +8,9 @@ void setup() { } void loop () { - int dist = ultrasonic.Ranging(CM); + int dist = capteur.Ranging(CM); Serial.print(dist); Serial.println(" cm"); - delay(100); + delay(100); // 100 ms }