Rotary Inverted Pendulum
Based on published sources · Not tested by us ·
Overview
Printed rotary pendulum with Arduino Nano control and a MuJoCo-to-hardware learning pipeline; preserved sources include rig-specific distilled policy weights and differing bring-up microstep guidance. [S001] [S006] [S009] [S010] [S011]
This project combines printed mechanics, an Arduino Nano and a stepper-driven rotary arm with a learned balancing controller. The repository includes MuJoCo training, hardware fine-tuning, distillation and standalone firmware. The selected commit is 230bdcc9c4f1751a2bfb2447b52fb349296ed31c; this catalog reviewed the sources without building or operating a pendulum. [S001] [S002]
Specifications
| Detail | Description |
|---|---|
| Type | Actuated rotary arm with passive pendulum link for control experiments. Reported by source [S001] [S005] · Checked 2026-10-01 |
| Intended users | Developers able to build and calibrate a physical control rig and distinguish simulated from measured results Editorial assessment [S001] · Checked 2026-10-01 |
| Assembly | Not known |
| Calibration | Match driver wiring, microsteps, rig dynamics and selected policy. Standalone sketch defines 32 microsteps; first-power-on guide still describes 16/8 settings. Reported by source [S006] [S009] [S010] · Checked 2026-10-01 |
| Operating system | Not known |
| Computer needed | Not known |
3D preview
Preview not available yet. A model has not yet been prepared and approved for display on this page. This does not mean the project lacks CAD files; see Source files and licenses for the reviewed source availability.
Assembly and use
The parts estimate belongs to a particular small rig
The BOM, dated May 25, 2026, estimates approximately £20 in parts and lists an ATmega328P Nano, short-body NEMA17 motor, AS5600 encoder and driver alternatives. Tools are listed separately. That estimate is not a verified current delivered budget and should not be treated as a like-for-like commercial laboratory-system comparison. [S005]
The printed pendulum incorporates a UK two-pence coin as its tip mass. The print guide explains that omitting it changes the mass and inertia assumed by the model. Source geometry, physical assembly and learned dynamics therefore need to remain consistent. The archive contains STL and URDF files; the external Onshape document was not independently exported in this review. [S005] [S007] [S012]
Reconcile the driver configuration before using the examples
The TMC2209 and DRV8825 options are not interchangeable pin-for-pin, and their current-setting conventions differ. The first-power-on guide also describes 16 microsteps for TMC2209 and 8 for DRV8825, whereas the selected standalone sketch explicitly sets MICROSTEPS = 32 and documents the corresponding driver pin settings. This discrepancy is preserved as a build check rather than silently presenting the pages as one consistent procedure. [S005] [S006] [S010]
The standalone sketch assigns the step signal to the Nano's Timer1-compatible pin and waits for magnet detection before engagement. Its settling pose becomes the encoder reference. These details make wiring and initialization part of the controller configuration, not incidental setup. No current setting, motion envelope or protective behavior was tested here. [S010]
A weight file name describes hardware, not network width
Committed policy headers are named by rig, driver and microstep ratio. The default sketch selects the rig1 TMC2209 32-microstep header; another preserved header for rig2 declares a 24–16–16–1 network. The final 32 in its filename is the microstep ratio, not a 32-unit hidden layer. The source includes the numerical weights, but that does not establish the complete original teacher checkpoints, replay buffers or measured training logs. [S009] [S010] [S011] [S012]
The distillation guide describes behavior cloning followed by DAgger under the intended deployment transport. It reports that the larger floating-point student missed the Nano's timing budget. The selected sketch sets 50 Hz control, a four-action smoothing window, four observation frames and a maximum velocity of 3.5 rad/s. These must agree with the policy's configuration; the weight header alone does not encode the operating point. The standalone procedure measures actual loop rate, because a nominal setting alone is not proof that inference meets it. Upstream balancing results remain reported results, not catalog reproductions. [S008] [S009]
The repository's MIT license accompanies the preserved source package. External CAD, toolchains and dependencies still need their own checks. Reproduction remains contingent on a matched physical rig, policy, measured timing and source dependencies; none was installed, trained or flashed during this review. [S003] [S005] [S009]
Cost
No current, complete configuration-specific build cost has been established for this profile.
Source files and licenses
Available project sources support research coverage; complete build and commercial qualification remain separate.
| Layer | Availability / license |
|---|---|
| mechanical design | available · MIT Selected repository artifact scope. Electronics are wiring references and component modules, not a complete custom PCB package; model weights are rig-specific committed C headers. External Onshape source and dependencies are separate. [S001] [S003] [S012] |
| electronics | available · MIT Selected repository artifact scope. Electronics are wiring references and component modules, not a complete custom PCB package; model weights are rig-specific committed C headers. External Onshape source and dependencies are separate. [S001] [S003] [S012] |
| firmware | available · MIT Selected repository artifact scope. Electronics are wiring references and component modules, not a complete custom PCB package; model weights are rig-specific committed C headers. External Onshape source and dependencies are separate. [S001] [S003] [S012] |
| software | available · MIT Selected repository artifact scope. Electronics are wiring references and component modules, not a complete custom PCB package; model weights are rig-specific committed C headers. External Onshape source and dependencies are separate. [S001] [S003] [S012] |
| model weights | available · MIT Selected repository artifact scope. Electronics are wiring references and component modules, not a complete custom PCB package; model weights are rig-specific committed C headers. External Onshape source and dependencies are separate. [S001] [S003] [S012] |
| datasets | not found · License not fully assessed Training and distillation procedures are present, but complete teacher checkpoints, replay buffers and original physical recordings are not established in the preserved archive. Generated policy headers are not the complete training dataset. [S008] [S009] [S012] |
| documentation | available · MIT Selected repository artifact scope. Electronics are wiring references and component modules, not a complete custom PCB package; model weights are rig-specific committed C headers. External Onshape source and dependencies are separate. [S001] [S003] [S012] |
References
Links identify the documentation and revisions used in this profile. Access dates record when each source was retrieved.
- S001 · ferrolho / project contributors
Upstream project overview
Accessed 2026-10-01 · README.mdSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S002 · ferrolho / project contributors
Repository revision and release metadata
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31cSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S003 · ferrolho / project contributors
Repository license
Accessed 2026-10-01 · LICENSESource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S004 · ferrolho / project contributors
Pinned repository artifact inventory
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c archive file inventorySource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S005 · ferrolho / project contributors
Rotary pendulum website/src/content/docs/build/bom.md
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c / website/src/content/docs/build/bom.mdSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S006 · ferrolho / project contributors
Rotary pendulum website/src/content/docs/build/first-power-on.md
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c / website/src/content/docs/build/first-power-on.mdSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S007 · ferrolho / project contributors
Rotary pendulum website/src/content/docs/build/printing.md
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c / website/src/content/docs/build/printing.mdSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S008 · ferrolho / project contributors
Rotary pendulum website/src/content/docs/train/distill.md
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c / website/src/content/docs/train/distill.mdSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S009 · ferrolho / project contributors
Rotary pendulum website/src/content/docs/train/flash.mdx
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c / website/src/content/docs/train/flash.mdxSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S010 · ferrolho / project contributors
Rotary pendulum firmware/RLControl/RLControl.ino
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c / firmware/RLControl/RLControl.inoSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S011 · ferrolho / project contributors
Rotary pendulum firmware/RLControl/policy_weights_rig2_tmc2209_32.h
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c / firmware/RLControl/policy_weights_rig2_tmc2209_32.hSource notes
Source text inspected for the cited scoped claims; see profile claim notes.
- S012 · ferrolho / project contributors
Complete preserved file inventory
Accessed 2026-10-01 · 230bdcc9c4f1751a2bfb2447b52fb349296ed31c complete archive inventorySource notes
Source text inspected for the cited scoped claims; see profile claim notes.
Correction guidance · Discussion is not enabled · Profile format 0.6.0-draft.1