Build, program and make Open Duck Mini V2 walk
Open Duck Mini V2 is an open-source biped created by Antoine Pirrone and inspired by Disney's BDX droids. It is approximately 42 cm tall when its legs are extended. The stated component-cost target is under $400, before additional expenses.
It uses 14 primary servo motors, a Raspberry Pi Zero 2 W, a BNO055 inertial measurement unit and a locomotion policy trained in simulation.
This guide starts from the mechanical parts and covers 3D printing, assembly, motor IDs, wiring, sensor checks, calibration, ONNX deployment, controller pairing, supervised walking and troubleshooting. Official project procedures are distinguished from explanatory diagnostics. No physical test was carried out for this guide.




1. Understand how the robot works
The Raspberry Pi executes the controller. The inertial measurement unit reports orientation, servo motors return their state and the ONNX locomotion policy calculates joint targets. Walking depends on synchronized joint movements and balance corrections. Hardware geometry, motor ordering and the simulated model must agree.
Control architecture
The joint state feeds back into the controller at each control step.
View the complete Mermaid diagram source
flowchart TD A["Xbox controller"] --> B["Raspberry Pi Zero 2 W"] C["BNO055 IMU"] --> B D["Joint positions and velocities"] --> B E["Foot contact sensors"] --> B B --> F["ONNX walking policy"] F --> G["Servo communication bus"] G --> H["Hips, knees and ankles"] H --> D
2. All the hardware you need
The following is the core V2 bill of materials. The original spreadsheet's reference total is approximately €398.10, depending on the prices recorded by the author; it is not a current retailer quote.
| Component | Quantity | Purpose |
|---|---|---|
| Feetech STS3215 7.4 V servo | 14 | Primary joints |
| Raspberry Pi Zero 2 W | 1 | Onboard computer |
| BNO055 | 1 | Orientation and balance feedback |
| Waveshare Bus Servo Adapter (A) | 1 | Motor interface |
| 18650 Li-ion cells | 2 | Battery supply |
| 2S battery holder | 1 | Battery mounting |
| 2S BMS | 1 | Battery protection |
| 5 V UBEC | 1 | Regulated electronics supply |
| Main switch | 1 | Power isolation |
| USB-C charging board suitable for 2S | 1 | Battery recharge |
| microSD card | 1 | Linux storage |
| SS-10 contact switches | 4 | Foot contact detection |
| 9 g micro servos | 2 | Antennae |
| Bearings | 3 | Mechanical guidance |
| M3 heat-set inserts | As required | Threaded fixings |
| Screws and cables | As required | Assembly and wiring |
For fabrication, prepare an FDM 3D printer, PLA, TPU, a soldering iron, a multimeter, hex keys, screwdrivers and a heat-set insert tool. Antennae, camera, speaker and LEDs may be installed after the walking mechanism. Verify the foot contacts if the selected policy uses them.
Motor variant: the published V2 list calls for STS3215 7.4 V. Other variants can require different supply conditions.
3. Software to install
| Software | Device | Use |
|---|---|---|
| Raspberry Pi Imager | PC | Flash the microSD card |
| Raspberry Pi OS Lite 64-bit | Pi | Operating system |
| Git | PC and Pi | Retrieve code |
| Python 3 and virtual environment | Pi | Run scripts |
| Open_Duck_Mini_Runtime V2 | Pi | Servo control and walking |
| MuJoCo | PC | Physics simulation |
| Open Duck Playground | PC | Locomotion research and learning |
| PrusaSlicer, Cura or equivalent | PC | Prepare 3D prints |
| Onshape | Browser | Inspect CAD assemblies |
| Bluetooth tools | Pi | Connect the Xbox controller |
A pretrained ONNX walking policy is supplied for first experiments, so retraining from zero is not required to test the documented controller.
4. Download the files and 3D-print the robot
Step 1. Download the models
git clone --branch v2 https://github.com/apirrone/Open_Duck_Mini.git
cd Open_Duck_Mini
ls print/The print/ folder contains the STL models. Import them into your slicer.
Step 2. Configure the prints
| Parts | Material | Infill |
|---|---|---|
| Body, legs, joints and head | PLA | 15% |
foot_bottom_tpu.stl soles | TPU | 40% |
Adjust nozzle temperature, supports and clearances for your machine and filament. The published V2 print guide specifies the material and infill values above.
Step 3. Identify the mechanical parts
Simplified mechanical breakdown
View the complete Mermaid diagram source
flowchart TD A["Open Duck Mini V2"] --> B["Head"] A --> C["Trunk"] C --> D["Left hip"] C --> E["Right hip"] D --> F["Left thigh"] E --> G["Right thigh"] F --> H["Left knee and shin"] G --> I["Right knee and shin"] H --> J["Left foot with TPU sole"] I --> K["Right foot with TPU sole"]
Print the foot components in the quantities specified by the guide. It lists four pieces each of knee_to_ankle_left_sheet.stl, knee_to_ankle_right_sheet.stl and leg_spacer.stl. The trunk includes trunk_bottom.stl and trunk_top.stl; use left_roll_to_pitch.stl and right_roll_to_pitch.stl on their corresponding sides.
Before committing to a complete batch of prints, test one servo mounting interface and one M3 insert fit.
5. Configure all 14 motors before assembly
Each servo needs its own identifier. Configure one motor at a time before fitting it to the mechanism, and mark the assigned ID on the motor.
| Joint | Motor ID |
|---|---|
| Right hip yaw | 10 |
| Right hip roll | 11 |
| Right hip pitch | 12 |
| Right knee | 13 |
| Right ankle | 14 |
| Left hip yaw | 20 |
| Left hip roll | 21 |
| Left hip pitch | 22 |
| Left knee | 23 |
| Left ankle | 24 |
| Neck pitch | 30 |
| Head pitch | 31 |
| Head yaw | 32 |
| Head roll | 33 |
Install the configuration program
git clone --branch v2 https://github.com/apirrone/Open_Duck_Mini_Runtime.git
cd Open_Duck_Mini_Runtime
python3 -m venv .venv
source .venv/bin/activate
python -m pip install -e .Assign one motor ID
Connect only one servo to the bus adapter using the required supply. Never wire a 7.4 V servo directly to a Raspberry Pi GPIO pin.
cd scripts
# Example: right knee motor
python configure_motor.py --id 13The script sets the ID and moves the motor to its zero position. Keep the shaft unobstructed; this is a physical movement command.
ls /dev/ttyACM* /dev/ttyUSB* 2>/dev/null
python configure_motor.py --id 13 --port /dev/ttyACM0If your interface is on another port, use its real path. Once configured, install each servo horn according to the reference orientation of the V2 assembly guide.
6. Assemble the physical robot
Build the mechanical subassemblies in the order below. Route wires before closing parts that become difficult to reach.
Recommended assembly order
- 1 Configure 14 motors
- 2 Assemble the trunk
- 3 Build both feet
- 4 Build shins
- 5 Install thighs
- 6 Assemble hips
- 7 Attach legs to the trunk
- 8 Mount neck and head
- 9 Install boards and IMU
- 10 Wire power and sensors
- 11 Inspect before power-on
View the complete Mermaid diagram source
flowchart TD A["Configure the 14 motors"] --> B["Assemble the trunk"] B --> C["Assemble both feet"] C --> D["Build the shins"] D --> E["Install the thighs"] E --> F["Assemble the hips"] F --> G["Attach the legs to the trunk"] G --> H["Mount the neck and head"] H --> I["Install boards and IMU"] I --> J["Wire power and sensors"] J --> K["Inspect the unpowered assembly"]
A. Assemble the trunk
Start with trunk_bottom and trunk_top. Install bearings and threaded inserts. Join the parts using the M3x10 fasteners described by the author and place the central servo in the documented orientation. The guide recommends blue 243 threadlocker for appropriate metal-to-metal screw connections, not for plastic threads.
B. Build the feet
Join foot_bottom_tpu and foot_bottom_pla with the documented M3x6 screws. Install inserts into foot_top and assemble the remaining components. Confirm that the soles lie flat and the switches are activated on contact without being permanently jammed.
C. Assemble shins and knees
Install M3 inserts in leg_spacer, route the ankle servo cable before closing the shin, assemble the side plates and spacers, and fit the knee servo. Verify free movement without power.
D. Install thighs and hips
The hip_pitch horn orientation determines its mechanical zero. Use left_roll_to_pitch and right_roll_to_pitch on the correct sides. Install roll_motor_top on hip_yaw and assemble hip_roll. Attach both legs symmetrically.
E. Assemble the head
Install the neck mechanism, head_pitch_to_yaw, head_yaw_to_roll and head_roll_mount. Ensure access to the Pi, battery and optional expression modules before closing the covers. Some head assembly photos and instructions in the original documentation are still incomplete, so use the V2 CAD to verify orientation.
7. Electrical diagram and wiring
The robot has separate electrical paths for the servo supply and the regulated computer/sensor supply.
V2 power supply functional diagram
View the complete Mermaid diagram source
flowchart TD A["Two 18650 cells in series"] --> B["2S BMS"] B --> C["Main power switch"] C --> D["Servo power line"] C --> E["5 V UBEC"] D --> F["Waveshare adapter"] F --> G["14 STS3215 servos"] E --> H["Raspberry Pi Zero 2 W"] H --> I["BNO055 over I2C"] H --> J["Foot contacts over GPIO"] H --> F


