"> ");
Hello guys!
In this lesson, we will drive Edison again. However, this time Edison is trapped in a maze.
We have to drive him in such a way that he will come out of the maze! Of course, all of this will be done by writing our program!
To write our program we will use EdBlocks. Let’s find the EdBlocks app. On our computer, we type www.edblocksapp.com in a browser. Another way is to look for the word Edblocksapp on a search engine machine.
Let’s go see our maze.
You will find the maze in the accompanying document titled as “Resources”.
Great!
How can we get Edison through the maze?
Specific moves will be required.
So we have to write a program that tells Edison what moves needs to make, in which order, and how long each one of them will last.
So let’s look at the maze and decide what moves Edison should make first:
1) First he must drive forward
2) Then he must turn left
3) Then, for a while he must go drive forward again
4) Then he must turn right and
5) Finally, he must drive forward toward the finish line.
Okay, we have prepared a list of the moves that our robot has to follow. So we are ready to write our program with Edblocks.
We will use the list of moves we have made to choose the right blocks and put them in the correct order:
1) First he should drive forward... 2) Then he should turn left...
3) Then he should drive forward... 4) Then he should turn right… and
5) finally, it should move drive forward again.
Our program is ready, or almost ready, because the time durations of Edison’s each move are still missing.
But how do we find those times? (Or more correctly, those time durations?)
The best way is to try. We will perform some testing step by step.
First, let’s try the first step where Edison has to drive forward.
We put a value, let’s say 1 sec.
We notice that this value is big and Edison gets out of the maze’s limits.
We put a much smaller value, let’s say 0.1 sec.
We notice that Edison did not reached the point we wanted, so the value we chose was too small.
We choose another value, slightly bigger, let’s say 0.2 sec.
We see that Edison reaches the point we want! We found the correct value.
We follow the same procedure to find the time duration for each of the following steps.
It may take several trials but I’m sure that at the end you will find the right values! I will also help you a little bit.
Especially for the time duration of turning to the left and to the right, we already know the answer!
We found it in the section titled “Let’s Turn”. You can use it without needing to look for that again.
How long did each move take? Give your answers to the next questions’ section.
[pdfviewer width=”100%” height=”600px” beta=”true/false”]http://coyotelearner.co/wp-content/uploads/2018/04/Barcodes-info_EN.pdf[/pdfviewer]