How can you be sure your image on the display is seen when the program ends?
- #397
- 29 Apr 2017
- 2:40
"The image is in the program but I can't see it"
We hear that phrase from our new students all the time. The reason is that the display block can't be the last block in the program.
When a program running on a robot ends, the display shows the program's menu list and your image is not visible anymore.
Wait a bit to see it
Put a wait block to be able to see the image that was the last block of the program. This way we postpone the end of the program and give ourselves some time to see the image.
English
One of the very common mistakes using the display block is to put the display block as a last block in your program. For example, you do some move forward and then you add the display block as a last block in the program. What will happen then?
Yes, the robot will move forward
but do you see a smiley face? Again.
It appears for kind of a millisecond and then disappears. You see it. The reason is that when you have the display block as a last block in the program first you'll have the motors move forward then the smiley face will be displayed on the brick screen and then the program will end. And when the program ends the whole display is cleared. And because we're not waiting for us to see the smiley face it just disappears. So, this is a very very common mistake with the display block. And the display block doesn't take some seconds to be executed like the sound, the sound will take, for example, a second for playing the sound. But displaying something on the screen happens very fast. So, you should be careful and if you're displaying something just put a wait block to be able to see it. In the program I'll add a new wait block as a last block in our program. In this way we move forward, display a big smile on the brick's screen. And then wait for 1 second and only after that because this is the last block in the program the program will end. So, we postpone the end of the program by using a wait block at the end of the program. Download.
You saw the smiley face. Move forward, show a smiley face, wait for a second and only then the program will stop.
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