Skip to main content

Case 01 - Run in A Square Routine

Purpose

Hello, in this class we are about to learn to program and control XGO, we will make XGO do more interesting things and make it our best friend. In this lesson, we programmed XGO to move forward quickly. Of course, if you want XGO to turn and adjust the code, let's start.

Quick to Start

Materials

micro:bit XGO Robot Kit × 1

micro:bit × 1

Hardware Connections


Connect the micro:bit with the computer. Believe you are already very skilled.

MakeCode programming


Step 1

Click Advanced in MakeCode to see more options.

For programming, we need to add a package: click "Extensions" at the bottom of the MakeCode drawer, search for "XGO" in the dialog to download.

Note: If you encounter a prompt that some codebases will be removed due to incompatibility, you can follow the prompt to continue or create a new project in the menu.

Step 2

sample program

LinkRun in A Square Routine

You can also download it directly below:

FAQ

If XGO doesn't run a perfect square, please try adjusting the time and speed.

Exploration

How to program it to run in circles?