Building a basic robot isn't about fancy 3D printing or exotic chips. It's about getting something that moves on command and then slowly making it do useful things.

I've built a lot of these over the years. The version most people actually want is a small Arduino-based vehicle with two wheels and an ultrasonic sensor so it doesn't run into walls. That takes about 45 minutes if you've done it before and about three hours if you're reading the manual for the first time. Here's how it works in practice. Start by gathering the parts. You need an Arduino Uno or compatible board, an L298N motor driver module, two continuous rotation servos for the wheels, an HC-SR04 ultrasonic sensor, a 9V battery or 4xAA holder, and some jumper wires. Total cost runs roughly $25 to $40 depending on where you source from. Skip the branded kits. They charge a premium for plastic that does nothing different from cardboard. The motor driver connects to the Arduino's digital pins. Pin 5 and 6 control the left servo through enable and direction pins. Pin 9 and 10 handle the right one. The ultrasonic sensor's trig goes to pin 12 and echo to pin 11. Power the servos from the battery through the motor driver's V_in and GND. Ground everything together. This last step matters more than most guides mention. If the Arduino ground isn't connected to the motor driver ground, your readings will be garbage and you'll waste an afternoon chasing phantom bugs.

Here's the core sketch logic. Load the Servo library. Define two servo objects. In setup, attach them to their respective pins and set initial speed to zero. The loop checks distance from the ultrasonic sensor and drives forward until something is within about 15 centimeters, then backs off and turns. Keep it simple at first. Don't add WiFi or Bluetooth until the basic movement works reliably.

The calibration problem that nobody warns you about

Continuous rotation servos are not the same as standard servos. They're modified so the internal potentiometer that normally limits rotation is removed. What that means practically is that the "stop" signal at 90 degrees is never exact. One servo might drift forward at 78 microseconds while another needs 92. My first working robot had this issue and I spent six hours thinking the code was broken before I realized the servos themselves were misaligned at the center point. The workaround is straightforward. Upload a minimal test sketch that pulses each servo independently at 1500 microseconds and watch which way it moves. Adjust until one full rotation per second is roughly equal on both sides. Then test forward, reverse, and stop positions by trying 700, 1500, and 2300 microseconds. Write down the actual values that work for your hardware. The ones in tutorials are suggestions, not rules. Use yours.

Get the Full Details

How to make a Simple Robot | Arduino Robotics for Beginners - YouTube
How to make a Simple Robot | Arduino Robotics for Beginners - YouTube

Power management is where simple robots actually fail

The L298N module has a voltage drop of about 2 volts. If you're powering the Arduino and servos from the same 9V battery, the Arduino will brown out under load and the whole thing resets unpredictably. I've seen this repeatedly in hobby labs. The fix is separating the power rails. Run the servos directly from the battery pack through the motor driver. Feed the Arduino a steady 5V from a separate buck converter or a USB power bank. This usually cuts random resets from happening dozens of times per hour down to never. Also, continuous rotation servos draw around 500 milliamps each under load. Two of them plus the Arduino and sensor easily pull 1.5 amps. A standard 9V battery lasts maybe 20 minutes at that rate. Budget lithium cells or a proper NiMH pack instead. A 7.4V 2000mAh pack will give you roughly 40 to 50 minutes of run time depending on terrain.

When this approach won't work for you

If you need precision navigation or the ability to map a room, this simple ultrasonic approach falls apart. The HC-SR04 has a 15-degree beam angle and unreliable readings past two meters. It also struggles with soft or absorbent surfaces like carpet. For anything beyond flat floors in open spaces, upgrade to a Time of Flight distance sensor or a LiDAR unit. The code complexity increases significantly but the results justify it. At that point you're no longer building a simple robot and should consider using an ESP32 with ROS2 navigation stacks instead of reinventing localization from scratch. For most people asking this question, though, the Arduino servo approach is sufficient. Wire it up, calibrate the servos properly, separate your power rails, and flash a basic obstacle avoidance loop. You'll have something that drives around your living room in under two hours.