Skip to content
Tutorials Center
My learning

Topics

Lesson 1 of 38 ยท Getting Started

Introduction to Robotics

Learn what a robot is, the sense-think-act loop that every robot runs, a short history of robotics, and simulate your first robot control loop in Python.

A robot is a machine that senses its surroundings, makes decisions, and acts on the physical world, usually by moving something. A washing machine follows a fixed program and does not really look at the world. A robot vacuum measures walls, notices a chair leg, and changes course. That feedback from the world into the decision is what turns a machine into a robot.

Robotics is the field that builds such machines. It borrows from mechanical engineering (bodies and joints), electronics (sensors and motor drivers), mathematics (geometry and probability), control theory (making motion accurate) and computer science (perception, planning and software). This course walks through all of them with small simulations you can run in your browser. No robot is needed: the physics is replaced by short Python models, and the ideas carry over to real hardware.

The sense-think-act loop

Almost every robot, from a toy rover to a factory arm, repeats the same loop many times per second.

flowchart LR
    W["World"] -->|"light, sound, force"| S["Sense<br/>(sensors)"]
    S --> T["Think<br/>(estimate, plan, decide)"]
    T --> A["Act<br/>(motors, grippers)"]
    A -->|"motion, forces"| W

The loop is closed through the world: the robot's actions change what its sensors see next.

  • Sense: sensors turn physical quantities (distance, angle, light, acceleration) into numbers. Those numbers are always noisy and incomplete. See Sensors and Noise.
  • Think: software estimates the state of the robot and the world, plans what to do and chooses commands.
  • Act: actuators such as motors, pistons and speakers convert commands into motion. They are imperfect too: wheels slip and motors have limits. See Motors and Actuators.
Python A robot in a corridor: the loop in 25 lines

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

The robot never sees the true position, only a noisy reading, yet it settles close to 0.5 m. The rule speed = 1.5 * error is a proportional controller, the first step of PID control.

A short history

The word robot comes from a 1920 Czech play, from robota, meaning forced labor. The ideas then moved into engineering:

Period Milestone
1950s-60s The first programmable industrial arm is patented; the first one goes to work on a die-casting line in 1961.
1960s-70s Shakey, a mobile robot at SRI, combines vision and planning (and gives us the A* search algorithm).
1980s Industrial arms spread through car factories; the SCARA arm appears.
1990s-2000s Probabilistic robotics, SLAM, Mars rovers, robot vacuum cleaners.
2010s Cheap sensors, ROS, drones, warehouse robots, deep-learning vision.
2020s Legged robots, general-purpose manipulation, robots trained with simulation and learned policies.

Why robots are hard

A program on a laptop runs in a clean, predictable world. A robot lives in a messy one:

  • Uncertainty. Sensors are noisy, maps are incomplete, wheels slip.
  • Real time. A balancing robot must react in milliseconds; a late answer is a wrong answer.
  • Physics. Mass, friction and delay mean a command does not become motion instantly.
  • Safety. A bug can break hardware or hurt people.
  • Variation. The lighting, floor and objects differ every day.

Much of this course is about handling those problems with mathematics instead of hope.

Python How sensor noise hurts a robot

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

With noisy readings the commanded speed jumps around, which wears motors and makes the motion jerky. With the very noisy sensor the robot even ends with a negative gap: it believed the wall was farther away than it was and drove into it. The lesson on sensor fusion shows how to clean readings up.

Parts of a robotics project

Most projects split into the same layers, and the chapters follow this order:

  1. Mechanics and kinematics: the body and how its joints move it (Kinematics).
  2. Sensing and perception: what the robot can measure (Sensors).
  3. Control: turning goals into accurate motor commands (PID).
  4. Planning and localization: where to go and where I am.
  5. Software architecture: how the programs communicate.

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. Which feature most clearly separates a robot from a simple automatic machine?

    Robots close a loop through the world: sensor data influences the next action. A machine with a fixed program does not.
  2. 2. What are the three steps of the basic robot loop?

    Sense, think, act repeats many times per second.
  3. 3. In the corridor example, why does the robot not stop exactly at 0.5 m every time?

    Noise and imperfect actuators are normal in robots, which is why control and estimation matter.
  4. 4. Which of these is an actuator?

    Actuators produce motion or force. Cameras and gyroscopes are sensors.

Summary

  • A robot senses, thinks and acts in a loop closed through the physical world.
  • Sensors are noisy and actuators are imperfect, so robotics is largely about managing uncertainty.
  • A simple proportional rule already gives useful behavior; PID control improves on it.
  • This course covers kinematics, sensing, control, planning, localization, software and applications.

Next: Types of Robots