mirror of
https://github.com/dptech-corp/Uni-Lab-OS.git
synced 2026-02-06 06:25:06 +00:00
Update moveit_interface.py
This commit is contained in:
@@ -239,8 +239,15 @@ class MoveitInterface:
|
|||||||
)
|
)
|
||||||
|
|
||||||
if "lift_height" in cmd_dict.keys():
|
if "lift_height" in cmd_dict.keys():
|
||||||
|
retval = None
|
||||||
retval = self.moveit2[cmd_dict["move_group"]].compute_fk(joint_positions_)
|
retry = config.get("retry", 10)
|
||||||
|
while retval is None and retry > 0:
|
||||||
|
retval = self.moveit2[cmd_dict["move_group"]].compute_fk(joint_positions_)
|
||||||
|
time.sleep(0.1)
|
||||||
|
retry -= 1
|
||||||
|
if retval is None:
|
||||||
|
result.success = False
|
||||||
|
return result
|
||||||
pose = [retval.pose.position.x, retval.pose.position.y, retval.pose.position.z]
|
pose = [retval.pose.position.x, retval.pose.position.y, retval.pose.position.z]
|
||||||
quaternion = [
|
quaternion = [
|
||||||
retval.pose.orientation.x,
|
retval.pose.orientation.x,
|
||||||
|
|||||||
Reference in New Issue
Block a user