HomeLearnCoursesHackathonsAccount
Behavior Trees for Robot Control
Designing a Fetch Behavior · 1/2

Breaking a fetch task into a tree

Consider a robot tasked with fetching an object: navigate to its expected location, detect it, grasp it, and retreat to a drop-off point. The natural top-level structure is a Sequence: Navigate, then Detect, then Grasp, then Retreat, because each step genuinely depends on the previous one succeeding. If navigation fails outright, there's no point attempting to detect anything.

But real robots don't get everything right on the first try, so individual steps deserve their own fallback logic rather than failing the whole Sequence immediately. Wrapping the Detect step in a Selector that first tries looking from the current position and, if that fails, tries repositioning slightly and looking again, captures a realistic retry strategy without complicating the top-level Sequence at all. The complexity stays local to the step that needs it.