Skip to content

Commit 1d16f11

Browse files
authored
Do not need to execute planned trajectories on real robot. (#105)
1 parent ce583f8 commit 1d16f11

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

tutorials/pick_and_place/ROS/src/niryo_moveit/scripts/mover.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def plan_trajectory(move_group, destination_pose, start_joint_angles):
4343
move_group.set_start_state(moveit_robot_state)
4444

4545
move_group.set_pose_target(destination_pose)
46-
plan = move_group.go(wait=True)
46+
plan = move_group.plan()
4747

4848
if not plan:
4949
exception_str = """
@@ -52,7 +52,7 @@ def plan_trajectory(move_group, destination_pose, start_joint_angles):
5252
""".format(destination_pose, destination_pose)
5353
raise Exception(exception_str)
5454

55-
return planCompat(move_group.plan())
55+
return planCompat(plan)
5656

5757

5858
"""

tutorials/pick_and_place/Scripts/TrajectoryPlanner.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ public void PublishJoints()
129129

130130
void TrajectoryResponse(MoverServiceResponse response)
131131
{
132-
if (response.trajectories != null)
132+
if (response.trajectories.Length > 0)
133133
{
134134
Debug.Log("Trajectory returned.");
135135
StartCoroutine(ExecuteTrajectories(response));

0 commit comments

Comments
 (0)