Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to update current joints in read function when disabling controller and use writeKeepalive #628

Closed
shuobh opened this issue Apr 7, 2023 · 0 comments

Comments

@shuobh
Copy link

shuobh commented Apr 7, 2023

Summary

When the robot is not in active write state which call writeKeepalive in write function, the read function will not update the robot to current robot joint state.

Versions

  • ROS Driver version: 2.1.2
  • Affected Robot Software Version(s): 5.13
  • Affected Robot Hardware Version(s): ur3e
  • URCaps Software version(s): 1.0.5

Impact

Blocker to integrate with new URCL freedrive function

Issue details

I've been testing to integrate with UniversalRobots/Universal_Robots_Client_Library#138 to switch to freedrive mode using the built in functionality. It works by adding a in_freedrive_ flag which calls ur_driver_->writeKeepalive() instead of writing cmds in the drivers write function.

However, during freedrive, it does not update to current joint angles in the read function which causes the robot to suddenly swing back to the joint state before freedrive enabled.

I've tried to manually call a read before switching back from freedrive but it results the same.

Use Case and Setup

Integrating with UniversalRobots/Universal_Robots_Client_Library#138 freedrive (with modifications on URCL and This driver).

Expected Behavior

read function will return current joint state and when we reenable write using position_controller joint_position_command_ will reflect current joint state.

Work Around

Set controller_reset_necessary_ = true to update.

@shuobh shuobh changed the title Failed to get update current joints in read function Failed to get update current joints in read function when disabling controller and use writeKeepalive Apr 7, 2023
@shuobh shuobh changed the title Failed to get update current joints in read function when disabling controller and use writeKeepalive Failed to update current joints in read function when disabling controller and use writeKeepalive Apr 7, 2023
@shuobh shuobh closed this as completed Apr 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant