We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent db5084a commit 6857340Copy full SHA for 6857340
examples/Tools/Test_Motor_Angular_Control/Test_Motor_Angular_Control.ino
@@ -32,9 +32,17 @@ void loop()
32
return;
33
}
34
35
- for (float angle = 0.0; angle <= 180.0; angle += 10.0) {
+ float const ANGLE_START = 0.0;
36
+ float const ANGLE_STOP = 180.0;
37
+ float const ANGLE_INCREMENT = 10.0;
38
+
39
+ for (float angle = ANGLE_START; angle <= ANGLE_STOP; angle += ANGLE_INCREMENT)
40
+ {
41
Braccio.move(selected_motor).to(angle);
- Serial.println("Current angle: " + String(angle));
42
+ Serial.print("Target angle: " + String(angle));
43
+ Serial.print(" | ");
44
+ Serial.print("Current angle: " + String(Braccio.get(selected_motor).position()));
45
+ Serial.println();
46
delay(100);
47
48
0 commit comments