Please enable JavaScript to use CodeHS

Introduction to Physical Computing with micro:bit

Lesson 2.1 For Loops

Description

In this lesson, students will connect a speaker to their physical circuit to play music using their micro:bit! They will learn to use for loops to control components, along with the playNote command.


Objective

Students will be able to:

  • Use for loops to control the flow of their programs
  • Control an external speaker by using the playNote command in micro:bit programs
  • Understand the correlation between frequency values and the pitch of a tone