a1tD0000006kkNbIAI

Course: Introduction to Programming with NAO
10: Sounds

  • 6-8 grade
  • Beginner

Lesson Description:

In this lesson, the students will make Nao robot add sound effects to their story by using the Play Sound box in Choregraphe.

 

image description

Lesson Modules


Teaching Tips:

Before Class
Room Setup
Follow the Room Setup Instructions.
Load  The Choregraphe Program
Find the Choregraphe sample program that corresponds to this lesson. Make sure it runs on one of the robots. 
Wash Hands
Have all students wash their hands before entering the class. 

Introduce the Lesson
Problem of the Day (5 minutes)
Have a student read the problem of the day. Discuss what it means. Today the students will make Nao use sound effects while telling the story. 
Sample Program (5 minutes)
Run the sample program and have the students fill out the Robot Story! activity.
Designate one student to interact with the robot throughout the story. 

Before Class
Wash Hands
Wash your hands before entering the lass. 

About the Lesson
Problem of the Day 
Read the problem of the day. The problem of the day is "How can you make NAO add sound effects to your story?" You will discuss what this means with your teacher.
Sample Program 
Watch the sample program your teacher shows you carefully. Then Fill out the Robot Story! questions. 



Robot Story


Listen to Nao tell his story then answer the questions on this page.

What sounds did Nao make while telling the story?

How did the sounds relate to the story?

What sounds do you want to use in your story?

 

Now, draw a picture of the wolf blowing the houses down on a piece of paper.


Teaching Tips:

Your Story! (5 minutes)
Have the students fill out the Your Story! questions. 
 


Your Story!


Today you will make Nao use sound effects while telling your story. 

At what part in your story are you going to use sound effects?

What sound effects do you want to use?

Where else are you going to use sound effects?

What will these sound effects add to your story?

Now that you have at least two places in your story where you want to use sound effects, it’s time to think about how you will add them in! In the next module you will learn about a new block called Play Sound. But before you do, you should decide on the flow of your program.


Lesson 1 code solution: https://www.robotlab.com/hubfs/Education.Robotlab.com/Storytelling/lesson%201%20-%20Welcome/Lesson1.zip

Open your program from the last lesson and look at how your program works or “flows”. See if you can walk yourself through how your program goes.


Here’s an example:

Think of a number between 1 and 50. Call that number your guess.

number = 10



if guess == number:

    print('Congratulations, you guessed correctly!')

    # New block ends here

elif guess < number:

    print('Guess higher')

else:

    print('Guess lower')


Can you describe (in plain English) the way the program will work?


Here’s how we’d do it:

The value of the ‘guess’ variable is 5. The value of the ‘number’ variable is 10.

The first if statement (guess equals number) will be skipped.

The second if statement (guess is less than number) fits, and “Guess higher” will be printed.

The final if statement (guess is greater than number) will be skipped.

Can you describe the way the program would work if you changed the value of your guess to 10?


Take a look at this flow diagram. It explains the flow of the program like you just did, but instead of just using words, it uses an easily followed flow chart.


Try drawing a flow diagram for your program so far.

When you have finished, set it aside.





Teaching Tips:

Demonstrate New Content (10 minutes)
Show the students how to download the sound effects, and then how to find the sound effects from their computers. Demonstrate how to add the sound effects to their project content. Next, show them how to use the Play Sound box. Finally, have them read the Sound Effects! on the student view. This will reinforce what they have just learned. Here is a sample Choregraphe file for this lesson. 


Student Implementation (25 minutes)
Have students work on adding sound effects to their story in Choregraphe. Students often struggle with browsing through the sound effects and adding them to their project. Work with the students individually to make sure they can all add the sound effects to their projects. When they are done, they should move on to the Reflect and Revise module.


Use this reference sheet for more details.

Sound Effects!


Follow the instructions below to add sound effects to your story. 

Finding the Sound Effects

1) If the sound effects are located on your computer,

​​

  • Download the sound effects to your computer.
  • Click the window icon at the bottom of your screen.
  • Click the documents icon.
  • On the left column of the file explorer, click “download”.
  • Double click on “Sounds”, and find the sound you want.
  • Double click the sound file to listen to the sound effect.



  • Once you have found your sound effect, right click and copy the file.




  • Find your Choregraphe project folder and paste the sound file into that folder.
  • Go back to Choregraphe.

For Nao V6 you need to import the file to the project before adding. Click the cross botton on the top and select import files

Select the sound you want to import




Add the Sound Effect to Your Story
  • Drag a play sound box onto the workspace.
  • Press the wrench in the bottom left corner of the box.
  • Click the file icon next to the “File Name” field.


  • Select the sound effect from the listed files.
  • Press OK. Press OK again.



Use this reference sheet for more details.


Go back to the flow diagram you completed in the last module. Add the new functionality you just created to your diagram.

How difficult was it to add the new functionality to your diagram?
  • Easy - I barely had to change a thing
  • Medium - I had to change/move a couple things
  • Difficult - I had to redraw the entire thing!

Why draw a flow diagram? It is a simple way to explain a program, and as your program gets more and more complex, you may find it useful. If you become a programmer in the future, and you take on a project started by someone else, you’ll hope that they made a flow diagram too!


 

Teaching Tips:

Silent Journaling (5 minutes)
Have students fill out the Reflect! activity. They should work silently for a few minutes.

Group Discussion (5 minutes)
After they have journaled, discuss their responses as a group. 


AFTER CLASS


Store Student Files
Put the student files on a thumb drive or store them in some way so that the students can continue working on their project in the next lesson. 

Pack Up Hardware
Pack the robots and computers according to the packing instructions.

REFLECT and REVISE!


Add the sound effects to your code. Then test them on the real robot!

Test your code on the real robot.

Did it work as you expected?

What do you want to change about your code?

What would you like to add?


Improve your story!

What did you change about your story?

What do you still need to change about your story?





Silent Journaling 
Fill out the Reflect! activity. You should work silently for a few minutes.

What did you make your robot do today?

What was your favorite part of your story?

What did you have the most fun programming?



Group Discussion 
After you have journaled, discuss your responses with the group. 




AFTER CLASS
 

Store Your Files
Store your file(s) on a thumb drive or in some way. Follow your teacher's instruction so that you can continue working on your project in the next lesson. 

Pack Up Hardware
Your teacher will pack the robots and computers according to the packing instructions. Follow your teacher's instruction for packing up the hardware.