- MBot Guides
- Robot Care
- Flashing the SD Card
- Configuring your MBot
- Calibrating your MBot
For more details about the MBot, see the other guides available on this site:
- Quick Start: Get up and running with the MBot on Day 1.
- Programming your Robot: Learn how to connect to your robot in VSCode to program it.
- The MBot Bridge API: Control your robot in C++ or Python.
- Mapping & Localization: Map your robot’s environment using the web app.
- MBot Omni Debugging Tips: Something not working right? Try these steps to fix it!
The default robot username and password are:
Check with course staff to confirm the login information for your robot.
Turning the robot on
To turn the robot on, flick the switch on the power bank to ON. The red light on the Raspberry Pi should turn on.
Turning the robot off
To turn the robot off, first type
sudo shutdown now in the terminal of the robot. This will shut down the Raspberry Pi. Once the lidar stops spinning, flick the switch on the power bank to OFF.
Each robot should be marked with a unique, three-digit ID, plus a prefix (001, 002, etc.). When turned on, the robot will connect to the MWireless WiFi network. Please note that this will only work on campus.
Robot battery care
- Charging the batteries: Plug the battery into the power supply and switch the battery to ON for charging. The power adapter will have a red light while charging, and it will turn green when done. Switch the battery to OFF for storage.
- Batteries are shared across all robots. There are bins labeled “CHARGED BATTERIES” and “UNCHARGED BATTERIES.” Batteries should be placed in the appropriate bin.
- Always plug in uncharged batteries right away as they take a long time to charge.
- When a battery has three out of five green lights on, it should be replaced.
- Tip: When you aren’t using the Lidar, unplug the Micro USB cord from its board to disconnect it from the Raspberry Pi. When it spins, it draws a lot of power and drains the battery quickly.
Flashing the SD Card
To configure a new robot, you must first flash a new SD card with the robot’s image. You will need:
- A way to read and write to a Micro SD card (you can use a laptop with an SD card slot or a USB adapter),
- The latest version of the HelloRob RPi OS Image (check with your instructor to make sure they do not have a custom image for you to use).
To flash the image, follow these instructions:
- Download the image. This might take some time because the file is large. Make sure you have about 4GB available.
- Download Balena Etcher. This is a tool for flashing OS images onto SD cards.
- Flash your SD card. Launch Etcher and insert the SD card into your laptop. Select the correct device from Etcher, and navigate to the image you downloaded. Then press “Flash!”. This process can take up to 30 minutes.
If the flash is not successful, you should try again. If it continues to fail, you can try another SD card. If you are using an SD card adapter, ensure that the switch on the adapter is not in “Lock” mode, which will make the SD card read-only.
Next, proceed to the MBot configuration instructions.
Configuring your MBot
The MBot configuration, including its name, WiFi connection, and IP registry configuration, is controlled by a file called
mbot_config.txt, which can be accessed directly from its SD card. This makes it easy to update the robot’s information on first boot or if something about your configuration changes, without needing to plug a monitor, keyboard, and mouse into your robot.
If you are configuring a new robot, you must first flash a new SD card with the robot’s image.
You will need the following information:
- Your robot’s name (your course staff will tell you what your robot should be named to keep the fleet organized),
- The WiFi connection information for your classroom or home (if applicable),
- The IP registry information for your course.
Your course staff will provide this information to you. You will also need a way to read and write to a Micro SD card. You can use a laptop with an SD card slot or a USB adapter.
- Remove the SD card from your robot and plug it into your computer. You may need an SD card adapter for this, depending on your laptop.
- Warning: If a message pops up telling you that there is a problem with the drive or asking you to "fix" the SD card, ignore it!!
Open the SD card device in your file explorer. It will likely be called “bootfs”.
Open the file
mbot_config.txt. You can use any text editor for this.
Edit the file contents. The file will look something like this:
The following information is stored in the file:
mbot_hostname: The robot’s name. This will be the name that it uses to publish to the IP registry and the one that is displayed in the webapp. This name should be unique. You should also label the physical robot with this name to identify it.
mbot_ap_password: This robot’s access point password. If the robot cannot connect to WiFi, it will start an access point with the hostname as the name and this as the password, which you can connect to with your computer’s network manager.
Wifi Information. This is only for networks which can be joined with a name and password only. If you are at an institution with a special network configuration, you will have to configure the WiFi separately.
new_wifi_ssid: The name of the WiFi network you would like your robot to join.
new_wifi_password: The password for the network.
IP Registry Configuration. Your course staff will tell you which IP registry your robot should use. This is where you will check for your robot’s IP to access it when it turns on. It will publish using a GitHub account which must have write access to this registry.
mbot_ip_list_url: The URL for the IP registry on GitHub, ending with
mbot_ip_list_user: The username of the GitHub account the robot uses to publish its IP.
mbot_ip_list_token: A token the robot can use to push to the registry (this is in place of using a password, which GitHub no longer supports).
Calibrating your MBot
Each robot needs to be individually calibrated in order to control it. Once it’s calibrated, the firmware can be flashed onto the robot. You will need to flash programs onto the Pico to calibrate and load the firmware onto your robot. To do this, you should connect to the robot using a program called NoMachine, that allows you to view the robot’s desktop from your laptop. You will need:
- The calibration script,
- The MBot firmware,
- NoMachine (download from NoMachine website)
- Your robot’s IP, from your course’s MBot IP registry
- Get the Pico firmware. Note: The firmware files you need are included on the desktop of the images for the course.
- Connect to the MBot in NoMachine. You will need the robot’s IP, which you can get from the MBot IP registry from your course. To connect in NoMachine, first, add the robot as a new host with a descriptive name and the robot’s IP as “Host”:
Then, connect to the robot in NoMachine using the robot’s username and password (the default username is
mbotand the password is
- Download the MBot firmware from here. You will need the
mbot.uf2files. Downloading the tests is optional.
- Drag and drop the two files from your laptop to the robot’s desktop using NoMachine.
- Connect to the MBot in NoMachine. You will need the robot’s IP, which you can get from the MBot IP registry from your course. To connect in NoMachine, first, add the robot as a new host with a descriptive name and the robot’s IP as “Host”: Then, connect to the robot in NoMachine using the robot’s username and password (the default username is
Calibrate the MBot. We will now flash the calibration script onto the Pico to calibrate it before we flash it.
The calibration script detects the motor and encoder polarity and then calibrates the motor coefficients. The robot will move around for this step so you will need clear space on the floor (preferably on the same type of surface that you plan to use the robots on).
Do not run the calibration script with the MBot on a table!!
- First, unplug the Robotics Control Board by disconnecting the barrel plug from the battery (leave the USB that powers the RPi plugged in). Also unplug the USB that connects the Pico to the Raspberry Pi.
- We will now put the Pico in flashing mode. Hold down the
BOOTSELbutton on the Pico board (it’s near the USB port). The location of the button depends on the version of your Robotics Control Board. The button is highlighted in red for each board in this photo: With the button held down, plug the Pico’s USB cord back into the Raspberry Pi. Then release the button. The Pico should now show up as a device in NoMachine (see below).
- Plug the barrel plug that powers the Robotics Control Board back into the battery.
- Place the MBot on the floor in a spot with at least 2 feet of clear space all around the robot.
Open the Pico device folder in NoMachine. Drag and drop the script
mbot_calibrate_omni.uf2into the folder. The Pico will reboot automatically, and will then run its calibration routine. Don’t touch the robot while it does this procedure. The calibration procedure looks like this:
- Flash the MBot Firmware onto the Pico. The calibration script will have saved parameters onto the Pico’s memory. We can now flash the firmware that will run on the Pico during operation. We will be repeating the flashing procedure.
- Repeat steps 2.1-2.3 from the calibration instructions to put the Pico into flashing mode.
- Open the Pico device folder in NoMachine. Drag and drop the script
mbot.uf2into the folder. The Pico will reboot automatically.
- Test the calibration. Follow the Quick Start Guide to make sure your robot can drive around!
Something not right? If your robot doesn’t drive properly, you may have a hardware issue. See the debugging tips to check for hardware issues.