Skip to main content

1.1

Major VersionM

by Pete Prodoehl

Introduction

Program the built-in LED Matrix found on the micro:bit and control it with a pushbutton.

We'll explore how we can control the LED Matrix with a single pushbutton.

Video Overview

Featured Document

  1. We'll use Maker Tape to connect the Button to the Bit Board on a LEGO baseplate. We'll connect our Button to Pin 5 and to Ground (GND).
    • We'll use Maker Tape to connect the Button to the Bit Board on a LEGO baseplate.

    • We'll connect our Button to Pin 5 and to Ground (GND).

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

    • While some components have Polarity our Button does not. If you connect it the other way around it will still work fine.

  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 LED Matrix Counter Button V2 program: https://makecode.microbit.org/_Htb6Yc6xd...

    • Our code will change the number displayed on the LED Matrix when the button is pressed.

    • If the button is pressed more than 9 times the count will be reset to 0.

    • While the micro:bit can display two-digit numbers they scroll horizontally across the screen, making them difficult to read.

    • Note that this version will not allow for holding the button down to keep incrementing the number.

    • 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.

    • The LED Matrix will show 0, and with each button press the number will increase by one.

    • Try holding down the button... this time the number will not keep incrementing!

    • Follow along with our recorded Live Stream!

    • You can watch the full video of us walking through this project, along with explaining and exploring the code: https://youtube.com/live/geFYVuV-DI8

Finish Line

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: 7

All Time: 104