Skip to main content

Module 02 · Robot fundamentals

Every robot, from a vacuum cleaner to a humanoid, is built from the same few ideas. It has parts that sense, think and move. Those parts live in different places and point in different directions, so the robot needs a clean way to describe where things are. It has to turn desired motions into joint angles and joint angles into forces, and it has to keep correcting itself because the world never behaves exactly as predicted.

This module teaches those ideas in the order you will use them: anatomy, frames, kinematics, dynamics, control. The maths is real but always tied to code you can run in NumPy, so you can poke at every formula. Nothing here needs a robot. By the end you will have a tiny virtual arm and a tuned motor controller of your own.

By the end of this module you can…​

  • Name the subsystems of a robot and estimate its power and data budget.
  • Describe poses with rotation matrices, homogeneous transforms and quaternions, and compose them without ordering mistakes.
  • Compute forward kinematics and Jacobians, and solve inverse kinematics analytically and numerically.
  • Read and use the manipulator equation, and check motions against torque limits.
  • Build, tune and debug a PID controller, including anti-windup, and explain cascaded and impedance control.

Lessons​

LessonWhat you buildTime
The anatomy of a robotA power and sensor data budget calculator30 min
Frames and rigid transformsA small transforms and quaternion library40 min
Forward and inverse kinematicsA 2-link arm with analytic and damped least squares IK45 min
Dynamics essentialsMass, Coriolis and gravity terms, plus a torque check40 min
Control and PIDA PID controller tuned on a simulated motor45 min

Module project: the virtual arm​

Combine the pieces into one script. Your 2-link arm follows a circle with its hand: inverse kinematics turns each point into joint targets, a PID controller (one per joint) drives simulated joints toward them, and the dynamics model from lesson 4 supplies gravity compensation so the controller only corrects errors. Plot the hand path against the desired circle and report the largest tracking error. If the path is a wobbly circle you have found a tuning problem; if it is a clean one, you are ready for the next module, where you will connect software pieces like these together with ROS 2.

Start with The anatomy of a robot.