Getting Started

This page will explain to you how to upload code to both the robots and the basestations.

Installing Linux

  1. Disable bitlocker in windows
  2. Make sure secure boot is disabled in your bios when setting up a dual boot
  3. Install from usb

Video tutorial

The video below will show you the minimum amount of steps to program either a robot or basestation. Note that for programming the basestation, you do not necessarily need a separate programmer. Some of them have a programmer still attached to them. Remark When you are going to program an STM that has not been programmed before, you might not be able to do it just yet with the help of just PlatformIO. In this case you will have to download CubeProgrammer. You will have to tweak the ST-Link settings, such that it uses the hardware reset feature, instead of the software reset one. When programming the STM chip, use the generated .elf file by PlatformIO, which can be found in the .pio folder in your project root.

Software installation

Below, all required software is listed. An asterisk (*) indices that the software is required if you actually want to work on the robot or basestation. If you just want to upload code, you can ignore these.

PlatformIO can handle code compilation for many different embedded platforms such as STM32 (ours), Arduino, and more. It automatically downloads all required source files and header files for STM32 development. It comes with a debugger for embedded platforms. Lastly, it comes with a program to actually upload code to an STM32.

STM32CubeMX allows us to graphically set what each pin should do (e.g. input, output, UART, PWM) etc, instead of having to write that code ourselves. STM32CubeMX generates this code for us (specifically, main.c/.h), and we build on top of this. Please make sure to download 6.10.0.

STM32CubeProgrammer allows us to easily read out the memory of an STM32 chip and is quite useful for checking if an STM32 chip is really 100% broken.

Github repositories

The following two repositories are needed.

roboteam_microcontroller6.0. This repository holds the code for the robot.

Basestation. This repository holds the code for the basestation.


Both repositories hold a copy of REM as a submodule. When cloning either of these repositories, make sure that you do it recursively so that REM is cloned as well.

git clone --recursive git@github.com:RoboTeamTwente/roboteam_microcontroller6.0.git
git clone --recursive git@github.com:RoboTeamTwente/Basestation.git
git clone git@github.com:RoboTeamTwente/roboteam_embedded_messages.git