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 c9d6efb commit 39a19a7Copy full SHA for 39a19a7
programming/motors.md
@@ -83,7 +83,7 @@ Therefore to stop your motors you must explicitly set the power output to zero:
83
~~~~~ python
84
# Put motor board srABC1, channel 1 at 25% power for 2.5 seconds:
85
robot.motor_boards["srABC1"].motors[1].power = 0.25
86
-time.sleep(2.5) # wait for 2.5 seconds
+robot.sleep(2.5) # wait for 2.5 seconds
87
robot.motor_boards["srABC1"].motors[1].power = 0
88
~~~~~
89
@@ -97,7 +97,7 @@ robot.motor_boards["srABC1"].motors[0].power = 1
97
robot.motor_boards["srABC1"].motors[1].power = -1
98
99
# Wait a while for the robot to move
100
-time.sleep(3)
+robot.sleep(3)
101
102
# Stop both motors
103
robot.motor_boards["srABC1"].motors[0].power = 0
0 commit comments