ROBOTICS 101Concept explainer

The Robot Software Stack

Robot software is organized in layers. Drivers talk to hardware. Middleware such as ROS 2 moves messages between programs. Perception turns sensor data into a picture of the world. Planning decides what to do, control turns plans into motor commands, and applications tie it all to a task. Each layer adds a little delay, and the total sets how fast the robot can react.

The layers

From the bottom: hardware (sensors, motors, computers), drivers (turn raw device data into standard messages), middleware (moves messages between processes, such as ROS 2 over DDS), perception and state estimation (detections, maps, the robot's pose), planning (paths and decisions), control (motor commands at a high rate), and application (the task logic, such as a behavior tree). Reaction time adds up across the path:

$$t_{\text{react}} \approx t_{\text{sensor}} + t_{\text{driver}} + t_{\text{perception}} + t_{\text{planning}} + t_{\text{control}} + t_{\text{actuator}}$$

What to notice

Perception and planning usually dominate the total, so they are where effort to speed things up pays off most. The control loop runs much faster than planning, which is why the stack is split: the controller keeps the motors stable between plans. A robot moving at 1 m/s travels 10 cm in 100 ms, so reaction time translates directly into safety margins. Numbers here are typical orders of magnitude, not measurements of a particular robot.