Welcome to Building:bit Superkit repository
2.5 Python Programming Guide
Python Programming Guide
Python Programming Guide1. Environment introduction and preparation2. Start programming3. Download and run
1. Environment introduction and preparation
- Go to this website to download Python programming software Mu, URL: https://codewith.mu/ If the download time is too long, you can click to download the Mu offline editing software we uploaded, MU click to download

- Next, you will jump to the software version selection interface, select your current computer system to download and install the software. Here I choose the Windows version to download according to my computer system

- After downloading, double-click to install, check the agreement, click Install and wait for the installation to complete


- After the program is installed, there will be an extra MU shortcut on the computer desktop! image-20250607150038212. Double-click this shortcut to run Mu. It is normal if there is a Microbit character in the lower right corner of Mu. If it is other content, please click [Mode] in the upper left corner to change it to BBC micro:bit.

- You can select the language in the setting icon in the lower right corner

2. Start programming
- We need to import the Python library file dedicated to Superbit. In the [Program Source Code] folder of the tutorial, we can see a python library folder. Select the corresponding .hex file according to your motherboard model. We need to send or copy this hex file to the micro:bit drive letter. Then, click the [REPL] button on the Python programming interface to import this library file. After importing, we can see the text prompt shown in the figure below on the Mu interface. The information prompted below is different for different versions of the library.

- Then we can write the program by ourselves. After writing, click the [Check] button to check whether there are any errors in our code. If a cursor or underline appears in a line, it means a syntax error. Please check and modify it. If there is no error, the lower left corner will prompt that there is no problem with the detection.

3. Download and run
We need to click the [Flash] button to download the program to the micro:bit mainboard. (You need to click the ‘REPL’ button again to turn off the import library file function before you can download the program normally).
During the download process, we can see that the orange indicator light on the back of the micro:bit motherboard will flash. When the orange indicator light stops flashing and the prompt shown in the figure below appears in the lower left corner of the Mu interface, it means that we have successfully downloaded the program to the micro:bit motherboard.
