feat(piper): require calibration by default with opt-out mode

- set piper calibration_mode default to required and keep off as explicit opt-out

- remove auto pairing policy and simplify runtime calibration gating

- update README and add test for uncalibrated control when calibration_mode=off
这个提交包含在:
Elvin
2026-03-05 21:49:39 +08:00
父节点 7a9aeb3850
当前提交 294a370657
共有 7 个文件被更改,包括 85 次插入 和 10 次删除

查看文件

@ -268,3 +268,21 @@ def test_piper_follower_connect_rolls_back_connected_cameras(monkeypatch):
assert cam_ok.disconnect_calls == 1
assert not cam_ok.is_connected
assert not robot.is_connected
def test_piper_calibration_mode_off_allows_uncalibrated_control(monkeypatch):
patch_fake_sdk(monkeypatch)
teleop = PiperLeader(PiperLeaderConfig(port="can1", calibration_mode="off"))
robot = PiperFollower(PiperFollowerConfig(port="can0", calibration_mode="off"))
teleop.connect(calibrate=False)
robot.connect(calibrate=False)
try:
action = teleop.get_action()
sent = robot.send_action(action)
assert sent["joint_1.pos"] == 10.0
assert sent["gripper.pos"] == 42.0
finally:
teleop.disconnect()
robot.disconnect()