Skip to main content

1.1

Major VersionM

by Pete Prodoehl

Introduction

Connect a piezo speaker to a Bit Board and control it with code.

We'll explore how we can make sounds using a piezo speaker.

Video Overview

Featured Document

  1. We'll use Maker Tape to connect the Piezo  to the Bit Board on a LEGO baseplate. The Piezo will connect to Pin 8 and to Ground (GND).
    • We'll use Maker Tape to connect the Piezo to the Bit Board on a LEGO baseplate.

    • The Piezo will connect to Pin 8 and to Ground (GND).

    • You'll notice the Ground on the Bit Board (as well as the Piezo and other Crazy Circuits components we'll use) is color coded White.

  2. If you've never used a micro:bit before you'll want to check out this guide:  Bit Board V2 Setup and Use
    • If you've never used a micro:bit before you'll want to check out this guide: Bit Board V2 Setup and Use

    • We're going to load the following code for our Piezo CC vs Built-in program: https://makecode.microbit.org/_WF90o32Dd...

    • The micro:bit (since the release of version V2) has included a built-in piezo speaker on the back. This guide will show you how to use both the Crazy Circuits Piezo we've connected as well as the built-in piezo on the micro:Bit and how to choose between the two.

    • It may be worth taking a quick look at the set Audio Pin page for more in-depth information.

    • Once the code is loaded it should start running immediately.

    • You can power the micro:bit via the USB cable you used to load the code or you can use a battery pack plugged into the Bit Board.

    • Press the A Button on the micro:bit and a sound will play on the Crazy Circuits Piezo Speaker we connected with Maker Tape.

    • Press the B Button on the micro:bit and a sound will play on the piezo speaker on the back of the micro:bit

    • The built-in piezo may be a bit louder. You can adjust the volume in the code to try making the volumes equal to each other if desired.

Finish Line

Attached Documents

Pete Prodoehl

Member since: 3/4/20

1,840 Reputation

424 Guides authored

0 Comments

Add Comment



View Statistics:

Past 24 Hours: 0

Past 7 Days: 1

Past 30 Days: 3

All Time: 38