How to make the robot stay idle while the program is still running.
- #395
- 27 Apr 2017
- 2:02
The Wait block
Go the orange Flow palette and take the second block which is the wait block. The default mode of the wait block is to wait for some time. You can set the number of seconds the robot should wait before the program continues to the next block.
You can think of the wait time block as a "pause".
English
The correct way to implement moving forward, wait and return back is to use a wait block. The goal of this wait block is to make the robot wait, just be there, stay for a number of seconds.
In the software we take a display block, we put on a smiley face, big smile, then we move forward with the steering block for 1 rotation and then we return back with the steering block. You remember that returning back is moving -1 rotation.
The new block that we'll introduce now is not in the green palette, it's in this kind of an orange palette. And we take the wait block. Just drag and drop. What this block will do is make the robot wait for a number of seconds. How many seconds? We set this here. It's just 1 second. So, we put on a big smile, move forward then wait for a second and then move back. It's not a good idea to be very rude if you are a robot and you try to greet a stranger. Just don't be rude. Wait, so the other could reply and then return back. That's our program. We'll use the wait block in many programs from now, it's a very simple block, it's just waiting for a number of seconds. Download and run.
Courses and lessons with this Tutorial
This Tutorial is used in the following courses and lessons

EV3 Phi. Introduction to robotics with LEGO Mindstorms
The things that you will be able to do with your EV3 robot by the end of this course are:
Freely move your robot towards desired target;
Avoid obstacles on the path of your robot using sensors;
Follow lines of any shape;
Detecting and picking up objects of any kind;
- 92
- 220:20
- 36

Robotics with LEGO - Level 1.0 - Adventure in Space
The first level of the Robotics with LEGO curriculum for students in fifth to twelfth grades.
Various constructions with robots are built. Learn how to control the motors so that the robot navigates around the Moon and Earth in various ways. Getting to know the first two sensors. The robot can feel its surroundings with the help of the Touch sensor and avoid obstacles.
The Ultrasonic distance sensor can help the robot avoid obstacles. Students work with concepts like loop, degrees and medium motor. Robots can now do two different actions at the same time - while solving missions on a field, the third motor clears detected obstacles.
- 126
- 123:52
- 150

Level A1. Introduction. Robotics with LEGO
Introduction to robotics - The first level of the Robotics with LEGO curriculum for students in second, third or fourth grades. A journey in space, with robots. Various constructions with robots are built. Learn how to control the motors so that the robot navigates around the Sun, the Moon and Earth in various ways. Getting to know the first of the sensors. The robot can feel its surroundings with the help of the Touch sensor and avoid obstacles.
- 142
- 133:42
- 187
Lesson 3 - Greet a stranger
Introduction
Today we will build a special robot - a spaceship. Nobody knows what to expect in space, that is why we need to be prepared. Our robot should be ready to meet extraterrestrials and even make friends with them!
- 12
- 3
- 5
- 3d_rotation 2