Mesh¶
Zenoh on the LAN, a Zenoh router across networks. Presence, state, correlated RPC, and one fleet e-stop.
Terminal one, a peer per robot:
python3 -m pip install "strands-robots[sim,mesh]"
strands-robots serve so101 --mode sim --peer-id arm-b
Terminal two, another peer that asks it:
from strands_robots import Robot
from strands_robots.mesh import Mesh
with Robot("so101", mode="sim") as arm, Mesh(arm, "arm-a") as mesh:
reply = mesh.ask("arm-b", "observe", timeout_s=2.0) # the remote result, or its refusal raised here
print(reply["joints"])
peers = mesh.peers # peer_id -> Peer(is_connected, state, ...); presence lands within 1 s
mesh.estop.emergency_stop("operator: person in the cell")
| key | carries |
|---|---|
strands/<ns>/<peer>/presence |
who is here |
strands/<ns>/<peer>/state |
joints at the robot's control rate |
strands/<ns>/<peer>/rpc/req rpc/rep |
correlated verbs |
strands/<ns>/<peer>/safety |
e-stop and resume |
Inbound act passes the per-robot allowlist, bounds, signature and replay window before it
reaches robot.act. STRANDS_MESH_BACKEND=loopback runs two peers in one process with no
zenoh. Every e-stop is appended to ~/.strands_robots/mesh_audit.jsonl. Knobs:
configuration.