1, 2, 3, code ! - Cycle 1 activities - Lesson 2.2. Colors and behaviors


Students learn that Thymio has several modes and can behave differently depending on the chosen mode. 

Key ideas
 (see Conceptual scenario)


  • A robot can perform actions: move, make a sound, produce light, etc.
  • A robot has sensors that let it perceive its surroundings.

Inquiry-based methods

Observation, experimentation


For each group:

  • A Thymio, with its batteries charged

For each student:

  • The Thymio drawing from the previous lesson

For the teacher:

  • Handout 8 (used in the previous lesson)
  • An A3 or A2 size flip chart


Sensor, wheels



30 min



Just before the lesson, the teacher turns the Thymio robots on and sets them to different modes (green, yellow, red and purple). Note that it is best to select the yellow mode at the last minute, otherwise it will move around the table on its own.


Starting the activiy

Each group tries to understand how Thymio is behaving when displaying a particular color. The teacher starts off the experiment by turning on the Thymio robots that are to be in yellow mode.


Experiment: Which behaviors correspond to which colors? (in groups)

Aside from the yellow mode, the other modes do not immediately start Thymio moving. If the students do not think of it on their own, suggest they place obstacles near the robot (a hand, an object, etc.).

When the Thymio robots begin to move (green and red modes), ask the students to figure out which part of its body allows the robot to detect obstacles and have them identify the distance sensors. They can make the connection between the robot's actions and the sensor indicators that light up. For example, in green mode, if a sensor detects an object, the indicator light turns red and Thymio begins following the object. The teacher can then officially introduce the term "sensor" to talk about these components.

The purple mode will likely be the most difficult to understand. The teacher can tell the students that the on/off button is also a sensor. The arrows could also be considered sensors.


Teaching notes:

·         For a smoother observation process, a few rules should be established from the start:

  • One student handles Thymio at a time
  • After each manipulation, leave a few minutes to observe and understand the effects
  • Leave some space around Thymio so it can move (students quickly tend to sit very closely around it, which overstimulates the sensors and does not give it enough space to move around)

Kindergarten class, Caroline Fayard, Paris

Group discussion

Each group tells the rest of the class about its robot and explains its behavior by showing which Thymio sensors interacted with its surroundings (obstacle detection or pushing buttons):

  • Yellow Thymio "moves on its own" by "avoiding obstacles."
  • Green Thymio tends to follow objects, like a hand, placed in front of it.
  • Red Thymio moves away from objects placed in front of, behind or beside it.
  • Purple Thymio moves forward or turns depending on the arrows that are pressed.

As a group, try to give each behavior a name (e.g., friendly, fearful, explorer, obedient). The teacher concludes the group discussion by asking how Thymio moves. The students will quickly point out the wheels.

Scientific notes:

  • Sensors are components that let a robot perceive its surroundings (including a person's actions).
  • The actuators are components that let the robot interact with its surroundings (here, by moving).


Exercise: playing with the other modes

The students swap robots to explore the other modes.


Conclusion and lesson recap activity

The class summarizes together what they learned in this lesson:

  • Thymio can be in different modes, each indicated by a different color, which determine the robot's behavior.

On their sheet of A4 paper, the students complete their drawing of Thymio, labeling the sensors and wheels.

On the board, the teacher describes the four initial modes, labeling each with a color, the adjective used to describe the mode (and/or an icon chosen by the class to designate the behavior, such as smileys).

A fifth line should be prepared ahead of time to describe the turquoise mode, which will be covered in the next lesson. This experiment will require some advanced preparation by the teacher, who will likely want to prepare the routes for Thymio to follow (see next page).

Although Handout 8 describes six behaviors, only five of them will be explored by the students. We do not recommend working in blue mode. Because Thymio reacts to sounds, the classroom can quickly become chaotic.



<< Lesson 2.1 Sequence II Lesson 2.3 >>


Project partners

Aucun résultats