Lithium battery and power warning
Two Li-ion cells in series form a nominal 7.4 V pack that can reach about 8.4 V when fully charged. Never feed this voltage into the Raspberry Pi's 5 V pins. Use a charger compatible with a 2S lithium-ion pack and the selected BMS. Check polarity and voltage with a multimeter before connecting the electronics; protect against short circuits and use cells suited to the motor current.
Connect the BNO055 to the Raspberry Pi
The official V2 documentation uses the I²C interface with these physical Raspberry Pi pins.
| BNO055 terminal | Physical Pi pin | Function |
|---|---|---|
| VIN | 1 | 3.3 V |
| GND | 9 | Ground |
| SDA | 3 | GPIO 2 / SDA |
| SCL | 5 | GPIO 3 / SCL |
BNO055 communication diagram
| From Raspberry Pi | Connection | To BNO055 |
|---|---|---|
| Physical pin 1 | 3.3 V → | VIN |
| Physical pin 9 | GND → | GND |
| Physical pin 3 | SDA ↔ | SDA |
| Physical pin 5 | SCL → | SCL |
View the complete Mermaid diagram source
flowchart LR A["Raspberry Pi Zero 2 W"] -- "Pin 1 / 3.3 V" --> B["BNO055 VIN"] A -- "Pin 9 / GND" --> C["BNO055 GND"] A -- "Pin 3 / SDA" --> D["BNO055 SDA"] A -- "Pin 5 / SCL" --> E["BNO055 SCL"]
Foot-contact sensors
| Contact signal | Physical Pi pin | GPIO |
|---|---|---|
| Left foot | 15 | 22 |
| Right foot | 13 | 27 |
| Common ground | 9 | GND |
The bill of materials lists four SS-10 switches while the published GPIO mapping identifies left and right signals. Use the original foot assembly instructions to route and combine the individual switches. When a foot touches the floor, a contact state changes; the controller can use it to identify support.
Optional expression accessories
| Accessory | GPIO |
|---|---|
| Left eye LED | 23 |
| Right eye LED | 24 |
| Projector | 25 |
| Left antenna | 12 |
| Right antenna | 13 |
LEDs and other peripherals need an appropriately rated driver or limiting circuit. Do not drive a power LED directly from a GPIO without suitable electronics.
8. Install the Raspberry Pi operating system
Two installation methods are described for V2. Choose one, rather than mixing preconfigured and manually installed runtime versions.
Method A. Use the preconfigured system image
- Obtain the V2 Raspberry Pi image from the runtime release documented by the project.
- Insert a 32 GB microSD card into your computer and open Raspberry Pi Imager.
- Select the project image as described in its installation instructions.
- Configure Wi-Fi and SSH access.
- Write the image, insert the card into the Pi and start with the robot safely secured.
The installation documentation describes the username bdxv2 and hostname bdxv2.local.
ssh bdxv2@bdxv2.localChange the image's default credentials immediately. Automatic motion services should remain stopped or paused until the motor calibration and IMU orientation are checked. A preconfigured image does not eliminate these hardware-specific steps.
Method B. Install Raspberry Pi OS Lite 64-bit manually
After flashing the operating system, connect to the Pi by SSH and install the basic dependencies:
sudo apt update
sudo apt upgrade -y
sudo apt install -y \
git \
python3-pip \
python3-venv \
i2c-toolsTurn on I²C under Interface Options in the Raspberry Pi configuration program.
sudo raspi-config
sudo rebootReconnect by SSH and inspect the I²C devices:
ls /dev/i2c*
sudo i2cdetect -y 1The BNO055 often appears at address 0x28, depending on module wiring. If it is absent, check the sensor supply, shared ground, SDA and SCL before continuing.
9. Install the main control program
On a manually prepared Raspberry Pi, use the V2 runtime repository and an isolated Python environment:
cd ~
git clone --branch v2 \
https://github.com/apirrone/Open_Duck_Mini_Runtime.git
cd Open_Duck_Mini_Runtime
python3 -m venv --system-site-packages .venv
source .venv/bin/activate
python -m pip install -e .On the preconfigured image, the runtime and dependencies are already installed. Avoid installing an unrelated second copy.
Read the IMU
python3 mini_bdx_runtime/mini_bdx_runtime/raw_imu.pyFor a networked sensor diagnostic, start the server on the Pi:
python3 scripts/imu_server.pyThen start the client from a computer that has the runtime client and required dependencies:
python3 scripts/imu_client.py --ip ROBOT_IP_ADDRESSWith the robot securely supported, tilt it gently forward, backward and sideways. Confirm that orientation changes match the coordinate convention expected by the controller.
10. Check the motors and calibrate their neutral positions
Step 1. Check motor communication
cd ~/Open_Duck_Mini_Runtime
source .venv/bin/activate
python3 scripts/check_motors.pyKeep the robot on a stand with its feet clear. Hardware diagnostics can result in motor movement.
Step 2. Copy the configuration example
cp example_config.json ~/duck_config.json
python3 -m json.tool ~/duck_config.jsonThe configuration contains pause behavior, IMU orientation, expression features and a software offset for each joint.
{
"start_paused": true,
"imu_upside_down": false,
"phase_frequency_factor_offset": 0.0,
"expression_features": {
"eyes": false,
"projector": false,
"antennas": false,
"speaker": false,
"microphone": false,
"camera": false
},
"joints_offsets": {
"left_hip_yaw": 0.0,
"left_hip_roll": 0.0,
"left_hip_pitch": 0.0,
"left_knee": 0.0,
"left_ankle": 0.0,
"neck_pitch": 0.0,
"head_pitch": 0.0,
"head_yaw": 0.0,
"head_roll": 0.0,
"right_hip_yaw": 0.0,
"right_hip_roll": 0.0,
"right_hip_pitch": 0.0,
"right_knee": 0.0,
"right_ankle": 0.0
}
}The zero values are only placeholders, not your robot's calibrated offsets. Read the real measurements and store them before walking.
Step 3. Find software offsets
cd ~/Open_Duck_Mini_Runtime/scripts
python3 find_soft_offsets.pyFollow the script's supported procedure with the body secured. Save each reported offset in ~/duck_config.json. An offset corrects the difference between the servo's measured zero and the mechanically neutral joint.
Example Python exercise: validate the JSON keys without moving the robot
Save the following as verify_config.py:
import json
from pathlib import Path
path = Path.home() / "duck_config.json"
expected = {
"right_hip_yaw",
"right_hip_roll",
"right_hip_pitch",
"right_knee",
"right_ankle",
"left_hip_yaw",
"left_hip_roll",
"left_hip_pitch",
"left_knee",
"left_ankle",
"neck_pitch",
"head_pitch",
"head_yaw",
"head_roll",
}
with path.open(encoding="utf-8") as file:
config = json.load(file)
offsets = config.get("joints_offsets", {})
missing = expected - set(offsets)
unexpected = set(offsets) - expected
if missing:
print("Missing joints:", sorted(missing))
if unexpected:
print("Unexpected joints:", sorted(unexpected))
invalid = [
name
for name in expected & set(offsets)
if type(offsets[name]) not in (int, float)
]
if invalid:
print("Invalid offset values:", sorted(invalid))
if not missing and not unexpected and not invalid:
print("Configuration structure OK")
print("Physical calibration still required")python3 verify_config.py“Configuration structure OK” means only that the required keys and value types are present. It does not certify the measurements or hardware.
11. Install and inspect the ONNX walking policy
The V2 repository contains BEST_WALK_ONNX_2.onnx. Download the mechanical project on the Pi if you have not already copied it there:
cd ~
git clone --branch v2 \
https://github.com/apirrone/Open_Duck_Mini.git
ls -lh ~/Open_Duck_Mini/BEST_WALK_ONNX_2.onnxONNX stores a trained neural network that produces commands from the robot's observations. The policy version must match the joint order, observations and runtime.
Optional read-only model inspection
With onnxruntime installed, save this Python snippet and adapt the absolute path to your own Linux username:
import onnxruntime as ort
model = (
"/home/pi/Open_Duck_Mini/"
"BEST_WALK_ONNX_2.onnx"
)
session = ort.InferenceSession(model)
print("Inputs")
for item in session.get_inputs():
print(item.name, item.shape, item.type)
print("Outputs")
for item in session.get_outputs():
print(item.name, item.shape, item.type)This only loads the network and prints its input and output tensors. It does not actuate the robot. A model may load correctly but still command unsafe movements if the observations or joint conventions are mismatched.
12. Pair an Xbox controller
On the Raspberry Pi, open the Bluetooth management tool:
bluetoothctlIn its interactive console:
power on
agent on
default-agent
scan onPut the Xbox controller in pairing mode, find its Bluetooth MAC address and replace the placeholder in the commands below:
pair XX:XX:XX:XX:XX:XX
trust XX:XX:XX:XX:XX:XX
connect XX:XX:XX:XX:XX:XX
quitCheck button and stick input before starting a walking policy:
cd ~/Open_Duck_Mini_Runtime
python3 mini_bdx_runtime/mini_bdx_runtime/xbox_controller.py13. Make Open Duck Mini stand and walk
This is where the mechanical configuration, sensors and control code must operate together. Do not proceed until every motor has its correct ID, each joint moves without mechanical interference, calibrated offsets are stored and the IMU responds in the expected direction.
Validation path before walking
If any check fails, stop and correct the motor bus, IMU orientation, calibration or model compatibility before moving to the next stage.
View the Mermaid decision diagram source
flowchart TD
A["Robot assembled"] --> B{"14 motors detected?"}
B -- No --> C["Check power, IDs, bus"]
C --> B
B -- Yes --> D{"IMU orientation correct?"}
D -- No --> E["Correct mounting and configuration"]
E --> D
D -- Yes --> F{"Offsets measured?"}
F -- No --> G["Run find_soft_offsets.py"]
G --> F
F -- Yes --> H{"Policy and runtime compatible?"}
H -- No --> I["Verify the ONNX model"]
I --> H
H -- Yes --> J["Controlled trial on a stand"]
J --> K{"Movement as expected?"}
K -- No --> L["Stop and diagnose"]
K -- Yes --> M["Supervised walking trial"]Official V2 walking command
cd ~/Open_Duck_Mini_Runtime
source .venv/bin/activate
python3 scripts/v2_rl_walk_mujoco.py \
--onnx_model_path \
~/Open_Duck_Mini/BEST_WALK_ONNX_2.onnx \
--duck_config_path \
~/duck_config.jsonReal hardware motion
The script above can move the physical robot despite the word mujoco in its filename. Use it only after assembly checks, motor calibration and securing the robot on a suitable test stand. Keep bystanders clear and an independent power cutoff in reach. Start with neutral motion input and inspect response before removing support.
Documented controller buttons
| Button | Documented action |
|---|---|
| A | Pause / resume |
| X | Projector on / off |
| B | Play sound |
| Y | Experimental head control |
| LB held | Increase walking frequency |
| Triggers | Control antennae |
The author warns against the experimental head control because it can damage the mechanism. Do not increase walking frequency until normal-speed behavior is validated. The program can be interrupted with Ctrl+C, but this is not a substitute for the hardware power cutoff during abnormal movement.
14. Understand and program locomotion
Open Duck Mini uses reinforcement learning with a MuJoCo representation of the robot. A physics model describes joint positions, masses, motor behavior and floor contact. The project also uses BAM for actuator identification.
From simulated biped to physical robot
View the complete Mermaid diagram source
flowchart TD A["Mechanical CAD model"] --> B["URDF / MJCF description"] B --> C["MuJoCo simulation"] D["Motor model"] --> C C --> E["Reinforcement learning"] E --> F["Export ONNX"] F --> G["Raspberry Pi runtime"] H["IMU and motor feedback"] --> G G --> I["Joint commands"] I --> J["Physical robot"]
If the simulation models the motors or structure incorrectly, a policy that works in simulation may fail on the real biped.
Install the training environment
On a Linux computer suitable for simulation, install uv using its official installation instructions, then obtain the playground repository:
git clone \
https://github.com/apirrone/Open_Duck_Playground.git
cd Open_Duck_Playground
ls playground/The project publishes MuJoCo environments and training runners. Its documentation describes a command of this form:
uv run playground/<robot>/runner.pyReplace <robot> with the environment directory actually present in your checkout. This sample command cannot be used literally. The chosen environment needs its documented dependencies.
Inspect training logs
uv run tensorboard --logdir=LOG_DIRECTORYTraining and transferring a new model are different tasks from deploying the supplied pretrained policy. Check a new model's tensor shapes, observations, joint order and physical limits before running it on a robot.
15. Troubleshooting and diagnostics
| Problem | What to check |
|---|---|
| Raspberry Pi does not boot | microSD image and regulated 5 V supply |
| SSH does not connect | Wi-Fi, IP address and SSH setting |
| No motor detected | Servo supply, serial adapter, motor IDs and device path |
| Several motors react incorrectly | Duplicate IDs, motor order and bus mapping |
| BNO055 not found | 3.3 V, ground, SDA, SCL and enabled I²C |
| Robot tilts in the wrong direction | IMU orientation and joint coordinate conventions |
| Knee rotates unexpectedly | Servo horn orientation and mechanical assembly |
| ONNX load fails | Policy file, Python packages and ONNX Runtime compatibility |
| Robot falls immediately | Offsets, IMU axes, motor IDs and foot contacts before another test |
| Xbox controller does not respond | Bluetooth pairing and controller input test |
| Servo motors become hot | Stop, then inspect binding, load and electrical supply |
A fall does not automatically mean that the neural policy needs retraining. Exclude mechanical and calibration errors first.
16. Commissioning checklist
Complete every item before a physical walking trial. The checklist is for planning and does not replace an independent hardware inspection.
Treat an unchecked requirement as a reason to delay the walking trial.
Original technical documentation
- Official mechanical repository and printable models
- Official V2 assembly guide
- Servo configuration guide
- Runtime and walking program
- Raspberry Pi image installation
- Simulation and reinforcement learning
Guide limitations: The official assembly material does not yet provide every photograph, screw count or a universally verified process for every hardware variation. Confirm the full electrical schematic before assembling the wiring loom. The software snippets are based on published interfaces, but successful physical execution depends on the components, runtime version and calibration of the actual machine.
Complete practical guide: Open Duck Mini
Open Duck Mini V2 uses printed legs, servo offsets and an IMU with an embedded policy runtime. Correct neutral geometry and orientation are prerequisites for learned locomotion.
1. Files, parts and fabrication
- Download the V2 mechanical files and print the rigid PLA and flexible TPU parts specified by that release. Check servo mounts and heat-set insert fit on one part.
- Assemble mirrored hip and knee mechanisms and install the specified servo horns at their reference positions. Fit the feet without obstructing joint travel.
- Mount the Pi, IMU and power electronics in the specified orientation. Keep cables from the moving legs and identify the motor assignments.
2. Software installation and configuration
- Use the V2 Open_Duck_Mini_Runtime checkout and install its Python package in the compatible Pi environment. Keep the runtime, model and ONNX checkpoint versions together.
- Use scripts/check_motors.py and the IMU diagnostic before executing a policy. Copy example_config.json to ~/duck_config.json.
- Run find_soft_offsets.py under the published supported calibration procedure and record the actual offsets and IMU orientation in the configuration.
Commissioning diagram
- 1IMU and motor feedback
- 2Configured offsets and axes
- 3ONNX policy
- 4Servo targets
- 5Biped balance
Mermaid diagram source
flowchart TD
N0["IMU and motor feedback"]
N1["Configured offsets and axes"]
N2["ONNX policy"]
N3["Servo targets"]
N4["Biped balance"]
N0 --> N1
N1 --> N2
N2 --> N3
N3 --> N43. Power-on preparation and first movement
- Support the robot with both feet clear and inspect every servo's feedback. Verify pitch and roll in the IMU diagnostic.
- Confirm neutral and soft offsets without releasing the body; compare the observed joints to the simulator.
- Validate the selected ONNX checkpoint in MuJoCo before running its V2 walking script. Use the documented supported startup and stop procedure for hardware.
4. Programming exercise
Inspect the configuration as valid JSON before deploying. This is a read-only sanity check, not policy execution.
python -m json.tool ~/duck_config.json
cd ~/Open_Duck_Mini_Runtime
python scripts/check_motors.py
# Inspect runtime help before a reviewed policy test:
python scripts/v2_rl_walk_mujoco.py --helpCheck that every configured value belongs to the actual robot. Motor discovery may require powered hardware; keep the body supported. Check the script help against the installed revision.
5. Progress to practical operation
- Test neutral pose and contact in simulation. Run the V2 policy with the matching ONNX model and verify actions, observations and balance.
- With the hardware supported, compare IMU axes and joint targets before a short supervised walking test.
- Increase speed only within the validated policy range. A policy intended for walking does not automatically support running.
6. Software and hardware diagnostics
- Motor missing
- Check power, ID, data connection and motor mapping.
- Robot leans opposite to correction
- Check the IMU frame and joint directions before changing the policy.
- ONNX model fails to load
- Match runtime version, checkpoint and observation dimensions.
Technical basis: Open Duck Mini V2 runtime and build documentation. Programming examples are identified as simulation, offline analysis or documented interface instructions. No physical commissioning test is claimed.
V2 PLA and TPU printing and biped assembly
DIY V2 biped
Commit to the V2 files, electronics and runtime together; the earlier revision is different.
From parts to first test 6 steps
Source the V2 hardware
Use the V2 documents to order the listed servos, controller, Raspberry Pi, IMU, power components, inserts and fasteners.
Reference 4 ↓Print the legs and foot pads
Download the V2 print tree. Follow the print guide's 15% PLA infill and 40% TPU foot-bottom settings; install the heat-set inserts where specified.
Reference 2 ↓Configure the motors before fitting
Follow the motor setup documents and keep each configured motor associated with its joint label.
Reference 4 ↓Assemble the biped
Follow the mirrored hip and leg orientations in the assembly guide. Connect the IMU and switches according to its controller pinout and check for cable interference.
Reference 3 ↓Install the embedded runtime
Set up Open_Duck_Mini_Runtime on the Pi for the correct revision and load the matching policy. Check IMU orientation and joint offsets with the body supported.
Reference 5 ↓First stand
Use the runtime's documented startup procedure only after verifying each motor's direction. Keep the robot secured for the initial standing test.
Reference 5 ↓
Parts, files and official manuals 5 references
V2 biped and IMU
Practical implementation notes for Open Duck Mini. Use the exact hardware and software revision specified in the project documentation.
Tools and equipment
- FDM printer
- PLA and TPU
- insert installation tool
- hex keys
- small screwdriver
- Raspberry Pi Zero 2 W
- servo adapter
- multimeter
Component illustration
- 1Hip actuator
- 2Thigh linkage
- 3Knee actuator
- 4TPU foot
Control architecture
- 01Gamepad command
- 02Policy on Pi
- 03Servo bus
- 04Legs + IMU feedback
Mechanical preparation and assembly
Print the V2 left and right legs and flexible foot pads. Seat heat-set inserts squarely, test fasteners without motors, fit the servo horns in their setup positions and check that knee and hip mechanisms move without striking the frame.
Electrical setup and calibration
Attach the IMU in the documented orientation. Label every servo and verify its ID and direction with the V2 runtime calibration procedure. Route the switch and battery leads away from the linkage. Use the V2 configuration and policy together.
Software setup and programming
The embedded runtime runs on the Pi, while training and simulation are on a separate computer. Clone the V2 runtime, follow its installation guide and use the IMU diagnostic server before running a policy. Check that tilting the robot produces the expected axes on the client. Copy the example configuration to the Pi home directory and store the measured soft offsets and IMU orientation there. The currently documented V2 policy script accepts a path to an ONNX checkpoint.
First test and acceptance criteria
A correct IMU frame and repeatable supported joint zero are required for balancing. A reversed roll axis or swapped hip motor can make a valid policy fall immediately. Verify both before releasing the support.
Programming and configuration example
Use a dedicated Python environment on the Pi. The offset utility requires the assembled robot; support it and check all motor IDs. The final walking command is intentionally commented out until commissioning is complete.
git clone -b v2 https://github.com/apirrone/Open_Duck_Mini_Runtime.git
cd Open_Duck_Mini_Runtime
python -m pip install -e .
python3 scripts/check_motors.py
cp example_config.json ~/duck_config.json
cd scripts
python find_soft_offsets.py
# Update duck_config.json with recorded offsets.
# After the IMU and supported motor checks pass:
# python v2_rl_walk_mujoco.py --onnx_model_path PATH_TO_CHECKPOINTTroubleshooting
If the robot leans incorrectly when lifted, review IMU mounting and configured orientation before changing policy parameters. If check_motors.py reports missing devices, inspect power and IDs with the body supported.
Technical reference: project release documentation. The assembly references above provide the revision-specific drawings and BOM. Examples are editorial walkthroughs or documented commands; they have not been physically tested by TechniaHQRobot.
The body is only part of the build
The v2 repository includes printable pieces and a bill of materials, with the creator stating a target below US$400 for parts. This is a project estimate and does not include a verified quote for every shipping destination, the tools or the time spent on assembly.
The public repository remains a working development space. Some experiments and scripts are not presented as finished installation instructions. A builder should identify the specific revision used in a successful build before ordering servo motors or changing link geometry.
Where reinforcement learning enters
The locomotion experiments use a physics simulator to train a policy that produces joint commands. The project also shares ONNX walking policies and instructions for running them with its MuJoCo-related scripts. Training a policy in simulation and running it on real joints are separate tasks: they depend on compatible observation definitions, joint order, controller timing and safe motion limits.
The posted videos show reported progress on transferring walking behavior to the physical robot. They do not provide a standard test of survival time, speed or success over unfamiliar floors.
What to check before the first powered step
Compare the v2 print files with the servo layout, check which orientation the controller expects for each joint, then evaluate the policy in simulation. Support the robot during the first motor-power tests. Even a plausible simulated gait can put the wrong joint into a hard stop when axis conventions differ.
Who this project suits
Open Duck Mini provides a compact way to study sim-to-real locomotion with inexpensive printed mechanics. It is a stronger fit for a builder willing to debug motion and electronics than for someone seeking a finished household droid.
Servo setup, mirrored hips and the walking runtime
Answers are based on published source material and project documentation. Their order does not represent search volume.
01What are the correct V2 3D-print settings?
The print guide specifies PLA at 15% infill for most components and 40% TPU for foot_bottom_tpu.stl. Check the actual printer and filament before assuming the same shrinkage.
Sources Official project source
02Which foot parts must I print twice?
The V2 print guide lists foot_top, foot_side, foot_bottom_pla and foot_bottom_tpu at two pieces each. It lists mirrored links and specific repeated knee sheets separately.
Sources Official project source
03Do I configure servos before or after building?
Before. The official assembly manual begins with a motor-configuration warning; otherwise the hardware may hide connectors and incorrectly centered horns.
Sources Official project source
04Is the official assembly guide complete?
Not fully. The maintainer flags missing screw counts and incomplete expression-feature instructions. Cross-check the CAD and newer build guide rather than inventing a screw number.
Sources Official project source
05Why are left and right hip links different?
The V2 model uses mirrored left_roll_to_pitch and right_roll_to_pitch parts. Match each hip side and the zero orientation in the illustrated guide.
Sources Official project source
06Can I run the walking policy by launching MuJoCo only?
No. The repository separates training/simulation from a physical runtime for the Raspberry Pi Zero 2 W. A simulated gait does not verify servo direction, foot contact or the installed policy.
Sources Official project source
Open Duck Mini: parts cost, software updates and maintenance
This practical ownership section complements the original assembly and programming instructions. Public files do not guarantee that all components can still be purchased or that every build is supported.
| Item | Project record |
|---|---|
| Cost record / BOM target | Under US$400 (creator’s v2 BOM estimate; excludes build expenses) |
| Software licence | Apache-2.0 |
| Hardware licence | Review per design file |
| Simulation availability | MuJoCo (project experiments) |
| Build difficulty | Intermediate to advanced |
How to obtain the robot or its parts
Use the Open Duck Mini documentation and hardware release to identify whether an assembled product, kit or self-sourced parts are offered. Price the matching revision, not a photograph or an old bill of materials. Include actuators, controller, supply, wiring, tools, fabrication, shipping, tax and spare parts. A historical BOM target is not a current delivered quote.
- Project documentation
- Source repository and version history
- CAD / fabrication files
- Revision-specific workshop source
How the hardware and software work together
Mechanical path: Hip actuator → Thigh linkage → Knee actuator → TPU foot.
- Gamepad command
- Policy on Pi
- Servo bus
- Legs + IMU feedback
Feedback, fault detection and the approved stop function constrain the command path.
The embedded runtime runs on the Pi, while training and simulation are on a separate computer. Clone the V2 runtime, follow its installation guide and use the IMU diagnostic server before running a policy. Check that tilting the robot produces the expected axes on the client. Copy the example configuration to the Pi home directory and store the measured soft offsets and IMU orientation there. The currently documented V2 policy script accepts a path to an ONNX checkpoint.
Install, update and recover the software
Keep the exact hardware revision, repository commit, operating system, dependencies, controller firmware and calibration in a local build manifest. Read the project’s setup instructions before installing. Use an isolated environment and a separate checkout for upgrades; compare release notes, regenerate only the documented configuration, and first repeat a simulation or read-only test. Back up calibration and original firmware files where the project supports it. Restore only a documented compatible release if the new version fails.
Project-specific verification: A correct IMU frame and repeatable supported joint zero are required for balancing. A reversed roll axis or swapped hip motor can make a valid policy fall immediately. Verify both before releasing the support.
Power, battery replacement and cycle life
Use the documented V2 power arrangement; log Pi uptime and servo supply sag separately. The parts-budget target is not a pack endurance rating.
Battery cycle life and robot service life are different. Equivalent full cycles (EFC) can be estimated as cumulative discharged energy (Wh) divided by initial usable pack energy (Wh). State of health (SOH) is measured usable capacity divided by baseline usable capacity × 100%, under comparable conditions. Example only: 1,800 Wh discharged from a 600 Wh reference pack equals 3 EFC; neither number is a specification for this robot. Ask for the manufacturer’s cycle rating, temperature limits, capacity-retention criterion and warranty. Do not use an arbitrary percentage as a replacement threshold.
Common problems, wear and service plan
| When | Inspection and evidence |
|---|---|
| Before operation | Check hip/knee servo alignment, TPU foot wear, cable slack and left/right mirrored offsets before repeating the walking test. |
| After a fault or impact | Attach the IMU in the documented orientation. Label every servo and verify its ID and direction with the V2 runtime calibration procedure. Route the switch and battery leads away from the linkage. Use the V2 configuration and policy together. |
| After software or parts change | Record versions and replaced part serials; compare the same approved test with the earlier baseline. Stop on new errors or unexpected movement. |
| At manufacturer service intervals | Use the documented interval and authorized service procedures. No universal calendar or lubricant is assumed. |
| At end of service | Ask about spare-part availability, data removal, battery take-back and local electronics recycling. |
What is not established by the published files
The project documentation must provide any claimed rated service life, battery cycle endurance, duty limits, warranty and repair intervals for the exact hardware. Without a cited endurance test, report those values as not established, not zero and not an estimate. For a DIY build, keep a parts-replacement log and report conditions when measuring reliability.
Original documentation
- Official v2 project and experiments
- Versioned v2 README and stated cost
- Independent build-file index
- Open Duck Mini V2 printable models
- Official project source
- Official project source
- Motor software and v2 documents
- Official project source
Found a changed specification? Submit a correction with its source ↗