How does this construction of VEX EDR turn? It has two motors. Let's start with turning right
- 24 Mar 2017
Turn with one motor
Starting from the program for moving forward we do a small modification. and make of the motors stop while the other is running. What you should do is set the power of one of the motors to 0.
motor[port2] = 50;
motor[port3] = 0;
Looking at the construction of this robot, it turns by rotating one of the motors. The left one or the right one. And depending on which motor you turn it rotates in a different direction. So, it can rotate left or it can turn right. In this video we'll do a small program that makes the robot turn.
Let's see how do we implement the program for this turning.
We start with the program that makes the robot move forward. And actually the only thing we should do we have the configuration for the motors. The first motor if connected on port 2. The second on port 3. And to make the robot turn we just set one of the powers for the motor to 0. And in this way only motor 2 will rotate and motor 3 will not rotate and this will make the robot turn right. Because the motor connected on port 2 is our left motor. And when you move the left motor forward it will make the robot turn right. And at the end we wait for 1000 milliseconds which is one second. Download and run the program.
This is the robot turning with only the motor connected on port 2 running. Again.