Getting Started with the BrickPi


If you’re familiar with Lego Mindstorms, then you are probably aware of all the cool projects that you can make and the educational value of such an easy-to-use robotics platform. Enter the BrickPi.

getting started with the brickpi
Bare BrickPi board

The BrickPi is a RasbperryPi add-on that lets you control Lego Mindstorm parts. The BrickPi stacks on top of the Raspberry Pi and accepts Lego Mindstorms motors and sensors.

The BrickPi allows you to control Mindstorms parts using any number of languages including C, Python, and Scratch.

Covered in This Tutorial

In this tutorial, we will cover how to get started with the BrickPi. We will show you how to connect the BrickPi to a Raspberry Pi, attach Legos, connect motors/sensors, and write a simple Python script to control the motors/sensors.

Required Materials

NOTE: The servo motor and touch sensor can also be found within the Lego Mindstorms NXT set.

Suggested Reading

Configure SD Card

IMPORTANT: You need to use Dexter Industries’ custom Raspbian build to get the BrickPi to work.

Required Downloads

Flash the SD Card

  1. Insert the SD Card into your computer
  2. Install Win32DiskImager
  3. Unzip Dexter Industries’ Raspbian build (use 7-Zip if the image is in .rar form)
  4. Run Win32DiskImager with administrative privileges
  5. Select the unzipped Dexter Industries’ Raspbian build as the Image File
  6. Select the location of the SD Card
  7. Click “Write”

BrickPi Assembly

You will need to build the hardware around the BrickPi in order to connect it to the Raspberry Pi and Legos.

Build the Case

1) Unpack the BrickPi hardware and remove the protective paper from the case.

Any of the Lego Mindstorms sensors can be attached to the ports labeled with an “S” followed by a number. You will need to remember the port number that you plugged your sensor into.

schematic getting started with the brickpi
Sensor port locations (Image courtesy of

For more detail: Getting Started with the BrickPi

Scroll to Top
Scroll to Top
Read previous post:
LED Tester with LCD Display
LED Tester with LCD Display

Most projects include at least one LED. Before soldering the LED, how can you determine if the color and brightness...