AccelStepper: the ramp, done for you
The library most Arduino machines use: moveTo and run, the recurrence that times each step, where it starts braking, what stop() really does, and the step rate an Uno tops out at.
Open it in the simulatorWhat a printer’s firmware does between a line of G-code and two STEP pins: microsteps, trapezoid and S-curve ramps, AccelStepper, Bresenham, a G-code parser, homing and limits, and a plotter that does it all.
0 of 7 done
7 lessons in 3 chapters, about 7 hours on a simulated Arduino Uno R3. Free, in your browser, every step checked by the simulator.
The library most Arduino machines use: moveTo and run, the recurrence that times each step, where it starts braking, what stop() really does, and the step rate an Uno tops out at.
Open it in the simulatorThe plotter’s firmware reads G-code one line at a time. Split a line into words, set the position with G92, see modal motion and relative mode carry from line to line, and catch a corrupted line with a checksum.
Open it in the simulatorPut it all together on the G-code plotter: home it, drive the pen, draw a square line by line, read a ramp off every move, run a whole drawing, and make the machine faster by tuning its acceleration.
Open it in the simulatorEach lesson opens when the one before it is done, and each chapter ends in a project.
What a microstep is worth, ramps worked out and run, and the library that does it for you.
An A4988 and a TMC2209 with their mode pins on the Uno. Send both the same pulses and they turn different amounts: read each chip’s table, set 1/16 and 1/64, move one microstep, and count the pulses a second each mode costs.
0 of 7 steps
Jump a NEMA 17 past its ceiling and watch it lose steps. Then work out a trapezoid, find when a move becomes a triangle, run a ramp one step at a time, and see what an S-curve costs.
0 of 7 steps
The library most Arduino machines use: moveTo and run, the recurrence that times each step, where it starts braking, what stop() really does, and the step rate an Uno tops out at.
0 of 6 steps
Bresenham keeps two motors on one line, and a parser turns G-code into moves.
Two motors, one straight line. Step both at one rate and see the dog leg, trace Bresenham by hand, draw the line within half a step, and turn a feed along the path into a step rate per axis, capped at the limit.
0 of 6 steps
The plotter’s firmware reads G-code one line at a time. Split a line into words, set the position with G92, see modal motion and relative mode carry from line to line, and catch a corrupted line with a checksum.
0 of 6 steps
Homing that brakes and backs off, soft and hard limits, and the boss: a G-code plotter.
Home a two-axis machine the way Grbl does: seek fast, brake past the switch, back off, touch slowly, pull off. Then refuse a target off the bed, and stop dead when a switch trips mid-move.
0 of 6 steps
Put it all together on the G-code plotter: home it, drive the pen, draw a square line by line, read a ramp off every move, run a whole drawing, and make the machine faster by tuning its acceleration.
0 of 6 steps
All 7 lessons, in order, each with what it covers. Any of them opens in the editor right away.
Every lesson runs in the simulator with nothing to buy. When you want the real thing, these kits have the parts.
Pick the starter kit you own and run every lesson in its manual with the same parts on the same pins.
See every kitYes. All 7 lessons of Stepper motion planning are free and run in your browser, with nothing to install and no parts to buy before you start.
No. Every lesson runs on a simulated Arduino Uno R3 with its parts on the canvas, and the simulator checks each step as you go. When you want to build it for real, the same wiring and code work on a real board.
About 7 hours: 7 lessons in 3 chapters, each one a few short steps. Your progress is kept, so you can stop after any lesson and pick up where you left off.
Each chapter ends in a project that puts it together: AccelStepper: the ramp, done for you, G-code parsing: words, modes and checksums and Boss: a two-axis plotter.
With "Microsteps: what one pulse is worth", and each lesson builds on the one before it. New to circuits? Electronics basics is the course that starts from zero.