How to build Microban: the whole process
137 steps to build Microban, from buying parts, printing and assembly to software, calibration and training, with the bill of materials, shop links and the official sour…
Microban is a roughly 30 cm tall, fully 3D-printable open-source humanoid robot for robotics learning, experimentation, and research. The repository provides STL and STEP parts, a detailed bill of materials, printing guidance, and step-by-step assembly instructions.
Bill of materials · Robot Components
| Part | Qty | EU |
|---|---|---|
| Battery Holder | 1 | USD 5 |
| BMS | 1 | USD 10 |
| Switch | 1 | USD 5 |
| Charger | 1 | USD 10 |
| Batteries | 2 | USD 4 |
| Raspberry Pi Zero 2W | 1 | USD 15 |
| RPI Robot Hat | 1 | USD 30 |
| 16GB+ micro SD card | 1 | USD 10 |
| Dynamixel XL330-M288-T | 19 | USD 23.9 |
| M2x6 STP39 Screws | 10 | USD 3 |
| Filament material | <1 | USD 10 |
| 20x30x1mm POM shims | 4 | USD 2.5 |
| 25x30x0.3mm Steel shims | 8 | USD 1.75 |
| M2.5x6 Screws | 18 | USD 3 |
Bill of materials · 🛠️ Components Overview
| Part | Qty |
|---|---|
| 3D Printed Parts | ~30 |
| Servo Motors | 19 |
| Microcontroller | 1 |
| Board Hat | 1 |
| Power Supply | 2 |
| Battery Holder | 1 |
| USB-C Charger | 1 |
| BMS | 1 |
| Plastic Screws | ~200 |
| Steel & POM Shims | 12 |
Buy parts
- Check the R33 resistor stock
During the PCB preview step, confirm that JLCPCB has the default R33 resistor in stock. If unavailable, substitute another 150R 0402 resistor, such as RT0402BRD07150RL or RCA02150RJLF.
- Buy the two-cell battery holder
Buy one battery holder for two 18650 cells; the listed price is approximately $5.00. The document provides an Amazon purchase link.
- Buy the battery management system
Buy one battery management system for two 18650 batteries; the listed price is approximately $10.00. The document provides an Amazon purchase link.
- Buy the robot power switch
Buy one power switch for the robot; the listed price is approximately $5.00. The document provides an Amazon purchase link.
- Buy the USB-C charger
Buy one standard USB-C charger; the listed price is approximately $10.00. The document provides an Amazon purchase link.
- Buy two 18650 batteries
Buy two 3.7V 18650 lithium-ion batteries at approximately $4.00 each. Murata VTC6 batteries are recommended but not mandatory; the document provides an Nkon purchase link.
- Buy steel shims
Buy 8 steel shims measuring 25×30×0.3 mm; they support the POM shim.
- Buy motor mounting screws
Buy 18 M2.5×6 screws to attach the idle horns to the motors; any standard equivalent will work.
- Check motor-kit screw count
Nineteen motor kits contain 114 M2×6 screws, while assembly requires 124. Buying more than 19 motors provides enough screws.
- Buy extra assembly screws
If buying exactly 19 motors, obtain 10 additional M2×6 screws; buying some extra is recommended to avoid assembly issues.
- Buy M2.2×8 motor-fixation screws
M2.2×8 screws are recommended for motor fixation. The M2×8 screws supplied with the motors may not fit perfectly, although they are usable.
- Prepare Dynamixel configuration tools
In addition to the robot components, obtain configuration tools for setting up the Dynamixel motors.
- Plan U2D2 purchases
When building several robots, multiple U2D2 sets are unnecessary because they are only required for the motors’ initial configuration.
- Replace M2x8 Screws
Use M2.2x8 screws instead of the supplied M2x8 screws.
- Prepare Assembly Screws
Prepare 124 M2x6 self-tapping screws for the horns and 66 M2x8 or M2.2x8 self-tapping screws for the motors. Keep extra screws in case any are lost.
- Check and Add Motor Cables
The motor-supplied cables should be sufficient, but replacements may be needed if they are damaged. Adjust cable lengths to the minimum required to prevent entanglement.
- Choose or Crimp Custom Cables
Alternatively, use 50 mm (6), 100 mm (4), and 180 mm (9) off-the-shelf cables. Because these may be unavailable, it is preferable to crimp cables with SEH-001T-P0.6 crimp pins and shorten the 180 mm cables as needed.
- Prepare Spare Batteries and Charger
If Microban will be used intensively, consider additional batteries and a charger to avoid downtime while charging.
- Review the complete bill of materials
Open `docs/bom.md` and obtain the robot components using the listed quantities, purchase links, and prices.
- Source the Hardware
Gather the components listed in the BOM; the document provides purchase links, and preferred suppliers may also be used. Dynamixel motors may vary by location and affect the total cost.
- Buy the required components
Buy the necessary components following the BOM as a prerequisite for assembly.
Print and make
- Obtain the STL files
Obtain the parts from the repository's `cad/stl/` directory and print them using PLA filament, 0.12mm layer height, and 15% infill.
- Print two feet
Print 2 copies of `foot.stl` using PLA filament, 0.12mm layer height, and 15% infill.
- Print the left tibia
Print 1 copy of `tibia_left.stl` using PLA filament, 0.12mm layer height, and 15% infill; it is asymmetric to ensure proper cable routing.
- Print the right tibia
Print 1 copy of `tibia_right.stl` using PLA filament, 0.12mm layer height, and 15% infill; it is asymmetric to ensure proper cable routing.
- Print the left femur
Print 1 copy of `femur_left.stl` using PLA filament, 0.12mm layer height, and 15% infill; it is asymmetric to ensure proper cable routing.
- Print the right femur
Print 1 copy of `femur_right.stl` using PLA filament, 0.12mm layer height, and 15% infill; it is asymmetric to ensure proper cable routing.
- Print two hips
Print 2 copies of `hip.stl` using PLA filament, 0.12mm layer height, and 15% infill.
- Print ankle double motor blocks
Print 2 copies of `ankle_dbl_block.stl` using PLA filament, 0.12mm layer height, and 15% infill for the ankle joint.
- Print left hip motor block
Print 1 copy of `hip_dbl_block_left.stl` using PLA filament, 0.12mm layer height, and 15% infill; it is asymmetric to ensure proper cable routing.
- Print right hip motor block
Print 1 copy of `hip_dbl_block_right.stl` using PLA filament, 0.12mm layer height, and 15% infill; it is asymmetric to ensure proper cable routing.
- Print four cable spacers
Print 4 copies of `spacer.stl` using PLA filament, 0.12mm layer height, and 15% infill for cable clearance around ankle and hip double-motor blocks.
- Print the pelvis
Print 1 copy of `pelvis.stl` using PLA filament, 0.12mm layer height, and 15% infill; it is the lower part of the torso.
- Print bearing-support parts
Print hip.stl, pelvis.stl, arm_bearing_support.stl, and shoulder.stl in the recommended orientations so the POM washers and steel shims fit correctly and have the intended surface finish.
- Print motor-alignment parts
Print idle_horn.stl, idle_cap.stl, and radius.stl in the recommended orientations to ensure proper fit and alignment with the motors.
- Print the remaining parts
Print all other parts in their straightforward orientations; many of them do not require support material.
- Manufacture the RPI Robot Hat PCB
Manufacture the RPI Robot Hat PCB from the freely available design files through a PCB fabrication service. JLCPCB, PCBWay, and Aisler are given as possible fabricators.
- Print the Robot Parts
After all components are ready, print the parts by following the detailed Printing Guide.
- Download and print all parts
Obtain all printable parts from the repository's `cad/` directory in STL and STEP formats; PLA is the recommended material.
- Print All Parts
Go to the cad/stl/ folder and print all parts with a 3D printer. PLA, a 0.12mm layer height, and 15% infill are recommended; some parts require specific orientations, as detailed in the Printing Guide.
- Print the robot parts
Print the parts following the Printing Guide as a prerequisite for assembly.
Assemble
- Insert Terminals Into Housing
Insert the three crimped terminals into the plastic housing in their corresponding positions. The wire order is important.
- Assemble and Mount Robot Legs
Use the Onshape assembly link in the document to see how the parts fit together. Fix the assembled legs to the pelvis.
- Route Cables Before Motor Installation
Route the cables before sliding the motors into the double-motor block because the motors are very close to each other. Do not forget the spacer.
- Connect Motor-Bus Cables
Before sliding the motors into the double-motor block, plug in the cable connected to the bus between the two motors. Also route the cable relaying the two motors and the cable connecting the double-motor block to the next motor in the chain.
- Slide Motors Into Block
After routing the cables, slide the motors into the double-motor block. The images show this assembly process on a right ankle double-motor block.
- Route cables through leg sockets
Use the cable lengths given in the “Cable Setup” section and route the cables through the sockets on the tibia, femur, and hip double-motor blocks.
- Increase foot adhesion
Add an optional rubber layer to the bottoms of the feet using a rubber sheet or a piece cut from an old cycling tire.
- Mount torso and connect splitter cables
After assembling the torso, fix it to the pelvis and connect the splitter cables to the hip yaw motors, shoulder pitch motors, and RPI Robot Hat.
- Assemble battery module and trunk top
Assemble the robot electronics, including the battery module with a 2S 18650 battery holder and BMS board, and the trunk top.
- Connect battery module with XT30
Connect the battery module to the trunk top with an XT30 connector.
- Install charger and Raspberry Pi switch
The trunk top contains a USB-C charger and the switch that powers on the Raspberry Pi. The routing allows the battery to charge independently of the robot's power state.
- Power the Raspberry Pi
Power the Raspberry Pi through one of the two JST EHR-4 connectors on the RPI Robot Hat.
- Connect the BMS and battery holder
Connect the BMS 4.2V pin to the metal contact on the battery holder. This contact is on the side opposite the red (8.4V) and black (0V) wires; you can melt a small hole in the holder to make soldering easier.
- Solder BMS wires to XT30
Solder the positive (+) and negative (-) wires from the BMS to the XT30 connector.
- Secure the BMS
After wiring is complete, secure the BMS to the back of the battery holder with double-sided tape.
- Insulate battery module connections
Apply hot glue to all connections to insulate them and prevent short circuits.
- Insert the switch
First, insert the switch into the trunk top.
- Fold switch pins down
Using pliers, carefully fold the switch pins down to free up vertical space.
- Prepare the JST power cable
Cut a Dynamixel cable to approximately 150mm and remove the two unused wires. Refer to the picture to see which wires to keep.
- Wire the switch power
Solder the charger's BAT pin to one switch terminal and the VIN wire of the JST EHR-4 cable to the other terminal.
- Complete the GND connection
Solder the GND wire of the JST EHR-4 cable directly to the GND pin of the USB-C charger to complete the circuit.
- Solder before mounting the charger
The trunk top is printed in PLA, which is sensitive to heat, so solder the USB-C charger module before mounting it to the plastic part.
- Insulate trunk top connections
After wiring is complete, isolate the connections with hot glue to prevent short circuits.
- Complete the final robot assembly
Slide the battery module into the trunk, connect its XT30 connector to the trunk top, connect the JST EHR-4 cable to the RPI Robot Hat, and close the trunk with the trunk top.
- Explore the interactive assembly
Open the document's Onshape assembly to explore how the parts fit together and use it as a reference for assembly and component identification.
- Assemble the Robot
Put the mechanics together by following the step-by-step Assembly Guide.
- Assemble the robot using the guide
After printing all the parts and obtaining the necessary components listed in the BOM, assemble the robot by following the Assembly Guide.
Software
- Download the Raspberry Pi Imager
Download Raspberry Pi Imager from the Raspberry Pi website.
- Insert the SD card into your computer
Insert the SD card into the computer that will run Raspberry Pi Imager.
- Run the Imager with sudo
Run the downloaded AppImage file in a terminal using sudo.
- Select Raspberry Pi Zero 2 W
Select Raspberry Pi Zero 2 W as the device.
- Select Raspberry Pi OS
Select Raspberry Pi OS (other) in the operating-system choices.
- Select the 64-bit Lite OS
Choose Raspberry Pi OS Lite (64-bit) as the system to install.
- Select the SD card
Select the inserted SD card as the storage device.
- Name the image microban
Set the device or hostname to “microban”.
- Set the timezone
Select your local timezone.
- Set a username and password
Create a username and password for signing in to the Raspberry Pi.
- Configure the 2.4 GHz Wi-Fi
Enter the SSID and password for the local 2.4 GHz network.
- Enable password authentication for SSH
Enable SSH and allow authentication with a password.
- Write the OS to the SD card
Choose Write to write Raspberry Pi OS to the SD card.
- Put the SD card in the robot
After writing finishes, eject the SD card, insert it in the robot, and wait for the robot to boot and connect to Wi-Fi.
- Wait for the first boot
The first boot expands the filesystem and installs updates, so it takes time; keep the robot powered on and do not switch it off.
- Use the same network
Put the computer and Raspberry Pi on the same network so you can access the Pi from the computer.
- Find the Raspberry Pi IP address
Run a ping command to find the Raspberry Pi’s IP address using microban.local.
- Confirm the ping response
Confirm that the response shows the Raspberry Pi’s IP address and note that address.
- Configure the SSH hostname
Add a microban entry to ~/.ssh/config, set HostName to the Pi’s IP address, and set User to the username created in the Imager.
- Connect to the Pi with SSH
Connect to the Raspberry Pi using the configured microban hostname.
- Generate an SSH key
If you do not already have an SSH key, generate one using the ed25519 type.
- Copy the SSH key to the Pi
Use ssh-copy-id to copy your SSH key to the microban host.
- Verify passwordless SSH access
Connect to the Raspberry Pi again to verify that it no longer asks for a password.
- Copy Configuration to the Pi
From your computer, run scp to copy docs/dev/config.txt as microban:config.txt.
- Move Configuration Into Place
On the Pi, run sudo mv to move config.txt to /boot/firmware/config.txt.
- Reboot the Pi
Run sudo reboot so the configuration changes take effect.
- Configure I2C and Serial Port
After rebooting, connect with ssh microban and run sudo raspi-config. Under Interface Options, enable I2C, then disable Serial Console and enable Serial Port.
- Disable Wi-Fi Power Saving
Run sudo nmcli con mod and set wifi.powersave to disable for the Wi-Fi connection to prevent SSH hangs while the Pi is idle.
- Disable Automatic Updates
Create /etc/apt/apt.conf.d/99disable-auto-upgrades and set APT periodic updates, upgradeable package downloads, automatic cleaning, and unattended upgrades to 0.
- Reboot the Pi Again
Run sudo reboot to reboot the Pi.
- Set the Pi Date
On the Pi, run sudo date -s to set the date and time to 2026-06-27 12:21:00.
- Install uv
Run curl -LsSf https://astral.sh/uv/install.sh | sh to install the uv Python package manager on the Pi.
- Enable SSH Host-Key Regeneration
On the Pi, create regen-ssh-host-keys.service so it runs /usr/bin/ssh-keygen -A when /etc/ssh/ssh_host_ed25519_key is absent, and enable the service.
- Connect to the Robot Pi
Connect to the robot’s Raspberry Pi using `ssh microban`.
- Create the Reapply Script
Create `/usr/local/bin/microban-netcfg-reapply` on the Pi. The script re-applies `/boot/firmware/network-config` by resetting cloud-init when the configuration changes.
- Set Configuration and Stamp Paths
Set the configuration file to `/boot/firmware/network-config` and the checksum stamp to `/var/lib/microban/netcfg.sha256`. Exit if the configuration file is missing and create the stamp directory.
- Calculate and Read Checksums
Calculate the SHA-256 checksum of the current network configuration. Read the saved previous checksum and enter the first-run handling when no previous value exists.
- Record the First-Run Checksum
On the first run, cloud-init has already applied the configuration during this boot. Record the new checksum and exit.
- Detect and Apply Changed Configuration
When the new checksum differs from the old one, record it and clean the cloud-init logs. Then reboot so cloud-init applies the new network configuration on the next boot.
- Finish and Enable the Script
Finish the script with the reboot action for a changed configuration. Close the heredoc and set the script permissions to 755.
Calibrate and test
- Label the motor IDs
Write each motor's corresponding ID from the table directly on the motor to avoid confusion during configuration and assembly.
- Connect a motor with U2D2
Connect one motor at a time to the PC using the U2D2 kit.
- Recover a used XL330
If the XL330 motor is not new, click "Recovery", select the XL-330-288 model, and follow the instructions to perform a factory reset.
- Set the communication options
In the "Option" tab, select "Protocol 2.0", set the baud rate to "57600 bps", and verify that the correct COM port is selected.
- Scan for the motor
Click the "Scan" button to detect the motor.
- Set and save motor parameters
After detecting the motor, set ID to the table value, Baud Rate to 3 (1Mbps), Return Delay Time to 0, PWM Slope to 255, and Shutdown to 52, then click "Save".
- Disconnect and configure the next
After setting the parameters, disconnect the motor and continue with the next one.
- Connect all motors for checking
After their IDs have been set, connect all the motors together for a final check.
- Change the scan rate to 1Mbps
For the final check, change the scan baud rate to 1Mbps because the motors were changed to that rate during configuration.
Data and training
- Train Your Own Walk or RL Skill
Use the training pipeline in the MarcDcls/mjlab_microban repository to train your own walking or other learned skills.
Use it
- Shut Down Safely Before Powering Off
Run `make shutdown` before cutting power to the robot. Wait 10–15 seconds for the Raspberry Pi to halt; powering it off without a clean shutdown can corrupt the SD card.
- Run Commands From the Repository Root
Run the Makefile commands from the repository root on your computer. The default target host is `microban`; add `HOST=microban-ext` to operate over the secondary network.
- Place the Robot Securely
Place the robot on a stable surface, or hold it securely. On start, it enables torque and ramps to its neutral pose.
- Start the Robot Control Loop
Run `make run`. The control loop starts at 50 Hz and stays attached to the terminal; some latency is expected because of the SSH connection.
- Toggle Moves and Drive
Toggle moves and drive the robot. Use the keyboard or a Bluetooth gamepad to control it.
- Stop or Power Off the Robot
Use `make stop` or press `q` to stop the robot. Use `make shutdown` to power it off.
- Control with the Keyboard
Use the keyboard to control the robot.
- Control with a Bluetooth Gamepad
A Bluetooth Xbox controller can be used instead of the keyboard. It supports SSH mode with a terminal and a fully headless mode with no SSH or terminal; headless mode is useful for demonstrations without a connected computer.
- Activate the walking policy
Toggle walking with `v` or gamepad **A**; once active, velocity commands drive forward/back motion, lateral motion, and turning.
- Toggle head oscillation
Press `h` to toggle head oscillation; the move runs independently on top of the neutral pose.
- Toggle the squat move
Press `s` to toggle a squat motion computed with inverse kinematics; it runs independently on top of the neutral pose.
- Control normalized velocity commands
Set `vx`, `vy`, and `vtheta` with the arrow keys or gamepad sticks. Each axis is normalized to `[-1, 1]`, then the scheduler maps it to physical limits with `scale_velocity()`.
- Run and Control the Robot
Consult the Usage Guide to run the robot, control it with a keyboard or gamepad, and learn how to add your own moves.