Control a Robot Arm From Anywhere

Build a phone-controlled robot arm simulation with private remote access.

Introduction

30 Second Summary

Pruning grapevines by hand is slow work. On December 3, 2026, Ryan_Resolution shared two MakerMods arms using a custom Budbreak pruner in Napa while @IsaacSin12 steered them from San Francisco over Starlink with a reported delay under 40 ms.

In this project, you will build a phone-based remote control for an SO-101 simulation in MuJoCo. WebSockets carry live camera frames plus control messages through a private Tailscale connection.

What You'll Build

With Wi-Fi turned off on your phone, you'll watch the SO-101 simulation respond as you move a control over mobile data.

By the end of this project, you'll have:

  • A phone-friendly operator page where live JPEG camera frames keep updating beside a frame-rate counter.
  • Six position actuator controls for shoulder_pan, shoulder_lift, elbow_flex, wrist_flex, wrist_roll, and gripper. The simulated arm holds its pose after half a second without messages.
  • A three-row round-trip latency record showing average and worst readings from the same computer, home Wi-Fi, and mobile data. You can compare your own readings with the Napa post's reported result of under 40 ms.
  • Secret Mission: Drive a calibrated real SO-101 follower with LeRobot safety limits plus physical safeguards.

What do I need before starting?

You need a Mac or Windows PC, an iPhone or Android phone, a Claude plan that includes Claude Code, and permission to use both devices on a private home network. Experience opening a terminal and running a command is enough, with no robotics or coding background required.

Before We Start

This is your moment to lock in the goal before the hands-on work begins. You are building a private remote control for a simulated robot arm so you can compare your own round-trip delay with 40 ms.

Load the Robot Arm

The SO-101 simulation needs its exact MuJoCo model before it can render the arm or read the model-defined actuator limits.

This step checks Claude Code, Python 3.12 or newer, and Git. Claude Code then creates the first working state inside robot-teleop.

In this step, get ready to:
  • Verify your required command-line tools.
  • Create the robot-teleop workspace.
  • Load the SO-101 model and render snapshot.png.
Check Claude Code, Python, and Git

These checks confirm that your computer can run Claude Code and create the local Python environment. Git supports the model download requested later in the step.

macOS

  • Check all three installed versions by running these commands:
claude --version
python3 --version
git --version

What do these commands do?

  • The first command checks that Claude Code can start from your terminal.
  • The second command shows the installed Python version.
  • The third command checks that Git is available for downloading the model folder.

Each successful command prints a version number. Python must report 3.12 or newer.

Windows

  • Check all three installed versions in PowerShell by running these commands:
claude --version
py --version
git --version

What do these commands do?

  • The first command checks that Claude Code can start from PowerShell.
  • The second command shows the installed Python version.
  • The third command checks that Git is available for downloading the model folder.

Each successful command prints a version number. Python must report 3.12 or newer.

✔️ I see version 3.12 or higher

Python is ready for the pinned packages in this project.

ⓧ I see an older version

The installed Python version is below the project minimum.

  • Install Python 3.12 or newer from the official Python downloads page.
  • Rerun the Python version check for your computer.

ⓧ Command not found

Your terminal cannot currently find Python.

  • Install Python 3.12 or newer from the official Python downloads page.
  • Start a new terminal session after the installation finishes.
  • Rerun the Python version check for your computer.
  • Install Claude Code with the command for your computer if its version check failed:

macOS

curl -fsSL https://claude.ai/install.sh | bash

What does this command do?

This downloads the official Claude Code installer. Bash runs the installer on your Mac.

Windows

irm https://claude.ai/install.ps1 | iex

What does this command do?

This downloads the official Claude Code installer in PowerShell. PowerShell runs the downloaded installation script.

The Claude Code version check should print a version after installation.

  • Install Python 3.12 or newer from the Python downloads page if Python is missing or older.
  • Install Git from the official Git installation page if its version check failed.
  • Rerun the three version checks from your computer's tab after completing any installation.

You should now see versions for Claude Code and Git. Python should show 3.12 or newer.

Create the project workspace

A fixed Desktop location makes robot-teleop easy to find when you inspect the generated image.

  • Move to your Desktop by running this command:
cd ~/Desktop

What does this command do?

The tilde points to your home folder. This command moves the terminal into its Desktop folder.

  • Create the project folder by running this command:
mkdir robot-teleop

What does this command do?

This creates robot-teleop on your Desktop.

