The Official BBC micro:bit User Guide
eBook - ePub

The Official BBC micro:bit User Guide

  1. English
  2. ePUB (mobile friendly)
  3. Available on iOS & Android
eBook - ePub

The Official BBC micro:bit User Guide

About this book

The go-to guide to getting started with the BBC micro: bit and exploring all of its amazing capabilities.

The BBC micro: bit is a pocket-sized electronic development platform built with education in mind. It was developed by the BBC in partnership with major tech companies, communities, and educational organizations to provide kids with a fun, easy, inexpensive way to develop their digital skills. With it, kids (and grownups) can learn basic programming and coding while having fun making virtual pets, developing games, and a whole lot more.

Written by internationally bestselling tech author Gareth Halfacree and endorsed by the Micro: bit Foundation, The Official BBC micro: bit User Guide contains what you need to know to get up and running fast with the BBC micro: bit. Learn everything from taking your first steps with the BBC micro: bit to writing your own programs. You'll also learn how to expand its capabilities with add-ons through easy-to-follow, step-by-step instructions.

  • Set up your BBC micro: bit and develop your digital skills
  • Write code in JavaScript Blocks, JavaScript, and Python
  • Discover the BBC micro: bit's built-in sensors
  • Connect the BBC micro: bit to a Raspberry Pi to extend its capabilities
  • Build your own circuits and create hardware

The Official BBC micro: bit User Guide is your go-to source for learning all the secrets of the BBC micro: bit. Whether you're just beginning or have some experience, this book allows you to dive right in and experience everything the BBC micro: bit has to offer.

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription.
At the moment all of our mobile-responsive ePub books are available to download via the app. Most of our PDFs are also available to download and we're working on making the final remaining ones downloadable now. Learn more here.
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, we’ve got you covered! Learn more here.
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Yes! You can use the Perlego app on both iOS or Android devices to read anytime, anywhere — even offline. Perfect for commutes or when you’re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app.
Yes, you can access The Official BBC micro:bit User Guide by Gareth Halfacree in PDF and/or ePUB format, as well as other popular books in Computer Science & Systems Architecture. We have over one million books available in our catalogue for you to explore.

Information

Part I

An Introduction to the BBC micro:bit

Chapter 1 Meet the BBC micro:bit
Chapter 2 Getting Started the BBC micro:bit
Chapter 3 Programming the BBC micro:bit
Chapter 1

Meet the BBC micro:bit

In this chapter
check
A look at what the BBC micro:bit is and how it came about
check
A tour of the BBC micro:bit and an explanation of its major components
THE BBC MICRO:BIT is an incredible device, capable of educating and entertaining in equal measure. It can form the heart of a complex robotic or home automation system, or it can simply show a smiley face when you press a button. It can help you come to grips with programming, learn about how electronics work, and even communicate wirelessly with more BBC micro:bits or other devices such as a smartphone or tablet.
You can write programs for the BBC micro:bit in a variety of programming languages, or you can use programs others have written. You can use the BBC micro:bit in the classroom, the club, the playground, or at home. You can play games, solve problems, and invent new devices, all with your BBC micro:bit.
Before all this, though, you’ll need to meet the BBC micro:bit.

A Tour of the Board

The BBC micro:bit is what is technically known as a microcontroller development board. That is, it’s a printed circuit board (PCB) which contains a microcontroller on which you can run your own programs and connect your own hardware.
The first microcontroller development boards were expensive and complicated to use. In the decades since their first introduction, they have become steadily cheaper and more accessible, until the BBC micro:bit became possible: a minimal-cost, highly-functional board designed to help teach programming, or ‘coding’, to anyone regardless of experience.
Your programming journey begins simply: learning about the BBC micro:bit itself.
WARNING
The BBC micro:bit is designed to be robust, but it’s still a complex electronic device. It’s designed as a bare circuit board so that you can see what all its components are and what they do, but this does mean you need to take a little more care with handling it than if it were in an enclosure. Always make sure to handle it by its edges to avoid damage through electrostatic discharge. For more information on preventing electrostatic discharge damage, see Chapter 2, ‘Getting Started with the BBC micro:bit’.
The BBC micro:bit itself is a small printed circuit board with a range of components fitted. It has two sides: the front side of the BBC micro:bit includes the display and buttons, while the back side has components like the micro-USB connector and radio. Figure 1-1 shows the front side of the BBC micro:bit, and Figure 1-2 shows the back.
image
FIGURE 1-1: The front of the BBC micro:bit
image
FIGURE 1-2: The back of the BBC micro:bit
The BBC micro:bit includes a layer of print known as a silkscreen layer, which labels some of the more important components. The buttons on the front side are labelled A and B so you know which is which, while the back side picks out key components like the processor and the accelerometer. These components, and others, are described in more detail in the next section.

