Hold the lift at the bottom until the longer head camera cable is in
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
+3
-3
@@ -17,9 +17,9 @@ HEAD_REST_PITCH = PITCH_RANGE[0] # deg; the head's rest: its lowest, looking do
|
|||||||
# and near things are in view. Every "head back / ahead" uses it; yaw rests at 0
|
# and near things are in view. Every "head back / ahead" uses it; yaw rests at 0
|
||||||
VEL = 40 # speed ratio %, 1-100 (was 15: too slow to follow a visitor)
|
VEL = 40 # speed ratio %, 1-100 (was 15: too slow to follow a visitor)
|
||||||
ACC = 40 # acceleration ratio %, 1-100
|
ACC = 40 # acceleration ratio %, 1-100
|
||||||
# Temporary (2026-10-20): the head camera's cable is too short, a higher lift pulls it out. Back to 250 mm (what
|
# Temporary: the head camera's cable is too short, any lift above the bottom pulls it out, so the lift stays at 0 and
|
||||||
# tasks/fetch.py used before; the body API allows 300) when the longer cable is in.
|
# Lumi searches by driving and turning. Back to 250 mm (the body API allows 300) when the longer cable is in.
|
||||||
LIFT_MAX_MM = 105.0
|
LIFT_MAX_MM = 0.0
|
||||||
# [lift mm, waist, head yaw, head pitch] limits of the body API (docs/03), the lift held to LIFT_MAX_MM. The controller
|
# [lift mm, waist, head yaw, head pitch] limits of the body API (docs/03), the lift held to LIFT_MAX_MM. The controller
|
||||||
# drops a whole moveto when any value is outside, and its own encoders read a little past the ends (pitch -5.003 at
|
# drops a whole moveto when any value is outside, and its own encoders read a little past the ends (pitch -5.003 at
|
||||||
# the bottom stop).
|
# the bottom stop).
|
||||||
|
|||||||
+3
-3
@@ -79,8 +79,8 @@ SURFACE_Z = (-560.0, -30.0) # mm, arm frame, after the lift: table tops the arm
|
|||||||
# the grasp, 2026-10-16: -578 4 of 9 spots, -528 7 of 9, -28 9 of 9). Lower: a floor or a
|
# the grasp, 2026-10-16: -578 4 of 9 spots, -528 7 of 9, -28 9 of 9). Lower: a floor or a
|
||||||
# seat ~30 cm under a table, which no grasp reaches even at lift 0
|
# seat ~30 cm under a table, which no grasp reaches even at lift 0
|
||||||
LIFT_TOL_MM = 20.0 # closer than this: the lift stays
|
LIFT_TOL_MM = 20.0 # closer than this: the lift stays
|
||||||
LIFT_RANGE = (0.0, head.LIFT_MAX_MM) # mm; 0-105 for now (head camera cable, robot/head.py), 0-250 with the long one
|
LIFT_RANGE = (0.0, head.LIFT_MAX_MM) # mm; 0 only for now (head camera cable, robot/head.py), 0-250 with the long one
|
||||||
LIFT_DRIVE_MM = 75.0 # every drive, every task's end and a look that found nothing again at this lift
|
LIFT_DRIVE_MM = min(75.0, head.LIFT_MAX_MM) # every drive, every task's end and a look that found nothing again at this lift
|
||||||
# (higher, the near part of the table is below the torso camera's view)
|
# (higher, the near part of the table is below the torso camera's view)
|
||||||
LIFT_VEL = 20 # % of the lift's speed
|
LIFT_VEL = 20 # % of the lift's speed
|
||||||
VIEW_STEPS = (60.0, 120.0, 180.0) # search (_look_around): both cameras look this far (deg from the front) to one
|
VIEW_STEPS = (60.0, 120.0, 180.0) # search (_look_around): both cameras look this far (deg from the front) to one
|
||||||
@@ -770,7 +770,7 @@ def _look_around(attempt, holding=False, say=None):
|
|||||||
sides = [s * v for s in (side, -side) for v in VIEW_STEPS] if arm_yaw() is not None or _head_ok() else []
|
sides = [s * v for s in (side, -side) for v in VIEW_STEPS] if arm_yaw() is not None or _head_ok() else []
|
||||||
here = head.status()[0]
|
here = head.status()[0]
|
||||||
other = LIFT_TRIES[1] if here < sum(LIFT_TRIES) / 2 else LIFT_TRIES[0]
|
other = LIFT_TRIES[1] if here < sum(LIFT_TRIES) / 2 else LIFT_TRIES[0]
|
||||||
for n, lift in enumerate((None, other)):
|
for n, lift in enumerate((None, other) if abs(other - here) >= 1.0 else (None,)): # no other lift: one pass
|
||||||
if lift is not None:
|
if lift is not None:
|
||||||
_lift_to(lift)
|
_lift_to(lift)
|
||||||
for turned in (False, True):
|
for turned in (False, True):
|
||||||
|
|||||||
@@ -8,6 +8,9 @@ from pathlib import Path
|
|||||||
|
|
||||||
import numpy as np
|
import numpy as np
|
||||||
|
|
||||||
|
from robot import head
|
||||||
|
assert head.LIFT_MAX_MM == 0.0 # live: the lift stays at the bottom (head camera cable); the cases below are the long cable's
|
||||||
|
head.LIFT_MAX_MM, head.AXIS_LIMITS = 105.0, ((0.0, 105.0),) + head.AXIS_LIMITS[1:]
|
||||||
from manipulation import skills
|
from manipulation import skills
|
||||||
from tasks import fetch
|
from tasks import fetch
|
||||||
from vision import calib
|
from vision import calib
|
||||||
|
|||||||
Reference in New Issue
Block a user