The command should return without an error. Your new robot-teleop folder is now ready.

  • Move into the new project folder by running this command:
cd robot-teleop

What does this command do?

This makes robot-teleop the terminal's current folder.

  • Start Claude Code in robot-teleop by running this command:
claude

What does this command do?

This starts an interactive Claude Code session. The session can create files and run commands inside robot-teleop.

You should see the Claude Code session ready for your request inside robot-teleop.

Build the first working state

Claude Code will fetch only the robotstudio_so101 folder from MuJoCo Menagerie. It will use offscreen rendering to produce an image without a desktop viewer.

The model supplies the ranges for all six position actuators. Reading those values keeps the simulation tied to the exact model.

Before you send the prompt, what should the terminal and image prove if the exact model loads correctly?

  • Send this exact prompt to Claude Code:
Build the first working state of this project in the current robot-teleop folder. Create a local virtual environment and install exactly mujoco==4.1.0, websockets==17.4, and Pillow==13.0.0. Download only the robotstudio_so101 folder from google-deepmind/mujoco_menagerie, using a sparse clone or the folder's files, and keep it at robotstudio_so101/scene.xml. Do not download the whole Menagerie repository.

Create robot.py. Load robotstudio_so101/scene.xml with MuJoCo. Read the model instead of inventing names or limits. Confirm these six position actuators exist, in this order: shoulder_pan, shoulder_lift, elbow_flex, wrist_flex, wrist_roll, gripper. Print each name and its actuator control range in radians. Render one 640x480 offscreen image with mujoco.Renderer, aim a free camera so the whole arm and floor are visible, and save it as snapshot.png with Pillow. Run it with plain python. Never import mujoco.viewer and never use launch_passive or mjpython. Keep the project to robot.py and the later operator.html, apart from the virtual environment, downloaded model folder, generated snapshot.png, and later latency.md. When finished, run robot.py with the virtual environment's Python and report the exact terminal output and saved image path.

What does this prompt do?

The prompt pins MuJoCo to 4.1.0, websockets to 17.4, and Pillow to 13.0.0. It also limits the download to the required model folder.

Claude Code reads the six actuator ranges from robotstudio_so101/scene.xml. It renders a 640x480 PNG with mujoco.Renderer.

The prompt excludes the desktop viewer path. The result stays runnable with plain Python.

  • Wait for Claude Code to finish the requested installation and run.

The terminal should list shoulder_pan, shoulder_lift, elbow_flex, wrist_flex, wrist_roll, and gripper. Each actuator should have a numeric control range in radians.

Claude Code should also report the saved path for snapshot.png.

  • Open snapshot.png from the robot-teleop folder with your computer's file preview.
  • Use your computer's file browser to view the Desktop folder.
  • Open the robot-teleop folder.
  • Open snapshot.png.

You should see the complete SO-101 arm standing on a floor. This proves that robotstudio_so101/scene.xml loaded into the SO-101 simulation.

That is the first major result complete. Your exact robot model now loads and renders without a desktop viewer.

Missing MuJoCo or seeing a black image?

  • Send this message to Claude Code if Python reports that MuJoCo is missing:
Run robot.py with the local virtual environment's Python. Report the exact command you use and confirm MuJoCo imports successfully.

This asks Claude Code to use the environment where the pinned packages were installed.

  • Send this message to Claude Code if the image is black or misses the arm:
Keep mujoco.Renderer, but adjust the free camera lookat, distance, azimuth, and elevation until snapshot.png shows the whole SO-101 and floor.

This keeps the required renderer while correcting the camera position.

Help me diagnose the model load or snapshot result.

Compare your project with this checkpoint before moving on.

✔️ I'll try it first

Check the terminal output and rendered image yourself. Continue when the six ranges and complete arm are visible.

ⓧ Let me check my work

  • The robot-teleop folder contains the local virtual environment, robot.py, robotstudio_so101, and snapshot.png.
  • The robotstudio_so101 folder contains robotstudio_so101/scene.xml.
  • The robot.py file loads the model and verifies the six required position actuators in order. It reads their control ranges from the model.
  • The robot.py file renders a 640x480 offscreen image with mujoco.Renderer.
  • The snapshot.png file shows the SO-101 arm and floor.
  • The project does not import mujoco.viewer or use launch_passive or mjpython.

Your SO-101 model now loads and renders locally. Next, you will turn that still image into a continuous camera stream.

Stream the Arm Camera

