Skip to content

Commit

Permalink
Fix missing joint_position_action in path
Browse files Browse the repository at this point in the history
  • Loading branch information
eugeneteoh committed Apr 10, 2024
1 parent 076ca15 commit e42cd73
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pyrep/robots/configuration_paths/arm_configuration_path.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,8 @@ def _step_motion(self) -> int:
if state >= 0:
pos = posVelAccel[0]
for i in range(len(lengths) - 1):
if lengths[i] <= pos <= lengths[i + 1]:
# Always execute the last point as pos might overshoot
if lengths[i] <= pos <= lengths[i + 1] or i == len(lengths) - 2:
t = (pos - lengths[i]) / (lengths[i + 1] - lengths[i])
# For each joint
offset = len(self._arm.joints) * i
Expand Down

0 comments on commit e42cd73

Please sign in to comment.