Skip to content

Mission Zero Mentor Guide

Mission Zero Mentor Guide

Welcome to the European Astro Pi Challenge 2024/25: Mission Zero. Mission Zero offers young people the amazing opportunity to write a computer program that will run on Astro Pi computers on board the International Space Station (ISS) and display a colourful image or animation to the astronauts.

This guide for mentors provides information and tips to help you support your teams to take part.

First, we’d like to give a big shout-out to everyone who runs Mission Zero with young people. Thank you for sharing your time, knowledge, and enthusiasm to support the next generation of tech creators.

Before you start, please check the eligibility criteria.

No prior experience required

You do not need any previous experience of the Astro Pi Challenge to take part in Mission Zero. We provide a number of helpful resources to support you and your team during the Mission.

You will find out more about the other resources available to help you and your team later in this guide.

Astro Pi Mission Zero overview

The goal of Mission Zero is to create a program that can run for 30 seconds on the ISS, and in that time, collect data from the Astro Pi computer’s light sensor and use it to customise the colour choices of an image or animation, which will be displayed on the Astro Pi’s LED matrix.

The activity can be completed individually or by teams of up to 4 young people working together. Once your teams have written and tested their programs, they will submit it for checking by specialists from the Raspberry Pi Foundation and the European Space Agency. All programs that follow the Mission Zero rules will then be awarded ‘flight status’, which will allow them to be run in space. 

Mission resources and preparation

In addition to this mentor’s guide, we provide a number of resources for Mission Zero for you and your teams.

The Mission Zero Guidelines contain all the requirements and technical instructions to support young people to create a Python program that can be awarded flight status (be run on the ISS). Think of it as the specification that the program must meet in order to be considered for running on the ISS.  

The Mission Zero Step-by-step guide takes you through how to create a space-ready program, but if you have any questions, please get in touch with Astro Pi Mission Control by emailing us at [email protected]. Don’t hesitate to contact us — we would love to hear from you.

To help you introduce the Astro Pi Challenge and Mission Zero, you could use this slide deck. It has a link to a view of the ISS on Google Street View, which your team can explore to try to find the Astro Pi computers on board. The slide also shows and has a link to this interactive PDF collage of some of the pixel art created for the 2022/23 challenge.

To complete Mission Zero, teams will need:

  • A computer with an internet connection

  • An up-to-date web browser

Participation in Mission Zero requires around 1 to 2 hours of contact/project time.  

Your teams will write their programs using our online code editor, which also provides an emulated view of an Astro Pi computer so that they can get an idea of how their art will look on the ISS.

Exactly what does the program need to do?

There are 4 requirements that a Mission Zero program has to meet. These are helpfully displayed at the bottom of the online code editor. 

A green tick will appear next to each requirement once it has been met. Programs that run for more than 30s due to a slow device or poor internet connection will get an error prompt rather than a check box. You can still submit your team’s program if it overruns for these reasons. 

A pixel art image of a Fox

The really fun part of the activity is designing the images that will be displayed on the 8x8 LED matrix. You should encourage your teams to leave plenty of time for this part of the challenge.

By looping through multiple images with small changes between them, it is easy to create a really fun animation. Many entries from last year started with the example pictures provided in the step-by-step guide and then animated them, like the snapping crocodile, pecking chicken, and slithering snake at the start of this guide. 

Or if they’re feeling really creative, your team can design a new character and animate its actions.

To help your teams with their designs, you could print out some grids for them to fill in with coloured pencils, or use one of the many online pixel art tools, like the one at pixilart.com (make sure they select an 8x8 grid). Creating new colours can also really enliven a project. There are plenty of online colour-mixing tools like this that can be used to craft a particularly vivid shade of whatever. 

You can encourage your teams to be as creative as they like, but remind them that there are a few restrictions on the type of content that is acceptable for display on the ISS. Images and animations must not contain:

  • Anything that could be interpreted as being of an illegal, political, or sensitive nature

  • Flags, as unfortunately they can be considered politically sensitive in some contexts

  • Anything that references or suggests unpleasantness or harm to another person

  • Personal data such as telephone numbers, social media handles, and email addresses

  • Obscene images

  • Bad language or swearing

All the submissions are checked thoroughly, and sneaky ways of trying to get something past the testing team will not be successful. For example, spelling out an unsuitable message one character at a time. It is a good idea to make sure every young person taking part is aware of these restrictions. Every year we have to disappoint some entrants by not running their programs because they contain flags.

How to register as a Mission Zero mentor

You can register as a Mission Zero mentor via the Astro Pi website. Click on the Mission Zero link at the top of the page. Then scroll down and click on the registration link.

This is a simple process that just involves setting up a Raspberry Pi account. If you already have one of these, things are even easier, and you can just log in.

If you don’t have a Raspberry Pi account, click on the link to create one and provide the usual details. You’ll be emailed a verification code as part of the sign-up process. 

Once signed in, you’ll be asked to agree to some privacy policies before continuing. Then select Mission Zero.

