Course: Graphical and Python programming using NAO
9: Interaction

  • 9-12 grade
  • Intermediate

Lesson Description:

In this lesson, students will learn how to make robots interact with humans by doing cooperative motions (handshakes and high fives).

Create an interaction between a person and the NAO robot. 


Standards Covered


By the end of grade 12, read and comprehend science/technical texts in the grades 11-CCR text complexity band independently and proficiently.


Follow precisely a complex multistep procedure when carrying out experiments, taking measurements, or performing technical tasks; analyze the specific results based on explanations in the text.


Evaluate the hypotheses, data, analysis, and conclusions in a science or technical text, verifying the data when possible and corroborating or challenging conclusions with other sources of information.


Synthesize information from a range of sources (e.g., texts, experiments, simulations) into a coherent understanding of a process, phenomenon, or concept, resolving conflicting information when possible.

image description

Lesson Modules

Teaching Tips:

This module is an introduction to the concept of human-robot interaction. The field is getting more and more popular. Many agents we communicate with today can be qualified as a robot. For example, Amazon Alexa , Google assistant, Siri all these devices can be considered to be robots. 

Human-Robot Interaction
Robots can do many things on their own. As humans, we want to build robots that interact with us. You may already interact with robots every day. Some cars can parallel park themselves. Other robots assemble the manufactured goods you use.
Human-robot interaction studies the interactions between humans and robots. This field combines robotics and psychology. It seeks to answer a number of questions. How can humans better control robots? How can humans and robots work together? And, in general, how can we improve the human experience and make robots more effective tools?
In this module, we will program the NAO to interact with humans. The NAO appeals to humans because of its humanoid shape. It is also designed to look “cute”. By the end of this lesson, you will have completed three tasks in which the robot interacts with humans. You will make the Nao communicate with hand motions, including shaking hands, giving a high five, and waving goodbye. You will program the NAO to play peek-a-boo with children. Finally, you will re-enact a scene from a play. After finishing this module, show off the results to children, adults or fellow students outside your class!

Give an example of a human robot interaction.

Teaching Tips:

In this module you will let the students create a code to make NAO interact in 3 different ways: Hello / High Five / Shake. In order to trigger the behaviors, the example uses voice recognition. When not all students have access to NAO an alternative can be the tactile head sensor. 

The code for this program can be downloaded here.

Step by step programming is found under CLASS VIEW.

Basic Task: Greetings
In this module, we’ll focus on how robots can interact with humans. We’ll teach the Nao to shake hands, give a high five, and wave goodbye.
1. Create a new Choregraphe project, with three new Timeline boxes for keyframe motions.

2. For one keyframe motion, make the NAO do a hand shaking motion. For the second, make the NAO give a high five. For the third, make the NAO wave goodbye (you can use the Hello motion box).

3. Now add a Speech Recognition box ( alternatively a tactile head can do the job for when you don't have a physical robot) and a Switch Case box. Set the word list for the speech recognition box to be “hello;high five;goodbye”, and set these three words in the Switch Case box.  And create the rest of the code to make the robot do one of the three actions based on your input ( voice or touch) and say something while performing the actions.

5. Run the behavior, and try saying each phrase on the word list. 

Teaching Tips:

In this module students will design a "peek a boo" routine. 

the code for this module can be found here

The step by step programming is under CLASS VIEW.

Intermediate Task: Peek-a-boo
Next, we’ll make the NAO play the children’s game “Peek-a-boo”.
1. Create a new Choregraphe project, with two new Timeline boxes for keyframe motions.

2. For one keyframe motion, make the NAO hide his face with his hands. For the other, make him put his hands at his side. Be sure to make these gradual transitions.

3. Add a speech recognition box, which recognizes the phrases “peek a boo” and “I see you”. Also add a face recognition box connected to a switch case box, which does nothing on receiving 0 and continues on in the default case. The robot should play the game in a cycle.

4. Create a" Peek a boo" routine and program it using Choregraphe. 

5. Try playing peek-a-boo with the NAO.

Teaching Tips:

This module lets the students create an act from scratch using the tools in Choregraphe they know. 

One example of code can be downloaded here

Advanced Task: Storytelling
Next, we’ll make the NAO either tell a story or act out a scene from a play. Choose either a short scene or a skit that interests you. Use a combination of voices and motions on the robot. You have already learned all the skills needed to do this exercise, so no step-by-step instructions will be provided. A few hints and suggestions:

  1. If the scene has multiple characters, try changing the voice parameters and head lights to differentiate between them.
  2. Use expressive hand gestures and move the NAO’s head.
  3. Use a variety of lights.
  4. Try including sound effects.
  5. Use the “Wait for Signals” box to wait for multiple boxes to finish (i.e., speech and motion) before beginning the next action.
  6. Use “Wait” boxes to insert dramatic pauses into the script.
  7. Be creative!


Teaching Tips:

Additional Exercises
  1. Make the NAO play rock paper scissors. Think carefully about how to modify the hand gestures for NAO’s hand and arm.
  2. Divide the class into several groups, and make each group responsible for delivering the lines of a character in a specific scene of a play. Combine the groups’ results to enact the play. If available, use multiple robots.
  3. Bring the NAOs to an elementary school, and show the class projects to the children at the school.

Teaching Tips:


  1. Describe human-robot interaction.
    The field studying how humans and robots interacts, and how robots can be made both easier and more pleasing to use for humans.

  2. Give an example of a robot that interacts with humans.
    A car that parallel parks itself (or other examples).

  3. Give a reason why humans find the NAO an appealing robot.
    It is shaped like a human and looks cute.

  4. Discuss how multiple robots would need to cooperate to enact a play together.
    They would communicate wirelessly to remain in sync, executing the same parts of the script in unison.

Describe human-robot interaction.

Give an example of a robot that interacts with people.

Give a reason why humans find the NAO an appealing robot.

Discuss how multiple robots would need to cooperate to enact a play together.