"> ");
Hello guys!
In this lesson, we will do something different. We will play music!
Our robot can play various musical notes.
So, we can see the notes of a song and make Edison play them!
All of this will be done by writing our program. This program needs the function of Edison’s speaker.
Do you remember Edison’s buzzer? It is located next to the sound sensor. With the buzzer, Edison can play simple sounds like a beep or musical notes.
To write a program with musical notes, we will use the purple blocks of EdBlocks. They are in the “outputs” category.
Depending on the duration of each note, there are four different blocks:
The whole note (or 4/4), the half note (or 2/4), the quarter note and the eighth note.
There is also the block “metronome” that gives the tempo or speed: slow, normal or fast.
So, we are going to write a program that tells Edison to play music.
Perfect! Now, let’s make Edison play this tune:
We must download the program to Edison with the EdComm cable, and then we
press the triangle play button.
We can take a sheet music and write those notes with EdBlocks so our robots understand them.
Now, we will make Edison play this tune. Do you recognize it?
Give the correct answer to the questions’ section, at the end of the lesson.
Let’s play a little bit with the “metronome” block.
Like the speed control block, it must be put to the left of the blocks – “notes.”
Let’s use the slow speed…
and now the fast speed!