These hands-on activities are designed to enable students to create and test their own machine learning models. Students will use their models to write programs with the Hummingbird Robotics Kit so that they can get a better idea of the power of these models when used in software. For example, the program captured below recognizes types of food and makes the Zombie robot react differently based on which food is detected.
Machine Learning Activities for Snap!

These activities use Google Teachable Machine to create machine learning models that students can incorporate into their Snap! programs. These models are quick to create online but will enable students to develop some intuition for how machine learning works and how it depends on the data that they use to create it. In each activity, students will create and test a machine learning model and then use it in a Snap! program. The mathematics behind such models can be very complicated, but this activity will use a simplified model to give students an idea of what is happening “behind the scenes” in machine learning.
Please note that these activities are designed to be completed in number order. Because of this, Activity 1: Image Recognition has the most detail, and is referenced in the other activities.
Control a Hummingbird Robot with a magic wand!
In this activity, students will create a gesture recognition model to recognize motion patterns on a micro:bit attached to a “magic wand”. Students will then create a program that makes their Hummingbird Robot react to the different motions using radio communication between the two micro:bits.
Acknowledgements
We would like to acknowledge the work of Ken Kahn and Jens Moenig. Ken’s Snap! project for machine learning was used as a reference when developing Activities 1-3, and Jens’ video tutorial is the basis for Activity 4.
