Skip to content

Commit

Permalink
Have a higher timeout for the first trajectory point while the robot …
Browse files Browse the repository at this point in the history
…isn't moving yet.
  • Loading branch information
fmauch committed Sep 6, 2024
1 parent 281c797 commit 99208e5
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion resources/external_control.urscript
Original file line number Diff line number Diff line change
Expand Up @@ -439,8 +439,12 @@ thread trajectoryThread():
enter_critical
trajectory_result = TRAJECTORY_RESULT_SUCCESS
while trajectory_result == TRAJECTORY_RESULT_SUCCESS and trajectory_points_left > 0:
local timeout = get_steptime()
if is_first_point:
timeout = 0.5
end
#reading trajectory point + blend radius + type of point (cartesian/joint based)
local raw_point = socket_read_binary_integer(TRAJECTORY_DATA_DIMENSION+1+1, "trajectory_socket", 0.2)
local raw_point = socket_read_binary_integer(TRAJECTORY_DATA_DIMENSION+1+1, "trajectory_socket", timeout)
trajectory_points_left = trajectory_points_left - 1

if raw_point[0] > 0:
Expand Down

0 comments on commit 99208e5

Please sign in to comment.