Skip to content

Commit

Permalink
Fix missing joint_position_action in path (#371)
Browse files Browse the repository at this point in the history
* Fix missing joint_position_action in path

* Fix test
  • Loading branch information
eugeneteoh authored Apr 10, 2024
1 parent 076ca15 commit cd9830b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
# start xvfb in the background
sudo /usr/bin/Xvfb $DISPLAY -screen 0 1280x1024x24 &
cur=`pwd`
wget http://www.coppeliarobotics.com/files/CoppeliaSim_Edu_V4_1_0_Ubuntu20_04.tar.xz
wget https://downloads.coppeliarobotics.com/V4_1_0/CoppeliaSim_Edu_V4_1_0_Ubuntu20_04.tar.xz
tar -xf CoppeliaSim_Edu_V4_1_0_Ubuntu20_04.tar.xz
export COPPELIASIM_ROOT="$cur/CoppeliaSim_Edu_V4_1_0_Ubuntu20_04"
echo $COPPELIASIM_ROOT
Expand Down
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 cd9830b

Please sign in to comment.