Yahboom Omibox Robot Kit Basic Course 3.7 Car Run
1-1. The position of the motor in the robot car
1-2. Learn how to control motion state of robot car by graphically programming
As shown in the figure above, we circled the red wire frame with the motor and wheel, and we can use it by programming.
In this lesson, we will learn the use of Robot sport building blocks to control the motion state of the robot car by programming.
3.Search for blocks
The following is the location of the building blocks required for this programming.
4. Combine blocks
The summary program is shown below:
After the program is uploaded, open the power of the car. The car will advance 2 seconds, back 2 seconds, turn left 2 seconds,turn right 2 seconds, stop 2 seconds, and continue to cycle.
!!!Note: The speed of robot car is set at the bottom of the building block is the maximum value of 255, because the center of gravity of the car is at the rear, so the car may lean backwards when moving forward.This is normal, we only need to adjust the speed of the car. The way to adjust the speed, we will talk about the next lesson.
The code of the experiment: 7.Car Run.rar