NAO Tips Vol. 1

Tip 1. Teaching: Benefits of programming human movements.

Nao’s humanoid form lends it well to programming human movements. This is ideal for students because human movements are their own native movements and therefore somewhat intuitive. This has 2 major advantages when students are learning the broad strokes of being a programmer. The first is they already know the action: this means students put their energy into the programming, not comprehension of the task. The second is that although the students know the actions, these actions are generally intuitive in the sense that students don’t often consciously breakdown the individual steps of physical tasks in their day to day lives - they just do them. So by programming a robot students are required to breakdown and consider the steps that make up human movements.

As an example: try getting your students to program NAO to thrown a small ball. Students are generally very good at programming the broad actions of throwing a ball, however there are to two mistakes in particular that students often make. First, some forget that you need to open the robots hand at the end of the throw for the ball to go somewhere. Second, students often forget that the robot needs to be holding the ball first before it can be thrown. With this task, students often try to put a ball into an already closed fist. The breaking-down of intended movements in programmable stages gives students a unique understanding of programming that is distinct to humanoid platforms such as Nao.

Tip 2. Functional decomposition: converting Chorégraphe sections to Boxes.

As a program get bigger it gets hard to analyse the program and troubleshoot, as there can be too many boxes to look at in one screen. A good habit to get into is to group sections of your program into their own boxes so that it is easier to manage. In programming it is common practise to write separate sections of code which have unique roles; this is called functional decomposition. In Chorégraphe this can be done in two ways. You can create your own box called a ‘Diagram’, in which you create a functional section of your program, or you can convert a group of existing boxes into one box using the ‘Convert to Box’ command.

‘Convert to Box’ is best used when you have already written a program and want to sort sections into their own boxes. All you need to do is select the boxes you wish to convert, right click and select 'Convert to Box' or press Ctrl & k. ‘Convert to box’ works best if you already have the input and output wires in place, as it will create the inputs and outputs of the new Box for you.