Connecting to sources…

How to build Upkie open-source wheeled biped: the whole process

175 steps to build Upkie open-source wheeled biped, from buying parts, printing and assembly to software, calibration and training, with the bill of materials, shop link…

The creator's FOSDEM 2026 talk abstract says one can be built from off-the-shelf parts for around $3,000; a creator's estimate, the BOM page lists no prices, and whether a 3D printer, tools and shipping are counted is not stated. No official kit is sold

Bill of materials · Bill of materials {#bill-of-materials}

PartQty
3D printer · FDM 3D printer such as a Prusa i3 MK3S+ · your preference1
Battery · RYOBI 18V compatible battery · online retail [1]1
Battery spring · Battery contact spring · Digi-Key2
DC fan · DC FAN 24V 1.8W 60x60x15mm · online retail [1]1
Heat shrink · Heat shrink tubing, 3:1 ratio, standard sizes · online retail2 m
Heat shrink large · Heat shrink tubing, 2:1 ratio, 19 mm diameter · online retail1 m
Hex spacer · M2x12 + 3 male hex spacer · comes with pi3hat4
Hex wrench · 17 mm RC Hex Wrench · 3D print1
JST connector · JST PH-3 2.0 mm 3 pin connector, see cables · come with mjbots products14
Leg power cable · Female-female power cable, length 400 mm · see cables4
M2.5 inserts · M2.5x4x4 heat set inserts, M2.5, OD 4 mm, length 4 mm · online retail8
M2.5 screws · M2x8 socket head screws, M2.5, length 8 mm · online retail10
M2.5x4 screws · M2.5x4 screws, M2.5, length 4 mm · comes with pi3hat4
M2.5x6 screws · M2.5 screws, M2.5, length 6 mm · online retail4
M2.5x8 screws · M2.5x8 screws, M2.5, length 8 mm · online retail10
M3 inserts · M3x5x4 heat set inserts, M3, OD 5mm, length 4 mm · online retail100
M3x10 screws · M3x10 socket head screws, M3, length 10 mm · online retail12
M3x12 screws · M3x12 socket head screws, M3, length 12 mm · online retail22
M3x8 screws · M3x8 socket head screws, M3, length 8 mm · online retail50
Micro HDMI cable · Any micro HDMI cable that works with your monitor · online retail [1]1
MicroSD card · microSDXC card, U3, V30, A2 · online retail1
Pi3hat · mjbots pi3hat, r4.4b+ · mjbots1
Power dist · mjbots power dist, r4.3b+ · mjbots1
Qdd100 · mjbots qdd100 servo, beta 2+ · mjbots4
Raspi · Raspberry Pi 4 Model B · see raspberrypi.com1
Raspi heat sink · Aluminum Heatsink, for rpi 4b+ · online retail1
Terminator · Resistor, 120 Ω, see this note · online retail2
Torso power cable · Male-female power cable, length: 30 cm · see cables3
USB gamepad · USB gaming controller (or Bluetooth: instructions) · online retail [1]1
Wheel · RC 1:8 rubber tyre, see RC wheels · online retail2
Wheel actuator · moteus developer kit, r4.11+ · mjbots2
Wheel hex coupler · 17 mm Wheel Hex Coupler · online retail [1]2
XT-30 connector · XT30 connector, see cables · come with mjbots products20
XT-90S connector · XT90-S connector · online retail [1]1

Bill of materials · Optional components {#optional-components}

PartQty
RTC module · DS3231 Chip · online retail1

Buy parts

  • Obtain the 3D printer

    Obtain a 3D printer from the linked bill of materials.

  • Obtain the power cables

    Obtain the power cables from the linked cables page.

  • Obtain the screw drivers

    Obtain screw drivers from the linked bill of materials.

  • Select RC wheels by specification

    Choose RC wheels with a 112 mm outer diameter, 80 mm inner diameter, 17 mm wheel-drive hex, and 12 mm axle-hole diameter. The outer diameter is the software default.

  • Buy a matching hex coupler

    If you select a different wheel-drive hex or axle-hole diameter, buy a matching hex coupler.

  • Select RC wheels with matching dimensions

    The wheel has a 112 mm outer diameter, 80 mm inner diameter, 17 mm wheel-drive hex, and 12 mm axle-hole diameter.

  • Buy a matching hex coupler

    If a different wheel-drive hex or axle-hole diameter is selected, buy a matching hex coupler.

  • Order the bill-of-materials parts

    Order the parts listed in the bill of materials first because shipping will take some time.

Print and make

  • Obtain each part's 3MF file

    Use the 3MF file provided for each part in the upkie_parts repository. The files include speed, infill, layer height, and other printing configuration details.

  • Import STL files on another printer

    If using a 3D printer other than the Prusa i3 MK3S+, import the STL mesh files from upkie_parts and apply the stated printing settings.

  • Slice all parts with proper settings

    Slice every part with the proper settings. The parts are designed for PETG with a 0.2 mm layer height and 15% to 30% infill; the wheel hub includes an explicit infill modifier on the hex coupler connector.

  • Print the back covers

    Print 1× back cover from the parts sliced in the previous step.

  • Print the back plates

    Print 1× back plate from the parts sliced in the previous step.

  • Print the battery shore plug

    Print 1× battery shore plug from the parts sliced in the previous step.

  • Print the battery stud

    Print 1× battery stud from the parts sliced in the previous step.

  • Print the bottom plate

    Print 1× bottom plate from the parts sliced in the previous step.

  • Print the face plate

    Print 1× face plate from the parts sliced in the previous step.

  • Print the head plate

    Print 1× head plate from the parts sliced in the previous step.

  • Print the side plates

    Print 2× side plates from the parts sliced in the previous step.

  • Print the bottom stiffener

    Print 1× stiffener bottom from the parts sliced in the previous step.

  • Print the top stiffener

    Print 1× stiffener top from the parts sliced in the previous step.

  • Print the ankles

    Print 2× ankles from the parts sliced in the previous step.

  • Print the femurs

    Print 2× femurs from the parts sliced in the previous step.

  • Print the horns

    Print 4× horns from the parts sliced in the previous step.

  • Print the knees

    Print 2× knees from the parts sliced in the previous step.

  • Print the tibias

    Print 2× tibias from the parts sliced in the previous step.

  • Print the wheel hubs

    Print 2× wheel hubs from the parts sliced in the previous step. The wheel hub has an explicit infill modifier on the hex coupler connector.

  • Optionally print the handle

    Optionally 3D print the handle from the linked design; this can be done at any later stage.

  • Print and refine the wheel-hub fit

    Print the updated wheel hub and test it in the wheel until it has a tight fit. This usually takes a few iterations.

  • Print and mount the handle

    Optionally 3D print the handle and screw it to the head plate using four M3x8 screws; this can be done later.

  • Update and print the wheel hub

    Changing the inner diameter, wheel-drive hex, or axle-hole diameter requires a corresponding update to the 3D-printed wheel hub. The hub usually takes a few iterations to fit the wheel tightly.

Assemble

  • Mount the Raspberry Pi

    Mount the Raspberry Pi to the plate with four M2 hex spacers, with the USB ports facing the side marked “USB”.

  • Mount the pi3hat

    Mount the pi3hat on top of the Pi using the four M2 screws included with it.

  • Mount the head assembly

    Mount the head on the left and right plates with the USB side facing the robot’s right; the eyes face forward and the battery faces backward.

  • Mount the power distribution board

    Screw the power distribution board to the buttocks plate using four M2.5x6 screws.

  • Mount the battery connector

    Screw the battery connector to the face plate using six M3x8 screws.

  • Orient the battery connector

    Point the tip of the battery connector toward the robot’s left side, offsetting the connector slightly to the left of the face plate.

  • Orient by the face plate

    Use the face plate to identify the robot's left, right, front, and rear.

  • Join face and buttocks plates

    Screw the face plate to the buttocks plate with M3x8 screws.

  • Set XT90 power board side

    Ensure the XT90 side of the power distribution board is on the robot's left.

  • Attach left and right plates

    Use M3x8 screws to attach the left and right plates to the face and buttocks plates.

  • Attach head plate

    Screw the head plate to the face, left, and right plates.

  • Set head plate USB side

    Ensure the USB side of the head plate is on the robot's left.

  • Set head plate XT30 side

    Ensure the XT30 side of the head plate is on the robot's right.

  • Keep head plate correctly oriented

    This orientation fits the cable lengths, and the IMU is attached to the head plate.

  • Attach front-plate stiffeners

    Attach the two stiffeners to the front plate using M3x8 screws.

  • Leave internal covers uninstalled

    Do not install the internal covers at this stage.

  • Install internal covers

    Install the two internal covers using the ten M2.5 screws.

  • Connect battery

    Plug the battery into the connector; it should make a clear click.

  • Keep motor and bracket assembled

    For each ankle, do not remove the mj5208 or moteus from the bracket.

  • Select three external screw holes

    Use the three external screw holes in the triangle pattern, not the two internal holes opposite the center.

  • Use M3x8 screws

    Use M3x8 screws for the ankle assembly.

  • Fit PCB inside bracket

    Ensure the PCB fits inside the bracket.

  • Carve threads if needed

    If the 3D-printed plastic blocks the hole, you may need to carve the thread.

  • Clear plastic from holes

    If too much plastic remains in the hole, use a smaller screwdriver to remove the blocking plastic.

  • Cut thread with screw

    Then use the screw to carve the thread; some force may be needed.

  • Align motor and wheel hub

    If necessary, repeatedly unscrew and screw the fasteners so the motor and wheel hub have the smallest possible gap and are aligned.

  • Insert locking pin

    Insert the pin into the tiny hole to lock the motor and wheel hub together.

  • Align hexagonal coupler

    Carefully align the coupler's hexagonal shape with the hexagonal hole inside the wheel rim.

  • Seat hub inside tyre

    When aligned, it clicks and the wheel hub sits entirely inside the tyre.

  • Lock wheel hex coupler

    Use a 17 mm hex wrench to tighten the last part of the wheel hex coupler and lock the wheel to the wheel hub.

  • Prepare cable heat-shrink

    Prepare two 3–4 cm pieces of heat-shrink per cable set, place them near the cable ends a few centimeters before the connectors, and heat them. Do not heat the cable sleeve because it may melt.

  • Tape one cable end

    Apply some removable tape to one end of each cable set.

  • Attach tibia to ankle

    Screw the tibia to the ankle using the hole in the middle.

  • Form pointed cable nose

    Use removable tape to bind the connectors to the heat-shrinked section, forming a pointed nose that helps insert the cables.

  • Connect tibia to wheel motor

    Connect the tibia connectors to the wheel motor and use seven M3x12 or M3x10 screws; do not use M3x8.

  • Insert femur into T part

    Insert the femur and its cable inside the T-shaped part.

  • Connect femur to motor

    Connect the femur connectors to the motor, leaving enough slack for the motor to turn. Use the three small motor holes, not the three larger ones.

  • Attach rounded horn

    Attach the rounded horn to the other side of the motor, then screw the two parts together.

  • Connect motor cables

    Connect the data cable to the motor first, then connect the power cable.

  • Label communication cables

    Add a "JC1" label to one communications cable and a "JC3" label to the other communications cable.

Software

  • Install the Upkie Python library

    Install the `upkie` Python library from PyPI with pip.

  • Create the PyBullet pendulum environment

    Create the `Upkie-PyBullet-Pendulum` environment with a frequency of `200.0`.

  • Switch the environment to the real robot

    Replace `"PyBullet"` with `"Spine"` in the environment name to switch to the real robot.

  • Power on and log in

    Power on the system and log into the Raspberry Pi over SSH.

  • Configure each servo ID

    Run moteus_tool for each servo ID X with bus 1 configured for servos 1, 2, and 3 and bus 2 for servos 4, 5, and 6.

  • Update wheel diameter in agent configuration

    When changing the outer diameter, update the agent's configuration. Most agents are robust to centimeter-scale variations in this diameter.

  • Clone the main repository

    Clone the main `upkie` repository on your computer and enter that directory; when installing the software, everything will be run from this directory.

  • Log into Raspberry Pi

    Log into the Raspberry Pi over SSH.

  • Update wheel diameter in agent configuration

    If the outer diameter changes, update the agent's configuration. Most agents are robust to centimeter-wide variations in this diameter.

Calibrate and test

  • Prepare the testing table

    Arrange and test the electronic components on a table as depicted.

  • Check the power board LED

    If everything is correct, the red LED on the power distribution board should turn on.

  • Check both board LEDs

    If everything is correct, red LEDs should turn on on both the pi3hat and the power distribution board.

  • Connect the servo via USB

    Connect the servo being configured to your computer via USB.

  • Open the configuration tab

    Go to the configuration tab in tview.

  • Set the servo identifier

    Set id.id to the desired value; this writes a conf set command in the console.

  • Restart tview with the new ID

    Close tview and restart it with the new ID, for example with tview -t X.

  • Check the configuration list

    Check that the console contains a list of configuration parameters; an empty list indicates a communication issue.

  • Save the servo ID permanently

    Execute conf write in the console to save the new ID permanently.

  • Configure the listed actuators

    Configure the qdd100 and mj25208 actuators according to the document's six-row table.

  • Test servo communications

    Test communications with each servo using the conf enumerate command.

  • Test servo motion

    Test each servo with the d stop and d pos commands.

  • Position robot upright

    Place the robot base as vertically as possible, then wiggle both legs to make them as vertical as possible. The hips and knees have some friction.

  • Run hard rezero

    Run the rezero script to perform the hard calibration routine, which sets the absolute zero position for all actuators. For Upkie, zero means both legs are straight. Hard zeroing only needs to be performed once, not at every power-up.

  • Run soft rezero

    Afterward, use upkie_tool rezero for soft rezeroing. Soft rezeroing only requires the robot to be vaguely upright, with hip and knee joints within 60 degrees of their true zero.

  • Run the PyBullet balancing loop

    Reset the environment, calculate actions with gain `[10.0, 1.0, 0.0, 0.1]`, and loop for up to `1_000_000` steps.

  • Reset the environment when an episode ends

    Reset the environment when a step returns `terminated` or `truncated`.

Use it

  • Run the lying genuflection example

    Run the standalone example that genuflects while the robot lies on a horizontal floor.

  • Run the model predictive control example

    Run the standalone example containing a self-contained MPC balancer.

  • Run the PD balancer example

    Run the standalone example that balances using proportional-derivative feedback to wheel velocities.

Common problems

  • Bazel Python dependencies are incompatible across ARM and x86 architectures #1 #211
  • Required Python packages are missing from Bazel-launched scripts #11 #128
  • SpineInterface cannot access shared memory on macOS #375
  • Wheel balancer uses incorrect forward and backward velocity signs #74
  • Realtime sleep constraints unnecessarily slow simulation policy training #77
  • Deserializing observation dictionaries takes too long, especially when extended #180
  • Doxygen documentation and pip installation errors fail CI #438
  • Build and launch scripts rely on GNU-specific commands unsupported by macOS #152 #457

Parts

  • 4 × mjbots qdd100 actuators (beta 2 or later) for hips and knees, 16 N·m peak torque
  • 2 × moteus r4.11 developer kits driving the wheels (mj5208 motors, limited to about 111 rad/s and 1.7 N·m in software)
  • Raspberry Pi 4B with heat sink, mjbots pi3hat r4.4b+ (on-board IMU), mjbots power dist r4.3b+ board
  • RYOBI 18V-compatible battery, XT90‑S and XT30 connectors, JST PH‑3 comms cables, 2 × 120 Ω terminators, 24V 60×60×15 mm fan
  • 2 × 1:8 RC rubber tyres (112 mm outer diameter by default, 17 mm hex drive) with 17 mm hex couplers
  • PETG prints (0.2 mm layers; each part's 3MF project file carries all slicing settings), about 100 M3 heat-set inserts and M2.5/M3 screws
  • USB gamepad, microSD card, micro HDMI cable; optional DS3231 real-time clock module

Tools

  • FDM 3D printer (the creator uses a Prusa i3 MK3S+)
  • JST PH crimping pliers (PA‑09 recommended)
  • Metric hex screwdrivers for M2.5 and M3 (ball tip recommended)
  • Soldering iron for the XT connectors, wire cutters

Skills

  • Crimping JST comms cables and soldering XT power cables
  • Raspberry Pi setup and electronics testing
  • Python agents (Gymnasium API) and the C++ spine for low-level control
  • Advanced: model predictive control (ProxQP) and reinforcement learning (Stable‑Baselines3; mjlab_upkie needs an NVIDIA GPU)

Software

  • upkie Python library v13.1.0 (PyPI, conda‑forge): Gymnasium environments, C++ spines, state estimation and control
  • Examples: PD balancer, MPC balancer, lying genuflection; PyBullet simulation
  • Reinforcement learning: rl_zoo3_balancer (Codeberg, CPU) and mjlab_upkie (MuJoCo Warp, NVIDIA GPU needed)
  • upkie_description: URDF/Xacro model that loads into Pinocchio and other frameworks

Documents