Microbit Music: Debugging
This lesson will provide students with the opportunity to debug computer code. Students will be provided with the necessary code blocks, but will have to identify, duplicate, and rearrange them for the program to run properly and for the music to play correctly.
OVERVIEW
Activity Overview:
This lesson will provide students with the opportunity to debug computer code. Students will be provided with the necessary code blocks, but will have to identify, duplicate, and rearrange them for the program to run properly and for the music to play correctly.
Meta description
- Subject Area: Computer Science, Music
- Grade Level : 3-5
- Computer Science Domains:
- Algorithms and Programming
- Computer Science Principles:
- Recognizing and Defining Computational Problems, Creating Computational Artifacts, Testing and Refining Computational Artifacts
- Materials:
- Micro:bit, Chromebook
- Considerations:
- An educator will need to be familiar with microbit classroom in order to have example code ready for the students to manipulate and debug.
Lesson Plan
Overview
This lesson will provide students with the opportunity to debug computer code. Students will be provided with the necessary code blocks, but will have to identify, duplicate, and rearrange them for the program to run properly and for the music to play correctly.
ASSESSMENT PRE/POST-TEST
What should the program do? What is the program currently doing? What changes need to be made to the code for the program to run correctly?
OBJECTIVES
Students will be able to debug a program by rearranging, copying, and pasting blocks.
CATCH/HOOK
Students will observe a brief demonstration of a musical performance using a microbit.
ACTIVITY INSTRUCTIONS
Display block code on screen and explain how it works to the class.
Have students open computers and go to classroom.microbit.org, join class, and open the example program.
Work through the example program with students, having them follow along copying the actions of the teacher, including dragging blocks, reordering blocks, and copying and pasting blocks.
Students open a new assigned program and practice debugging the program by implementing the above skills.
When students have successfully debugged the code, they can then load their program onto a microbit to see it runs as anticipated.
Supplements
Any items in this section are the property & under the license of their respective owners.
REVIEW
Class discussion: What is debugging? When and why do we need to debug programs? How did students in the class approach this challenge for
STANDARDS
| Type | Listing |
|---|---|
| CS Domains | Algorithms and Programming |
| CS Principles | Recognizing and Defining Computational Problems, Creating Computational Artifacts, Testing and Refining Computational Artifacts |
| Other Content Standards |