Your MuJoCo render captured the SO-101 arm in snapshot.png. The next goal is to turn that frozen frame into a live view.

A remote operator needs a continuous camera stream over WebSockets before the controls become useful.

In this step, get ready to:
  • Generate the live camera stream with Claude Code.
  • Run the SO-101 simulation.
  • View the changing JPEG frames on the operator page.
Extend the project with live streaming

The next prompt turns the single offscreen render into a continuous simulation loop. It also creates the operator page that receives each frame.

  • Send this prompt to Claude Code in the existing robot-teleop session:
Extend the existing robot.py and create operator.html. Do not replace the working model loading, actuator-range output, snapshot, or offscreen camera. Run the MuJoCo simulation continuously in real time. About 20 times per second, render a 640x480 RGB frame with mujoco.Renderer, encode it as JPEG with Pillow, and send the JPEG bytes to every connected browser over a WebSocket using websockets 17.4.

In the same robot.py process, use Python's standard-library HTTP server to serve only operator.html on port 8000, and run the WebSocket server on port 8001. For now, bind both to localhost and print http://localhost:8000. In operator.html, connect to ws://localhost:8001, display each binary JPEG as it arrives, and show an updating frames-per-second counter. Do not use mujoco.viewer, launch_passive, mjpython, Node, React, ROS, Flask, or Docker. Run the finished state and report the HTTP link and WebSocket connection result.

What does this prompt do?

  • It preserves the working model loader plus the existing offscreen camera.
  • It advances the SO-101 simulation while mujoco.Renderer captures new frames.
  • It uses Pillow to encode each frame as a JPEG for the WebSocket connection.
  • It creates operator.html to display the frames with a live frame-rate counter.
  • Review Claude Code's report for the HTTP link plus the WebSocket connection result.

Claude Code should create operator.html beside robot.py. Its report should include http://localhost:8000 plus a successful WebSocket connection result.

Run the SO-101 simulation

The camera stream exists only while robot.py keeps the simulation plus both local servers running.

Before you run it, predict whether the terminal will return to a prompt or stay busy serving the stream.

  • Start the SO-101 simulation with the active virtual environment by running this command:
python robot.py

What does this command do?

The command loads robotstudio_so101/scene.xml through the virtual environment's Python interpreter. It then starts the continuous simulation plus the local HTTP and WebSocket servers.

You should see http://localhost:8000 in the terminal. The process stays active while it renders and broadcasts new frames.

Watch the camera stream

The operator page converts each binary JPEG message into the image you see. Its frame-rate counter confirms that new frames keep arriving.

Before you load the page, predict whether a successful connection will show one fixed image or a changing image with a counter.

  • Go straight to http://localhost:8000 in the browser that is already open.

You should see changing JPEG frames of the SO-101 arm. The frame-rate counter should keep updating.

You now have the live view that a remote operator needs before sending movement commands.

Camera stream not connecting?

  • Confirm robot.py is still running in the terminal.
  • Confirm ports 8000 and 8001 are free before restarting the simulation.
  • Keep the required 640x480 frame size if updates feel slow. Diagnose the timing without assuming a target frame rate.

Help me diagnose the camera stream.

Your operator page now delivers a live view from the SO-101 simulation. Next, you'll turn that view into a safe six-joint control loop.

Control the Six Actuators

Your operator page now carries a live view of the SO-101 simulation. The missing piece is a way to steer what you can see.

Adding safe controls for all six position actuators turns the camera stream into a teleoperation loop that stops motion when control messages disappear.

The controller combines joint-limit clamping with a dead-man timeout. Accepted targets stay inside the model's ranges. Missing messages make the arm hold its current pose.

In this step, get ready to:
  • Add safe six-joint control with Claude Code.
  • Test the page controls.
  • Trigger the hold-still timeout.
Add safe six-joint control

The page needs model-derived ranges before it can build accurate controls. The Python controller remains the final safety boundary for every target.

  • Return to Claude Code from earlier and paste this complete prompt:
Extend the working robot.py and operator.html with safe six-joint control. Keep these exact names and this exact order: shoulder_pan, shoulder_lift, elbow_flex, wrist_flex, wrist_roll, gripper. robot.py must read each actuator control range from the loaded model and send those ranges to the page when it connects. operator.html must create one slider per joint, an open/close gripper button, and keyboard pairs for the six joints. Page layout, colors, and key choices may vary, but the two filenames and six joint names must not.