Breaking It Down

Like any complex device, the BBC micro:bit is made up of numerous relatively simple parts. From the more obvious, like the display which dominates the front of the board, to the more subtle, like the radio which allows two or more BBC micro:bits to communicate with each other or connect to a smartphone or tablet, each component works with the others to give the BBC micro:bit its impressive flexibility.
If you’re impatient to get started with your BBC micro:bit, you can skip ahead to Chapter 2. Reading the rest of this chapter, though, will give you a good understanding of just what the BBC micro:bit can do, putting you in good stead for not only learning how it works but coming up with practical projects of your own as your skills progress.

Display

The most obvious feature of the BBC micro:bit is its display, which sits in the centre of the board’s front side (see Figure 1-3). This is the BBC micro:bit’s primary output device, a means for a program running on the BBC micro:bit to communicate with the outside world—whether that’s reading off the position of one of the BBC micro:bit’s sensors or simply displaying a smiling face.
image
FIGURE 1-3: The BBC micro:bit’s display
The BBC micro:bit’s display serves the same purpose as the monitor on a desktop computer but is of a considerably lower resolution. Where a desktop monitor may be made up of 1,920 columns of 1,080 picture elements or pixels, the BBC micro:bit has just five columns of five picture elements for a total of 25 pixels.
Although 25 pixels may not sound like much, it’s more than enough to view useful information such as a bar graph or the elements of a simple game or to scroll messages of almost any length. You’ll learn more about using the display for these tasks and more later in the book.
From a technical perspective, the BBC micro:bit’s display is made up of a 5 × 5 light emitting diode (LED) matrix. Each LED in the matrix makes up one pixel and can display a single colour in varying brightnesses. By altering the brightness and rapidly changing the image being shown, the BBC micro:bit’s display can show animation as well as still images.

Buttons

Next to the display, the buttons are the BBC micro:bit’s second most obvious feature. The two main buttons, Button A and Button B, are positioned either side of the display at the front of the board and are labelled with their letter to avoid any confusion (see Figure 1-4). These two buttons form the BBC micro:bit’s primary input devices. Where the display allows information to be output from a program running on the BBC micro:bit, the buttons allow you to send simple inputs into the program to change the image being displayed, for example, or control a character in a game.
image
FIGURE 1-4: The BBC micro:bit’s Button A and Button B
These buttons are technically known as a momentary switch. These are different to the switches you might use to turn on a light, which are known as latching switches or toggle switches. A momentary switch stays ‘on’ only as long as you continue to push it down, while a latching switch goes from ‘off’ to ‘on’ and stays there until you push it again.
Although the buttons are permanently connected to the BBC micro:bit, they won’t do anything unless the program running on the BBC micro:bit is listening for a button input. Depending on what you’re using the BBC micro:bit for, you may want to use only one or even neither of the two buttons; alternatively, you may find you need more buttons, in which case the input-output pins will help you expand the BBC micro:bit.
In addition to Button A and Button B, there’s a third button on the back of the BBC micro:bit: the Reset button. Like the Reset button of a desktop computer, the BBC micro:bit’s Reset button acts like cutting the...

Table of contents

  1. Cover
  2. Title Page
  3. Table of Contents
  4. Foreword
  5. Introduction
  6. Part I: An Introduction to the BBC micro:bit
  7. Part II: Coding for the BBC micro:bit
  8. Part III: Advanced BBC micro:bit Projects
  9. Part IV: Appendices
  10. End User License Agreement