Physical AI: Intelligence That Has to Act
A chatbot that gives a bad answer costs you a rephrase. A physical AI that gives a bad answer drives a motor into a wall. That single difference changes the whole design.
What makes AI physical
The difference between a wrong sentence and a wrong motor command changes the design completely. The model is allowed to choose what should happen, but a separate controller is allowed to refuse: the controller holds the limits, and the model's output is treated as a request the controller can reject. That is the most important architectural habit in any physical AI project, and it costs about ten lines of code.
There is a second, less obvious difference. Text is reversible, a motor is not. A robot that pushes against an obstacle loads the gearbox, heats the motor and drains the battery, and none of that shows up as an error message. Physical systems also have state nobody wrote down: friction, backlash, the texture of the floor. A physical AI has to cope with a world that does not hold still between two samples.
The three jobs in every physical AI
Split the system into three parts and it stops being mysterious. The model is the planner, and it decides what the goal is, for example follow the light. The controller is the low-level loop that holds a setpoint, for example the PWM duty cycle that puts the sensor on the light. The sensors close the loop back to the planner. Each part runs at a different rate: the planner at a few hertz, the controller at hundreds, the sensors at kilohertz.
Almost every failed student robot tries to put all three in one loop, and the servo twitches because the planner and the controller are fighting over the same variable. Split them, run each at its own rate with millis(), and the same hardware starts working. The projects below are ordered in exactly that way, because a planner built on a controller that does not work yet tells you nothing about the planner.
Step by step
-
Start with the part that is easy to control
A fan or a servo responds predictably and cannot be damaged by a bad decision. Get the whole loop working on it before anything with wheels.
-
Write the controller first
On-off, then proportional, then PID if you need it. Know how the output behaves before you let anything else change it.
-
Add the sensor that closes the loop
One sensor whose reading you can compare against a setpoint. Log both numbers so you can see the error you are trying to reduce.
-
Give the planner a menu, not raw control
Let the higher level choose between track, stop and search. Letting a model write raw motor values is how things break.
-
Enforce the limits below the planner
Clamp the angle and the speed in the controller code, and add a physical limit switch for the one axis that could hurt someone.
-
Test the failure case first
Unplug the sensor mid-run and confirm the robot stops rather than spinning. A physical AI that is only tested when everything works has not been tested.
What you'll need
| Item | Qty | Why |
|---|---|---|
| Arduino Uno R3 | 1 | Enough pins and timers for a closed loop at 16 MHz, and the board most students already own. |
| SG90 micro servo | 2 | A safe first actuator, with a limited range and no free-running wheels, and easy to mount to a sensor. |
| Light-dependent resistor | 1 | The light source the tracker follows, and an analogue input whose error curve you can plot. |
| HC-SR04 ultrasonic sensor | 1 | Distance feedback for the second axis of the tracker, and the reading the planner uses. |
| L298N dual H-bridge module | 1 | Drives small DC motors with current that an Arduino pin cannot supply on its own. |
| Pushbutton | 1 | A manual stop that works even when the code does not, which is the point of a stop button. |
Practise it before you build it
Every step above has a matching circuit in the ThinkEdge Learn simulator. The simulator runs a real
Arduino sketch against a modified-nodal-analysis solver, so digitalWrite actually drives the
LED on screen and the readings change when you change the wiring — no hardware, no burnt components.
A real solar panel tracks the sun across the sky to capture 30-40% more energy than a fixed panel. We can build a simple 1-axis version with two LDRs (one on each side of a divider) and a servo. The Arduino reads both LDRs, compares them, and turns the servo toward the brighter side. With more LDRs, you can do 2-axis tracking.
Mount an HC-SR04 ultrasonic sensor on top of a servo. Sweep the servo from 0° to 180° and back, and at each step measure the distance. Print the results to the Serial Monitor as "angle,distance" pairs. Open the Serial Plotter in the Arduino IDE to see a live radar-like graph of the room. With Processing on your computer, you can build a full visual radar.
Real smart fans use TWO sensors: temperature (to know WHEN to turn on) and motion or distance (to know IF someone is present). If it's hot AND someone is within 100 cm, the fan turns on. This avoids the silly situation of a fan blowing in an empty room. We use the DHT11 for temperature, the ultrasonic for distance, and a real DC fan motor for the output.
Build a feeder that detects when an animal is nearby and smoothly dispenses food by rotating a servo. The ultrasonic sensor measures distance; when the pet is at the "close" preset (10 cm) or the "near" preset (50 cm), the servo sweeps from 0° → 90° over 2 seconds (opening the chute), holds briefly, then sweeps back 90° → 0° over 2 seconds (closing). At the farther presets (100 / 200 / 400 cm) the feeder stays idle — servo at rest, LED off — because the pet is too far away. The green LED is on for the full 4-second feeding motion when it does fire. This is the same pattern as automatic pet feeders, smart trash cans, and vending machines.
A servo motor holds whatever angle you tell it. Inside the servo is a small DC motor, a gearbox, and a potentiometer that tells the servo's brain where it currently is. The Arduino sends a pulse 50 times per second; the pulse width (1ms to 2ms) tells the servo the target angle (0° to 180°). The Servo.h library handles all of this for you.
A 10-segment LED bar graph is the easiest way to visualize an analog input: spin a potentiometer and 1, 2, 3 ... 10 LEDs light up in sequence. This is a "VU meter" — the kind you see on stereo equipment. The Mega is ideal because it has 10 free digital pins without stealing any from the analog or serial pins. The same code can be extended to 20, 30, or 100 LEDs on a Mega.
Common questions
Do robots need AI to work?
Most industrial robots do not. A robotic arm on an assembly line runs the same fixed program thousands of times a day, and that is exactly why it is fast and reliable. AI earns its place when the world varies: a crate that is not always in the same place, a light that moves, a surface that is wet. If your project has a fixed environment, plain control logic will usually do better.
Is a humanoid robot the same thing as physical AI?
No. A humanoid is a shape, physical AI is a capability. A tracked robot can do physical AI perfectly well, and a humanoid walking on flat floor with no disturbance is mostly a control problem with a very hard actuator budget. Judge a physical AI project by how well it handles something unexpected, not by how human it looks.
How much does a physical AI project cost?
A solar tracker with a servo and two sensors runs about $35 to $60 in parts: $12 to $20 for the board, $5 to $10 for the servo, $3 to $6 for the light sensor, $4 to $8 for the ultrasonic sensor, and the rest on wires and a stand. The controller is the project. The hardware is the cheap part.
Related guides
Try the full simulator with your class
103 guided circuit projects, 21 lessons and an in-browser Arduino simulator. The first 15 projects are free, no account needed. NCERT Science mapping on 47 projects, with Arabic and English copy in the regional builds.