Every target message must contain the joint name and target in radians. In robot.py, reject unknown names and non-numeric values, then clamp every accepted target to that actuator's model control range before writing data.ctrl. Never trust the page's slider range as the safety boundary.

Add a half-second dead-man behavior. The page sends regular messages while connected. If robot.py receives no page message for 0.5 seconds, set every actuator target to the matching joint's current position so the arm holds still. Send a status message so operator.html shows green while messages are arriving and red while the hold-still state is active. Keep the JPEG stream and offscreen renderer working. Run it and report one successful target, one clamped target, and the timeout transition.

What does this prompt ask Claude Code to do?

  • The updated robot.py reads all six actuator ranges from the loaded model. Those ranges become the source for the page controls and Python-side clamps.
  • The updated operator.html sends each target as a joint name with a radian value.
  • The timeout replaces stale targets with the arm's current joint positions. This prevents continued motion after page messages stop.

Claude Code should report one accepted target. It should report one out-of-range target clamped into its model-derived range.

Its report should also show the transition into hold-still after 0.5 seconds without a page message.

Test the page controls

Each page control should send a named radian target while the JPEG stream continues. Testing three control methods confirms that the sliders, button, and keyboard path all reach the simulation.

  • Send a radian target for shoulder_pan from the operator page.
  • Find the slider labelled shoulder_pan below the live image.
  • Drag the slider away from its starting position.

You should see six named sliders on the page. The arm should turn in the live image when the shoulder_pan target changes.

  • Send a new gripper target with the Open / close gripper button.
  • Find the Open / close gripper button below the joint controls.
  • Click the button once.

You should see the gripper change position while the camera stream keeps updating.

  • Send a keyboard target for shoulder_lift.
  • Find the keyboard pair that the operator page assigns to shoulder_lift.
  • Tap one key from that pair.

You should see shoulder_lift move in the live image.

Arm not moving?

A mismatched joint name prevents the controller from accepting the target. Use Claude Code to compare the received names with the model names.

  • Ask Claude Code to inspect the received names with this prompt:
Log each received joint name and compare it character for character with shoulder_pan, shoulder_lift, elbow_flex, wrist_flex, wrist_roll, and gripper. Report any mismatch without renaming the model actuators.

This check finds spelling differences while preserving the six names loaded from the model.

Get help diagnosing the control messages.

Trigger the hold-still safety state

A remote control must handle the moment its operator disappears. The timeout turns that lost-message moment into a stable pose instead of continued motion.

Before the check, consider whether the arm will keep moving or hold its pose after page messages stop.

  • Start a sustained shoulder_pan movement with its keyboard pair.
  • Find the keyboard pair assigned to shoulder_pan.
  • Press and hold one movement key from that pair.

You should see the arm begin turning in the live image.

  • Stop the page messages by leaving the operator page while the movement key is held.
  • Use the close control on the operator page's browser tab.
  • Wait at least 0.5 seconds.

The SO-101 simulation should stop changing pose. Claude Code's report should show that the controller entered the red hold-still state.

  • Return to the operator page at http://localhost:8000.
  • Enter http://localhost:8000 in the browser's address bar.

You should see the JPEG stream continue from the held pose. The status should return to green after the page reconnects.

You now have a control loop that stops the arm when its messages disappear.

Motion unstable?

Unstable motion can reveal a target or clamp problem. Keep the model's limits unchanged while you inspect the accepted values.

  • Ask Claude Code to expose the safety values with this prompt:
Show the model-derived clamp and current data.ctrl values without changing the limits.

The output lets you compare each applied target with the range read from the model.

Get help interpreting the control values.

Your arm now responds to safe targets and holds still when control messages stop. Next, you will measure the round-trip delay through that control loop.

Measure Round-Trip Delay

Your safe controls now move all six actuators. The next goal is to measure the delay between the operator page and the SO-101 simulation.

A working control loop still needs a round-trip measurement before you can compare its responsiveness with the Napa post's reported result below 40 ms.

In this step, get ready to:
  • Use Claude Code to add page-only RTT measurement and create latency.md.
  • Collect enough RTT samples for the Average RTT and Worst RTT readouts to settle.
  • Record the displayed values in the same computer row of latency.md.
Add page-only round-trip measurement

Using the operator page's own performance.now() values keeps the measurement on one clock. robot.py returns each timestamp unchanged so the page can calculate the complete trip.

  • Extend the current project by pasting this exact prompt into the Claude Code session for robot-teleop:
Add round-trip delay measurement without using the computer's wall clock. In operator.html only, send a JSON ping every 200 ms with a sent value from performance.now(). In robot.py, echo that sent value back immediately in a JSON pong. When the page receives the pong, calculate performance.now() minus the echoed sent value. Never compare a phone clock with a computer clock and never label this one-way latency.

Keep the latest 50 round-trip samples. Show a live readout with both Average RTT and Worst RTT in milliseconds. Color the readout green below 40 ms, orange from 40 ms to below 100 ms, and red at 100 ms or above. These colors are labels, not promises about the learner's network.

Create latency.md with exactly three data rows named same computer, home Wi-Fi, and mobile data, and columns for Network, Average RTT (ms), and Worst RTT (ms). Leave cells ready for the learner's measured values. Add a line beneath the table for which rows beat 40 ms. Keep all existing streaming, controls, limits, and timeout behavior. Run it and report that RTT changes over multiple pings.

What does this prompt do?

  • A JSON ping carries a page timestamp from performance.now() to robot.py every 200 ms.
  • The pong returns the original timestamp so the operator page can subtract it from a new performance.now() reading.
  • The latest 50 samples feed the Average RTT and Worst RTT readouts.
  • The new latency.md file holds the three-network comparison.

That measurement loop is now live: Claude Code reports changing RTT values over multiple pings. The operator page shows Average RTT and Worst RTT in milliseconds.

RTT Readout Stuck at Zero?

  • Ask Claude Code to trace the zero RTT readout with this prompt:
confirm that both the original timestamp and subtraction use performance.now() in operator.html, with robot.py only echoing the value unchanged.

This keeps both timing readings on the operator page. It also checks that robot.py returns the timestamp without replacing it.

Watch the RTT readout settle

The colors label the readings from this operator page. They do not predict results for home Wi-Fi or mobile data.

How the Thresholds Work

  • The readout is green below 40 ms.
  • The readout is orange from 40 ms to below 100 ms.
  • The readout is red at 100 ms or above.
  • Switch back to the browser tab showing the operator page from earlier.
  • Leave the operator page running until Average RTT and Worst RTT settle into your observed range.

You should see both values update in milliseconds. Worst RTT stays at least as large as Average RTT.

Record the same computer result

The latency.md table preserves the same measurement across three network paths. This step fills the same computer row while the other rows remain ready for later tests.

  • Record the displayed Average RTT as your same computer Average RTT.
  • Record the displayed Worst RTT as your same computer Worst RTT.

Before you update the file, consider whether the two future-network rows should still contain placeholders.

  • Update latency.md with your recorded values by sending this prompt to Claude Code:
Update only the `same computer` row in latency.md. Set Average RTT (ms) to [[SAME_COMPUTER_AVERAGE_RTT="your same computer Average RTT"]] and Worst RTT (ms) to [[SAME_COMPUTER_WORST_RTT="your same computer Worst RTT"]]. Keep the three row names, columns, Napa comparison line, and Rows that beat 40 ms line unchanged. Then show the full updated table.

What does this prompt do?

  • Claude Code replaces the two placeholders in the same computer row with the values you recorded.
  • The home Wi-Fi and mobile data rows stay ready for their later measurements.
  • The full table appears after the edit so you can confirm the row names and columns.

You now have your first measured baseline in the same computer row.

You should see exactly three rows: same computer, home Wi-Fi, and mobile data. A line beneath the table remains ready to list the rows that beat 40 ms.

Your same-computer baseline is recorded. Next, you will move the operator page onto your phone and measure the first real network path.

Control It on Home Wi-Fi

Your operator page already streams JPEG frames through WebSockets while preserving the model-derived limits and hold-still safety behavior.

Moving the operator page from your computer to your phone introduces the first real network path between the controls and the SO-101 simulation over home Wi-Fi.

In this step, get ready to:
  • Prepare robot.py and operator.html for private home Wi-Fi access.
  • Control elbow_flex from the phone's operator page.
  • Record the phone's round-trip measurements in latency.md.
Prepare the servers for phone access

The current localhost addresses keep both servers reachable from this computer only. Your phone needs those servers to accept connections through the computer's private local address.

  • Ask Claude Code to adapt the existing project for phone access by pasting this exact prompt:
