Claude Code taught a Roborock to escape from under the stairs, 10/10 success

fillyourcoffee · reddit · 2026-10-24

A user's Roborock lived under the stairs in a gap only a few cm wider than the robot, requiring manual rescue before every clean. Over one evening, he used Claude Code — acting mostly as the eyes while Claude wrote code, read robot logs, and ran tests — to build an escape routine.

Key discoveries: the robot has undocumented remote-control commands (found by trial and error); moves in the first 5 seconds of remote control are silently ignored; it does its own 180° turn after leaving the dock; and its map position updates live, so the script can measure after each move. The first "dodge right" strategy crashed into the stair post — position readings wobble by about the gap's width, so no fixed path works. The final approach backs off a few cm when blocked and tries other angles, nearest first, on both sides: 10/10 successful escapes in testing. Runs on a Raspberry Pi with Home Assistant bridged to Google Home.

Original post →

More from coding & agent

coding & agent channel →