微调手柄控制
Some checks failed
Quality / Style (push) Has been cancelled
Quality / Typos (push) Has been cancelled
Tests / Pytest (push) Has been cancelled
Tests / Pytest (minimal install) (push) Has been cancelled
Tests / End-to-end (push) Has been cancelled
Secret Leaks / trufflehog (push) Has been cancelled
Builds / CPU (push) Has been cancelled
Builds / GPU (push) Has been cancelled
Builds / GPU Dev (push) Has been cancelled
Nightly / CPU (push) Has been cancelled
Nightly / GPU (push) Has been cancelled

This commit is contained in:
2025-05-05 18:16:30 +08:00
parent ea9048b896
commit ba241c1f55
4 changed files with 162 additions and 7 deletions

View File

@@ -113,7 +113,9 @@ class PiperMotorsBus:
joint_5 = round(target_joint[5]*self.joint_factor)
gripper_range = round(target_joint[6]*1000*1000)
self.piper.MotionCtrl_2(0x01, 0x01, 100, 0x00) # joint control
self.piper.MotionCtrl_2(0x01, 0x01, 100, 0x00) # joint control # 0x00 标准模式
# self.piper.MotionCtrl_2(0x01, 0x01, 10, 0xAD) # joint control # mit模式
self.piper.JointCtrl(joint_0, joint_1, joint_2, joint_3, joint_4, joint_5)
self.piper.GripperCtrl(abs(gripper_range), 1000, 0x01, 0) # 单位 0.001°