Prepare the existing two-file project for a phone on the same private Wi-Fi. Change both the HTTP server on port 8000 and WebSocket server on port 8001 to listen on all local network interfaces. Print a local IPv4 HTTP link for this computer, such as http://192.168.1.20:8000, without hardcoding an address. In operator.html, build the WebSocket URL from location.hostname and port 8001 so localhost, the local IPv4 address, and the later Tailscale address all work.

Make operator.html fit a phone screen with a responsive 640x480 camera area, large sliders, a large gripper button, the status indicator, frame counter, and the unchanged Average RTT and Worst RTT readout. Keep the exact file names, joint names, model-derived clamps, 0.5-second hold-still timeout, and page-only performance.now() measurement. Do not add a public tunnel, router port forwarding, new framework, or new dependency. Run it and print the exact private-network link.

What does this prompt change?

  • Binding the HTTP server and WebSocket server to 0.0.0.0 lets them accept connections through the computer's available network interfaces.
  • Building the WebSocket address from location.hostname makes the page reuse the hostname from its current HTTP link.
  • Responsive sizing keeps the required camera view and controls usable on a phone screen.

Claude Code should preserve the stream, the six controls, the model-derived clamps, the hold-still timeout, and the page-only RTT calculation. It should report a private local IPv4 link after starting the updated project.

  • Record the private local IPv4 HTTP link printed by robot.py: http://192.168.1.20:8000.
Keep the network private

A firewall prompt can feel risky. This permission stays limited to the trusted private network you select.

  • Permit Python network access only for the current private home network if your computer displays a firewall prompt.
  • Choose the network scope that refers to your current trusted or private network.
  • Leave every public-network option disabled.
  • Confirm the limited permission.

If you granted permission, Python can now receive the phone's connection through the trusted home network. Public networks remain outside the permission.

  • Connect your owned phone to the same private home Wi-Fi as your computer.
  • Use the phone's Wi-Fi controls to select the same trusted home network as your computer.

Your phone and computer should now be using the same private home network.

  • Load the operator page on your phone at http://192.168.1.20:8000.
  • Tap the address bar in the browser already open on your phone.
  • Enter http://192.168.1.20:8000.
  • Load the address.

You should see the live SO-101 simulation, the six controls, the safety status, the frame counter, and the RTT readout on your phone. That is the first real network jump in your control loop.

Phone can't load the operator page?

  • Confirm that the phone and computer use the same non-guest private network.
  • Confirm that robot.py is still running with HTTP port 8000 and WebSocket port 8001.
  • Keep router port forwarding disabled while you review the private firewall permission.

Help me diagnose the private phone connection.

Control the arm and record home Wi-Fi RTT

The operator page now measures round-trip time across the home Wi-Fi path. Your own readings show how this network behaves without predicting anyone else's results.

Before you move elbow_flex, predict whether the phone's command will reach the simulation over home Wi-Fi.

  • Move elbow_flex a small distance from the phone's operator page.
  • Find the slider labelled elbow_flex.
  • Drag the slider a small distance.

You should see the elbow move in the live camera stream while the page continues receiving frames.

  • Leave the operator page connected until its latest RTT samples settle into your observed range.

You should see Average RTT and Worst RTT continue updating with measurements from the phone page.

  • Record the displayed Average RTT as your home Wi-Fi Average RTT in ms.
  • Record the displayed Worst RTT as your home Wi-Fi Worst RTT in ms.
  • Replace only the home Wi-Fi row in latency.md with your home Wi-Fi Average RTT in ms and your home Wi-Fi Worst RTT in ms.

You should see measured values in the home Wi-Fi row. The same computer measurements remain unchanged. The mobile data row remains ready for the next test.

Your phone now controls the simulation through your private home Wi-Fi. Next, you'll test the same loop after your phone leaves that network.

Control It Through Tailscale

Your phone already controls the SO-101 simulation across your private home Wi-Fi. The final network test moves that same control loop onto mobile data.

Home Wi-Fi keeps both devices on one local network. Tailscale carries the same private control loop when your phone switches to mobile data.

Your existing server addresses already support this route. This step connects only your owned devices without creating a public link or router forwarding rule.

In this step, get ready to:
  • Connect your computer and phone to a private tailnet.
  • Audit your existing project with Claude Code.
  • Test control over mobile data and complete your round-trip latency record.
Connect both devices to your tailnet

A tailnet keeps the route between your devices private. Use the same identity on both owned devices so they join the same network.

  • Choose the tab that matches your computer's current state.

