Education
Start of main content
Age Range: 11-14
Duration: 60 or more mins
  • Computing
  • D&T

Micro:bit traffic light project

Creating a pedestrian crossing system

This activity tasks students with creating a scale model and working prototype for a pedestrian crossing system for a school, using the BBC micro:bit.

Hundreds of people are killed in accidents on roads in the United Kingdom every year. When schools are situated close to roads there is particular danger to children crossing them. A good, well programmed pedestrian control system can minimise risk and enable people to cross the road safely.

This micro:bit traffic light project is an ideal activity for teaching students how to integrate a programmable system into a product design. It’s one of a set of resources developed to aid the teaching of the secondary national curriculum, particularly KS3, supporting the teaching in computing and design & technology (D&T).

Activity: Creating a pedestrian crossing system

Learners will use the BBC micro:bit to develop a prototype for a safer pedestrian crossing for a local secondary school.

To create a micro:bit traffic light, students must:

1. Understand the brief

Using the Let’s Cross Safely! presentation, students will learn about the dangers pedestrians face, especially children near schools, when crossing road. They’ll then be asked to help by making a working scale prototype for a school pedestrian crossing.

2. Follow the design criteria

The prototype must:

  • Integrate the BBC micro:bit
  • Stop traffic with a pedestrian-activated button
  • Signal to pedestrians that it's safe to cross
  • Give 30-seconds for people to cross the road
  • Include a scale model demonstrating how the system would work

3. Plan the prototype

Students will discuss in groups the value of scale models and prototypes. They’ll then evaluate the available materials (e.g., card, paper, MDF, foam board, etc) for designing the prototype.

4. Build the prototype

Students will make their prototypes, keeping in mind the design requirements and how their idea could be made commercially viable. The scale model should illustrate how the system would work.

Download our activity overview for a detailed lesson plan for teaching students on how to create a pedestrian crossing system.

Where can I find the pre-written programme for making a traffic light with the BBC micro:bit?

To create the pedestrian crossing system, students will need to integrate a pre-written program into their BBC micro:bit. The program is provided as JavaScript Blocks Editor Powered by Microsoft MakeCode (microbit-pedestrian-jsb.hex) and Python Editor (pedestrian.py) code, which can be installed by following these simple steps:

Installing JavaScript Blocks Editor

  • Visit to www.microbit.org/code and open the JavaScript Blocks Editor.
  • Drag the file microbit-pedestrian-jsb.hex onto the work area.
  • Download the program onto your BBC micro:bit.

Installing Python Editor

  • Visit www.microbit.org/code and open the Python Editor.
  • Drag the file transport.py onto the work area.
  • Download the program onto your BBC micro:bit.

How do you make a traffic light with the BBC micro:bit?

To build a traffic light with a BBC micro:bit, you'll need LEDs (red, amber, green) and have the pre-written program downloaded to your micro:bit to control the light sequence. Connect the LEDs to the micro:bit's pins (Red-Pin 0, Amber-Pin 1, Green-Pin 2). The pre-written program will mimic a pelican crossing, responding to button presses and running through the traffic light sequence with the LED display letting pedestrians know when it’s safe to cross the road.

The engineering context

Designing and prototyping are essential processes used by engineers for research and development in manufacturing and product design. Students will how learn how elements of electrical, software and systems engineering can come together to create one final product that can be used by society.

Suggested learning outcomes

This activity will teach students to integrate a programmable system into a prototype scale model. It will help students develop modelling and prototyping skills, allowing them to show creativity and the ability to avoid stereotypical responses when creating design solutions.

Download our activity sheet and other teaching resources

The activity sheet includes teachers’ notes, useful web links, and links (where appropriate) to the national curriculum in each of the four devolved nations; England, Northern Ireland, Scotland and Wales.

All activity sheets and supporting resources are free to download, and all the documents are fully editable, so you can tailor them to your students’ and your schools’ needs.

Download our classroom lesson plan and presentation below.

Please do share your highlights with us @IETeducation. 

Videos

Pedestrian crossing

Related resources