Connecting Your robot to PRG AI Blocks

Resources on this page

  1. Micro:bit .hex file for Cutebot robot

  2. Scratch Website Link (https://mitmedialab.github.io/prg-extension-boilerplate/httyr/)

Part 1: Installing a .hex file on your micro:bit

1. Plug your micro:bit into your computer.

Connect the small end of the USB cable to the micro USB port on your BBC micro:bit

Connect the other end of the USB cable to a USB port on your computer.

You should see the micro:bit appear on your computer.

On computers running Windows, MICROBIT appears as a drive under Devices and drives.
On a Mac it appears as a new drive under Devices.
On a Chromebook it will appear as a new device in file manager.

2. Download the correct .hex file onto your micro:bit device.

The .hex file contains the code that allows your micro:bit to communicate with your computer.

If you happen to download the file somewhere else, then drag and drop it into your micro:bit device after.

Download the proper .hex file for your micro:bit. V1 was sold in 2020 or earlier, v2 was sold in 2021 or later.

If you're using the Yahboom Tinybit, get the .hex files from here.

While it's downloading, the yellow LED on the back of your micro:bit flashes (which should only take a few seconds).

Did I install it correctly?

After the program is written to the micro:bit, the device may Eject itself. The code will automatically run on your micro:bit. You should see a red 'S' appear on the LEDs on front of the micro:bit.

If you look inside the folder, you won't see the .hex file on your device. This is normal! The micro:bit is a little different from a flash drive.

4. Disconnect your micro:bit from your computer and plug it into your robot. See the picture on the left.

When you switch the robot on, the micro:bit will show an 'S' on its screen and the headlights will be red.

Now we can go to Scratch to connect the robot to the computer.

Part 2: Using AI Blocks to connect your robot to your computer

You can learn to connect your robot to your computer using this video or by following the instructions below.

1. Click on the link below to open PRG AI Blocks. The end of the URL should be httyr.

Make sure you are using Google Chrome!

Note: Bookmark the link so that you can find it easily next time.

2. Scroll down to the PRG Microbit Robot Blocks Category.

At first the status indicator will show an orange exclamation point ( ! ) which means the robot is not connected.

3. Click on the Connect Robot button.

Chrome will begin scanning for nearby Bluetooth devices. (Make sure your micro:bit robot is turned on!)

Select your micro:bit from the list of devices and click Pair.

Got more than one robot in the room? Need to know which is yours?

If there are multiple micro:bit devices nearby, the Bluetooth window may show several micro:bits you can pair with. How do you know which one is yours?

Every micro:bit has a unique name of 5 characters. When you first turn on your micro:bit, or if you hit the reset button on the back of the micro:bit, the name will flash across the screen. Remember this name or even write it down.

In the Bluetooth pairing window, all nearby micro:bit devices are called "BBC micro:bit [robot name]. Find your robot, select it, and click Pair.

4. After you click Pair, wait about a minute for the status indicator to change into a green checkmark.

The robot will show a 'D' and the headlights will be green.

Now your robot is ready to program!

From here on, you won't need to install another .hex file on your micro:bit. Whenever you are on the AI Blocks website you will be able to click the Connect Robot button and your computer should be able to find your robot.

To disconnect your robot, just turn it off or close the website on your computer.

You can use this programming file to get to know your robot's features.

Running into trouble?

If your robot suddenly becomes disconnected, it will flash a frowny face.

If this happens, turn the robot off, then on and reconnect it.

The distance sensor is the silver and white part that looks like a pair of eyes.

your robot is connected, but it won't drive, or the headlights don't seem to change, remove the distance sensor and try again.

If that works, then put the distance sensor back in and make sure it is in the correct set of holes.

If the site can't find your device, make sure that Bluetooth is turned on for your computer:

See more support from Google Chrome here.

Not all computers are BLE capable (this requires Bluetooth 4.0). If you get an error message about this then this robot is not compatible with your computer.