You’ll be asked a few more simple questions, including about where you intend to run Mission Zero. This might be a school, club, Scout group, somewhere else, or maybe all of these. If you are going to be entering teams from different places (e.g. a CoderDojo and a Scout group), just tell us about the one from where you think most of your entries will come. 

After that, you’ll see a screen like this, with your classroom code displayed. This is the only thing your teams will need to submit their programs, and it will automatically link them to your account.

There is no limit to the number of teams who can submit entries using your classroom code. Check that your teams meet the eligibility criteria here.

How to submit an entry

When your teams have a working program and the tick-boxes at the bottom of the code editor are checked, they can submit their program. Once they enter your classroom code and choose a team name, they will move on to a short form that asks for a few details. 

If there is more than one participant who has worked on this program, click on +Add team member to add their details too. The team name and first name of all the team members will appear on the unique certificates that will be sent once the programs have run on the ISS.

On the back of each certificate, there will also be a map showing the location of the ISS above the Earth at the time the program was run. 

You will receive an email for each team that enters. If you’re running Mission Zero with a big group, you can use these emails to check that all entries have been submitted correctly. You can also check this information by logging on to your Raspberry Pi account and checking the Mission Zero hub. 

MZ submission of a rainbow

Troubleshooting Mission Zero

Saving work between sessions Teams can save their programs by clicking the Save button on the Mission Zero starter project. They will need to enter a team name, each member’s name, and the classroom code you have given them. So please allow some time for this in your session.

Loading your program To load a program, your teams can simply enter the classroom code and their team name, and their saved program will appear in the Mission Zero starter project.

Why isn’t my program working? It is difficult to predict what programming errors your coders may encounter, but a few common ones are shown below. As a general rule, always check with the example code shown in the step-by-step guide and look for typos and differences in the line formatting. The step-by-step guide encourages the programmers to make small changes and additions to their code and then run the program to check everything is working. This approach makes it much easier to find an error.

Here are some examples of errors you may encounter:

NameError: name 'c' is not defined on line 16 of main.py

There is nothing wrong with any of the lines of code in this example. However, the single-letter colour variables used in the image are not defined until after the list that constitutes the image itself. Moving lines 27–30 up above the list definition that begins on line 16 will fix this problem. The key learning here is that you can’t use a variable in Python until you’ve assigned a value to it.

screen grab of c not defined mz CODE error

"My animation isn't working"

In this case, the program will run without any errors, but will appear to only display the second image in the animation sequence. This is because there is no pause between displaying the two frames. Adding a sleep(1) line between lines 45 and 46 will remedy this problem.

Screen grab of MZ starter project code error

SyntaxError: bad input on line 34 of main.py

Line 34 is indented, aligned with the list above. The tab at the start of that line should be removed. 

MZ starter code error screen grab - indentation

SyntaxError: bad input on line 33 of main.py

Apart from the line number reported, this appears identical to the previous problem. However, the cause is slightly different. In this case, the closing square bracket from the list is missing from the end of line 30. This is a common problem — sometimes the line number reported in the error message is not the culprit.

Screen grab of MZ starter project code error

NameError: name 'set_pixels' is not defined on line 33 of main.py

The problem here can be tricky to spot, especially if you’re looking over the coder’s shoulder at a small screen. It is just a single character typo: the comma between sense and set on line 33 should be a full stop.

Screen grab of MZ starter project set_pixels code error

I've finished

It is possible to create a requirement-meeting program by adding just a couple of lines to the starting code. If you have a sharp programmer who has done this, or one who has discovered the complete example and just pasted that in, encourage them to really customise their work by adding additional frames to their animation, or choosing vibrant colours.

Something went wrong and I’ve lost my program

Sometimes coders can accidentally close their tab, or the browser, or perhaps there was a problem with the computer. If this happens, it is worth reopening everything as there is a chance that a cached version might be available. If this isn’t the case, then unfortunately there isn’t anything that can be done to recover their work unless they have saved it previously. Inevitably, these kinds of issues occur towards the end of the session, when there isn’t enough time to start again from the beginning. However, section 4 of the step-by-step guide does have a completed version of a valid Mission Zero program. Unlucky teams can copy-and-paste this code to quickly get something to work from. It won’t help if they’ve spent ages working on an amazing animation, but at least they’ll be able to submit something, have it run on the ISS, and receive a certificate. 

If you have a team that is producing many lines of code, encourage them to save their work at regular intervals.

My program runs for more than 30 seconds

Even though a Mission Zero program has 29 frames with a 1 second delay between them, it can still sometimes take more than 30 seconds to execute if it is being run on an older computer. If the program is looping through the same image as shown in the step-by-step guide, then the easiest solution is to just reduce the number of loops so that it is finished in under 30 seconds. If there are 29 unique frames of a custom animation, then reduce the interval time.

The classroom code isn’t working

Check that it is being typed correctly. Classroom codes use hyphens between the two component words.  They are also case sensitive.

Mentors are issued with a new classroom code every year, which you can access from the Mission Hub. If you previously registered with a Raspberry Pi account in 2023/24, then just visit the Mission Hub to see your new code for 2024/25. 

Please register for your mentor account here if this is your first time doing Mission Zero. You will see your classroom code for 2024/25 when you have registered.