✔️ Tailscale is already installed

Your existing installation is ready for the sign-in step below.

ⓧ Tailscale is not installed yet

  • Select your computer's operating system in the installation guide.
  • Follow the current installation steps shown for that platform.
  • Return to Tailscale on your computer after the installation finishes.

You should now have Tailscale available on your owned computer.

  • Create a personal tailnet with an identity you control on your computer.
  • Return to Tailscale on your computer.
  • Follow its sign-in flow with your chosen identity.

You should see your computer registered in your personal tailnet.

  • Set up Tailscale on your owned phone with the same installation guide.
  • Use the mobile-device section of the installation guide.
  • Install the Tailscale app on your phone with the steps for its operating system.

You should now have Tailscale available on your owned phone.

  • Sign in to Tailscale on your phone with the same identity used on your computer.
  • Return to Tailscale on your phone.
  • Follow its sign-in flow with the identity from your computer.

That is the private route in place. Your two owned devices should appear connected in the same tailnet.

Do the devices appear in different tailnets?

  • Confirm that both devices use the same sign-in identity.
  • Confirm that Tailscale remains connected on both devices.

Get help matching the two device sign-ins with this Tailscale setup question.

Audit the private route

Your existing files already listen on the addresses needed for private access. Claude Code checks that those settings remain intact and that no public exposure feature enters the project.

  • Send this exact audit prompt in Claude Code from your existing robot-teleop session:
Audit the existing robot.py and operator.html for use through Tailscale between my own computer and phone. Keep the HTTP server on 0.0.0.0 port 8000, the WebSocket server on 0.0.0.0 port 8001, and the page's WebSocket hostname derived from location.hostname. Do not add Tailscale Funnel, a public tunnel, authentication sharing, router port forwarding, or any dependency. Tell me to use the computer's Tailscale 100.x.y.z address as http://100.x.y.z:8000, and confirm that both ports remain private to my local firewall and tailnet. Then run the existing tests and report the exact command to start robot.py.

What does this prompt do?

  • The prompt checks that HTTP remains on 0.0.0.0 port 8000.
  • It checks that the WebSocket server remains on 0.0.0.0 port 8001.
  • It preserves location.hostname so the operator page follows whichever private hostname loaded it.
  • It excludes Tailscale Funnel, public tunnels, authentication sharing, and router port forwarding.

You should see Claude Code confirm the existing private bindings. It should also report the command that starts robot.py without adding dependencies or changing the two project files.

Test control over mobile data

The computer's stable Tailscale address follows the 100.x.y.z pattern. The operator page uses that same hostname when it creates its WebSocket connection.

  • Record the computer's private Tailscale address here: your computer's Tailscale 100.x.y.z address.
  • Return to Tailscale on your computer.
  • Select the entry for your owned computer.
  • Copy its private 100.x.y.z address into the field above.

Your recorded address should follow the 100.x.y.z pattern.

  • Turn off Wi-Fi on your owned phone.
  • Use your phone's quick network controls to disable Wi-Fi.

You should see mobile data remain active while Tailscale stays connected.

Before you load the link, do you think the operator page will reconnect while Wi-Fi is off?

  • Load the operator page on your phone by entering this private address:
http://[[TAILSCALE_IP="your computer's Tailscale 100.x.y.z address"]]:8000

What does this address do?

The address sends the phone's request to port 8000 on your computer through the tailnet. The page then uses the same private hostname with port 8001 for its WebSocket connection.

You should see the live JPEG stream and all six actuator controls on the phone while Wi-Fi remains off.

  • Move the gripper from the operator page.
  • Tap the Open / close gripper button below the six controls.

That is the private mobile-data loop working. Your phone can steer the arm without sharing a public link.

Does the page fail to load?

  • Confirm that Tailscale is connected on both owned devices.
  • Confirm that robot.py is still running in the terminal from earlier.
  • Keep the route private through your tailnet. Do not create a router forwarding rule or public link.

Work through the private connection checks with this troubleshooting question.

  • Wait for the operator page to collect enough samples for its Average RTT and Worst RTT values to settle into your observed range.

You should see both round-trip values continue to update from measurements made on the page.

Do the images feel slower than the RTT?

Control RTT measures the ping echo. JPEG encoding and frame delivery add separate work that can make the camera stream feel different.

Use this timing question to separate those measurements.

  • Enter the displayed mobile-data values in the mobile data row of latency.md.

