Skip to content

Your First Robot

Mehrdad Pajuhaan edited this page Nov 30, 2026 · 1 revision

Your First Robot

This page follows one session with Claude Code: a pan-tilt head with an ESP32 and two servos. You watch the design grow in the window, steer it with notes, check it and undo what you do not like.

Before you start

  1. Robot Studio is running (npm run dev, see Installation).
  2. Claude Code is connected to it (see Connect an AI Agent). Inside Claude Code, /mcp should list robot-studio as connected.
  3. Keep the Robot Studio window open. The agent will ask for your approval there, for example to download the compiler for the ESP32.

Optional: install KiCad (9 or newer) if you want KiCad's electrical and design-rule checks and fabrication files for the board. Without it the agent can still design the board, and the tools say which KiCad checks could not run. See External Programs and Add-ons.

1. Ask

Paste this into Claude Code:

Use Robot Studio over MCP. Create a new project called "Pan-Tilt" and design a pan-tilt head: an ESP32 and two servos, a printed base and brackets with working joints, the wiring and schematic, a small carrier PCB and firmware that sweeps both axes slowly. Run the checks, fix every issue they find, and tell me what to buy and what to print.

The agent decides the details itself. A session usually goes through these stages, following the studio's own workflow guide (read_guide topic workflow):

Stage Typical tools
A new, empty project. The project open before stays saved on disk. new_project
Real parts from the catalog: an ESP32 board and hobby servos (the catalog has SG90, MG90S, MG996R and DS3218). search_catalog, get_module, add_part
The printed base and brackets, designed as parts of this robot create_parametric_part, create_solid_part
Parts placed and joined; the two mates turned into joints driven by the servos mate_parts, set_joint, move_joints, check_joint_travel
Wires and the schematic connect_pins, add_wire, write_schematic_page, review_schematic_sheet
The carrier board, and the board placed in the robot set_pcb_outline, place_on_pcb, route_pcb_path, place_board_in_robot
Firmware that includes the files generated from the design (pins.h, robot_model.h) write_firmware, get_pin_map, build_firmware
Checks and fixes run_checks, set_making, set_tolerances
What to buy and what to print get_build_plan, get_bom

2. Watch it happen

The top bar has two pills on the right:

  • The agent pill reads Connect an agent until the first tool call, then Agent connected, and Agent working… while calls arrive. Click it for Agent activity: every tool the agent called, a short summary of its arguments (or its error) and how long it took.
  • The health pill reads Checking…, Ready, N things to check (warnings) or N problems (errors). Click it for the Problems list.

The places (tabs across the top, see The Places) each show one view of the same project:

Place What to look for
Robot The base, brackets and servos appear as the agent adds them, and the joints move when it poses them.
Parts The printed base and brackets, each with how it is made.
Schematic The ESP32, the servos and their connections.
PCB The carrier board's outline, parts and copper.
Code The firmware files of the ESP32, beside the files the studio generates from the design.
Build What to buy, what to make, the board, programming and assembly, each with what is still missing.

The agent can look at the window too: capture_view gives it a screenshot of a place.

3. Approve what touches the real world

When the agent compiles the firmware for the first time, the studio needs arduino-cli and the ESP32 board package. The agent asks for them (install_toolchain), and the window shows an approval dialog with what will be downloaded. Click Allow or Deny. The same happens before an upload to a real board, a print, running a program and other real-world actions (see MCP Tools). For some kinds, such as downloads and uploads, the dialog can allow the same kind of request without asking until Robot Studio restarts; prints, add-ons, Git pushes and model downloads always ask. Before an upload, the dialog warns that whatever the board drives, such as servos, may start moving as soon as the new program runs.

4. Steer it with AI Annotate

The purple AI Annotate button lets you point at something and tell the agent what to do with it:

  1. Click AI Annotate. What a click would pick lights up purple.
  2. Click a part, a pin, a wire, a track or a line of code.
  3. Write what you want, for example "Make this bracket 20 mm taller", or say it with Windows voice typing.

The note waits in a queue (the arrow beside the button shows it). The next answer of any tool the agent calls carries the note, with exactly what it is about. The agent acknowledges it (acknowledge_annotations) as received or working, and marks it done with a one-line reply you can read beside the note. Notes are saved with the project in agent/annotations.json. They are messages, so Undo does not take them back.

If the agent is idle, ask it: "Read my notes in Robot Studio and do what they ask."

5. Read the design feedback

The studio analyses the design after every change. When an agent's change creates or fixes a problem, the tool's answer carries design_feedback: the new issues, with the parts involved and, for a collision, the shared volume and where it is; the issues resolved; and how many are still open.

run_checks lists everything wrong with the design right now:

  • Electrical: supply voltage against pin limits, unpowered or ungrounded parts, outputs in conflict.
  • Mechanical: shaft and bore fits of mates; solids that occupy the same space; joints that hit something within their travel, found by moving every joint through its range.
  • Physics: the robot stood up in the MuJoCo simulation. Does it fall? Is a servo overloaded?
  • Making: made parts that do not yet say their material, route, print orientation or tolerances (issues named make.*).
  • Board: parts not yet placed on the PCB.

The same list is in the window's Problems panel. A finished design should reach zero errors. Warnings need a decision from you or the agent.

6. Undo

  • In the window: Ctrl+Z to undo and Ctrl+Y to redo, or the arrows in the top bar.
  • Each place keeps its own history. The agent's changes and yours are in the same history, so you can undo what the agent did.
  • You can also ask the agent: "Undo your last change." It has the undo and redo tools.

7. What to buy and what to print

Ask the agent for the build plan, or open the Build place. get_build_plan gives, in order:

  1. Buy: the standard parts and the wire as a cut list.
  2. Make: each made part by shop and material, with its size, route, threads and fits and its files; and the circuit board: ordering, assembling and testing it.
  3. Program: how each controller gets its program.
  4. Assemble: the written assembly steps and the kit of each sub-assembly.
  5. Apps: any tools made for this robot.

Ask for "export the build folder" to have export_build write all of it into one folder: a shopping list (PDF and CSV), every made part in the formats of its process with its drawing, the board's fabrication and assembly files, the controllers' sources and the assembly steps. See Manufacturing.

8. Next prompts

  • "Write the assembly steps with set_assembly_steps, in the order I would build it at a table."
  • "Add a motion called Nod that tilts the head down and back within the joint limits, check it with check_motion and play it in the window."
  • "My printer is a Prusa MK4S. Add it to the workshop, slice the base and tell me the print time."

More in Example Prompts.

Honest limits

  • The checks and the physics simulation find many mistakes before anything is made. They are not proof that the robot will work.
  • Nothing designed in Robot Studio has been built on real hardware yet, and uploading firmware has not been tried on a real board.
  • The agent's answers are only as good as the part data it works from. Ask it to say which figures it assumed.

Clone this wiki locally