Giter Club home page Giter Club logo

Comments (5)

Tejas-Shastha avatar Tejas-Shastha commented on August 17, 2024 1

Whereas I could not solve this problem in Moveit itself, I found a simple enough workaround through testing with the robot. Narrowing the joint position limit windows by ~7% seems to work for the sequence of poses I test against.

Maybe MoveIt prepares position inside the limits, but the JTC making it go out of limits.

I think this makes the most sense, since it has been acknowledged that ros2_control does not yet respect joint limits. So I would reason out that the default planner OMPL/RRT prepares the trajectory with IK solutions that respect joint limits, but when the controller ros2_control/JTC tries to follow this trajectory, it sometimes arrives at different IK solutions that are unaware of joint limits.

In any case, since I am fairly certain that this is not a problem on the Franka side, I will close this issue.

@BarisYazici Thank you for the support!!

from franka_ros2.

BarisYazici avatar BarisYazici commented on August 17, 2024

I also noticed the limit parameters not processed by moveit. Is there sth we can do to fix? Or is it something moveit related?

from franka_ros2.

Tejas-Shastha avatar Tejas-Shastha commented on August 17, 2024

So I poked around a bit and decided to pass the joint limits expressly through a YAML file based on franka_ros values, and indeed moveit now picks them up correctly:

robot_description_planning:
      joint_limits:
        panda_joint1:
          has_acceleration_limits: true
          has_effort_limits: true
          has_jerk_limits: null
          has_position_limits: true
          has_velocity_limits: true
          max_acceleration: 3.75
          max_effort: 87
          max_position: 2.8973
          max_velocity: 2.175
          min_position: -2.8973
        panda_joint2:
          has_acceleration_limits: true
          has_effort_limits: true
          has_jerk_limits: null
          has_position_limits: true
          has_velocity_limits: true
          max_acceleration: 1.875
          max_effort: 87
          max_position: 1.7628
          max_velocity: 2.175
          min_position: -1.7628
        panda_joint3:
          has_acceleration_limits: true
          has_effort_limits: true
          has_jerk_limits: null
          has_position_limits: true
          has_velocity_limits: true
          max_acceleration: 2.5
          max_effort: 87
          max_position: 2.8973
          max_velocity: 2.175
          min_position: -2.8973
        panda_joint4:
          has_acceleration_limits: true
          has_effort_limits: true
          has_jerk_limits: null
          has_position_limits: true
          has_velocity_limits: true
          max_acceleration: 3.125
          max_effort: 12
          max_position: 2.8973
          max_velocity: 2.61
          min_position: -2.8973
        panda_joint5:
          has_acceleration_limits: true
          has_effort_limits: true
          has_jerk_limits: null
          has_position_limits: true
          has_velocity_limits: true
          max_acceleration: 3.75
          max_effort: 12
          max_position: 1.7628
          max_velocity: 2.61
          min_position: -1.7628
        panda_joint6:
          has_acceleration_limits: true
          has_effort_limits: true
          has_jerk_limits: null
          has_position_limits: true
          has_velocity_limits: true
          max_acceleration: 5.0
          max_effort: 12
          max_position: 3.7525
          max_velocity: 2.61
          min_position: -0.0175
        panda_joint7:
          has_acceleration_limits: true
          has_effort_limits: true
          has_jerk_limits: null
          has_position_limits: true
          has_velocity_limits: true
          max_acceleration: 5.0
          max_effort: 12
          max_position: 2.8973
          max_velocity: 2.61
          min_position: -2.8973

However, this does not solve my problem and I still run into the reflex state with joint limits exceeded :( . The last time this happened, the joint values looked like this:

name:
- panda_joint1
- panda_joint2
- panda_joint3
- panda_joint4
- panda_joint6
- panda_joint7
- panda_joint5
position:
- -0.5846188414192806
- 0.5743862018374197
- -0.9308654554855968
- -0.0807863111203012
- 1.0447302227815072
- -0.03548325803408056
- -0.9017913305650664
velocity:
- 0.0005321018174672895
- -0.0004305121441906692
- 0.00015391332496071937
- -0.0004063499873393697
- -0.0002132338215014766
- -0.0019501103657266297
- 7.913850579020568e-05
effort:
- 0.17199018597602844
- -30.422439575195312
- -3.2222132682800293
- 5.280417442321777
- 1.5263864994049072
- 0.08953773230314255
- -1.359389066696167

From this I can surmise that the offending joint is panda_joint6: Actual value -0.03548325803408056, permitted range: (-0.0175, 3.7525). I also dug through the runtime environment and robot model->joint model group->get varibale bounds does indeed reflect these limits being properly set. So it seems like moveit planned a joint space trajectory that violated the limits.

I will try to look into this problem a bit more or post an issue in the moveit2 repo, but of course I would welcome any suggestions in this thread as well!!

from franka_ros2.

BarisYazici avatar BarisYazici commented on August 17, 2024

It might also worth looking at JTC. Maybe MoveIt prepares position inside the limits, but the JTC making it go out of limits. We recently added the old patched JTC to the repo. It might worth trying with that.

from franka_ros2.

Tejas-Shastha avatar Tejas-Shastha commented on August 17, 2024

It might also worth looking at JTC. Maybe MoveIt prepares position inside the limits, but the JTC making it go out of limits. We recently added the old patched JTC to the repo. It might worth trying with that.

Unfortunately, we are using the FER1 robot with ROS2, so I am restricted to using libfranka v0.9.2 and and this repo at version v0.1.0. So I cannot try out the juicy new features being released :( .

from franka_ros2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.