You should see measured Average RTT and Worst RTT values in all three rows.

  • Replace the comparison placeholder with the names of only your measured rows that beat 40 ms.
  • Save latency.md.

Your completed file should contain exactly the same computer, home Wi-Fi, and mobile data rows. Its final line should identify which of your own results beat 40 ms.

Secret mission

Drive a real SO-101 arm

Take the private control loop from simulation to a calibrated real SO-101 follower. You will add a guarded real mode with a dry run, motion limits, direction checks, and physical safeguards.

Clean Up Your Resources

Clean Up Your Resources

Your local files have no ongoing cost. Tailscale Personal is free for personal use.

Decide whether to keep your resources running, pause them to come back later, or delete them entirely.

Resources you used:

  • The robot.py process that serves the operator page on ports 8000 and 8001.
  • The robot-teleop folder with its virtual environment, robot.py, operator.html, robotstudio_so101, snapshot.png, and completed latency.md.
  • Your owned computer and phone registered in your private tailnet.
  • The temporary Python firewall permission for private traffic on ports 8000 and 8001, if your computer created one.

Keep everything running

No action is needed. Choose this if you are still testing the SO-101 simulation or the optional calibrated real SO-101 follower.

  • Keep the robot-teleop folder with its simulation, operator page, model files, snapshot, and latency record.
  • Keep your owned computer and phone registered in your private tailnet.
  • Stop robot.py whenever you are not actively testing. The operator page remains offline until you restart the process.
  • Keep the Python firewall permission limited to private networks.

Pause - I'll come back to this later

Stop the running process to free its local resources. Disconnect Tailscale on both devices while keeping every project file for later.

  • Return to the terminal session inside robot-teleop.
  • Press Ctrl+C to stop the active robot.py or robot.py --real process.
  • Disconnect Tailscale on your computer.
  • Disconnect Tailscale on your phone.
  • Keep the robot-teleop folder unchanged.

The operator page is now offline. Your simulation, completed latency measurements, and private device registrations remain ready for your next session.

Delete - I don't want to use this again

Deleting the local folder is permanent. These steps target only robot-teleop and the access you created for this project.

  • Return to the terminal session inside robot-teleop.
  • Press Ctrl+C if robot.py or robot.py --real is still running.
  • Remove the robot-teleop folder with the instructions for your computer:

macOS

  • Leave robot-teleop and remove that folder by running these commands:
cd ..
rm -rf robot-teleop
What do these commands do?

The cd .. command moves the terminal into the directory containing robot-teleop.

The second command permanently deletes the named folder. Every local project file inside it is removed.

You should return to the parent directory without an error. The robot-teleop folder is no longer present.

Windows

  • Leave robot-teleop and remove that folder from PowerShell by running these commands:
cd ..
Remove-Item -Recurse -Force robot-teleop
What do these commands do?

The cd .. command moves PowerShell into the directory containing robot-teleop.

The second command permanently removes the named folder. Every local project file inside it is deleted.

You should return to the parent directory without an error. The robot-teleop folder is no longer present.

  • Return to the Tailscale admin console's device list for the tailnet from earlier.
  • Remove the computer registered for this project.
  • Remove the phone registered for this project.
  • Search your computer's firewall configuration for the temporary Python permission on private networks.
  • Remove the permission for ports 8000 and 8001.

Cleanup is complete. The operator page no longer runs from this computer.

Your personal tailnet can remain available without the two project device registrations. This project never created a public tunnel or router port-forwarding rule.

Nice Work!

Nice Work!

You made remote robot control work from end to end! Your phone now steers the SO-101 simulation through your private Tailscale tailnet.

What you learned:

  • Built an SO-101 simulation from robotstudio_so101/scene.xml with MuJoCo offscreen rendering. Streamed live JPEG frames to the operator page over WebSockets.
  • Controlled the exact six position actuators with model-derived clamps. Stopped runaway motion through a half-second dead-man timeout.
  • Measured round-trip delay with page-only timing across same computer, home Wi-Fi, and mobile data. Compared the completed latency.md readings with the Napa post's reported result under 40 ms. Proved private teleoperation over Tailscale with a phone screen recording taken while Wi-Fi was off and mobile data was on.
  • Secret Mission: Prepared optional real SO-101 control with LeRobot after official setup and calibration. Preserved model-derived clamps through use_degrees=True. Limited each move with a positive max_relative_target. Required the physical safety checklist before motor output.

Ready to quiz yourself?