The classic unstable system, kicked upright and held there at 1 kHz
A didactic inverted pendulum on a 1 m rail, built to learn feedback control. The cart is designed to kick the pendulum up from its stop and balance it with a cascaded PID or LQR, while a Windows app plots every signal and lets you change every gain live.
In development
Level: Intermediate
Version: 0.1.0
Design v0.1.0: simulated and checked in CAD; the first unit is not built yet
IP-11 inverted pendulum on its 1 m rail, with the mech livery
The experience
Start in the simulator: PendulumStudio runs the same controller as the firmware, so you can press START, push the pendulum and switch PID ↔ LQR before printing anything. Then print the carriage, pivot, towers and armor plates, bolt them to a 1000 mm V-slot rail and stack the M5Stack CoreS3 on its stepper driver. On START the cart is designed to home, move to the side opposite the lean, kick the pendulum up from its ±15° stop and hold it upright, also when you push it. From there every gain, filter and limit is yours to change while it balances, with the charts showing each controller term and a seven-chapter theory course explaining why.
What makes it special
Kick-up from rest
From its ±15° stop the cart kicks the pendulum up with an energy-based burst, then balances it. Stops for ±12° and ±18° are included.
Two controllers, live
Cascaded PID and LQR state feedback, switchable on the fly. The default PID gains are the LQR law rewritten in cascade form.
1 kHz control loop
The loop runs at 1 kHz on the CoreS3 and commands the cart acceleration, so the motor and cart masses drop out of the model.
Simulator inside
PendulumStudio runs a line-by-line port of the firmware's supervisor and controllers on a cart-pole model with sensor noise and quantisation.
Every parameter live
Gains, filters, limits, the kick-up strategy and the setpoint can be changed while the pendulum balances, with the effect on the charts.
Safety built in
A mushroom E-stop cuts the 24 V motor power, NC endstops sit at both ends, soft limits act first and the feet clamp the rail to the table.
What you will learn
Cart-pole dynamics and linearisation
PID in depth: P, I, D, derivative filter, anti-windup
Cascade control and bandwidth separation
State space, pole placement and LQR
The kick-up: energy strategy and state machine
Sensing and filtering noisy signals
Stepper drives, microstepping and torque-speed
Step-by-step tuning, in the simulator and on the machine
Three ways to get it
Be the first to build the Inverted Pendulum
This kit is still in development. Leave your contact and we will write to you when it is released.
DIY: files and software
The whole build is yours: print the parts, buy the components, build the electronics and assemble the machine.
You do
Print, source the components, build the boards, assemble
Print files of every part (STL, STEP and 3MF)
Electronics design: wiring, schematics and the list of components
Firmware and software, including the app when the kit has one
Price on request: it depends on the option. In the DIY option the filament, the electronics and the hardware are yours to source (this page lists them); in the kit option, only the filament.
Included with every option
The files, the manual and the software come with every option, the ready-to-use machine too.
Print files
STL files for every printed part
Two-colour 3MF armor plates with the yellow mech livery
STEP files of the assembly and of each part
Interchangeable stops for ±12°, ±15° and ±18°
Firmware for the M5Stack CoreS3
Assembly manual
Build guide with every part, fastener and step
Bill of materials and wiring diagram
Tuning guide and lab experiments
Theory course in 7 chapters
Safety notes and first power-up checklist
App
PendulumStudio Windows
Live pendulum view and rolling charts of angle, position, command and controller terms
Parameter editor: change every gain, filter and limit while it runs
LQR designer: from Q and R to the gains, the closed-loop poles and the equivalent PID
Simulator that runs a port of the firmware's controller, with sensor noise