Comments (8)
Why would you come to the assumption, that control commands are only sent with 50 Hz?
from universal_robots_externalcontrol_urcap.
I am using a custom IK solution to generate trajectory commands like these:
---
header:
seq: 191
stamp:
secs: 1639835958
nsecs: 765319108
frame_id: ''
goal_id:
stamp:
secs: 1639835958
nsecs: 765327930
id: "/move_group-4-1639835958.765319108"
goal:
trajectory:
header:
seq: 0
stamp:
secs: 0
nsecs: 0
frame_id: "world"
joint_names: [shoulder_pan_joint, shoulder_lift_joint, elbow_joint, wrist_1_joint, wrist_2_joint,
wrist_3_joint]
points:
-
positions: [7.374982670751816e-05, -1.3939911525172393, 1.4019192847185409, -0.005670634384257868, 0.35640352556791954, 0.0031893071445614055]
velocities: [7.006015059003896e-07, 1.975990426839047e-06, -8.795930761529291e-07, -1.360765239637879e-07, 6.620829717807197e-08, -6.75472778405295e-08]
accelerations: [0.0, 0.0, 0.0, 0.0, 0.0, 0.0]
effort: []
time_from_start:
secs: 0
nsecs: 20000000
path_tolerance: []
goal_tolerance: []
goal_time_tolerance:
secs: 0
nsecs: 0
---
These commands are then published to the ROS topic /scaled_pos_joint_traj_controller/follow_joint_trajectory/goal
using a custom publisher publishing at 50Hz
from universal_robots_externalcontrol_urcap.
We are using the driver file ur5e_bringup.launch from the repository for establishing the connection to the URCap externalcontrol-1.0.5.urcap.
The Figure 1 below shows the update of /scaled_pos_joint_traj_controller/follow_joint_trajectory/goal.goal.trajectory.points[0].positions[4]
and /scaled_pos_joint_traj_controller/follow_joint_trajectory/goal.goal.trajectory.points[0].velocities[4]
from the trajectory command generated using our custom IK scripts to node /ur_hardware_interface
Figure 1 : Joint 4 Position and Velocity Graph
from universal_robots_externalcontrol_urcap.
This is the result from the UR Log Viewer. This there a way to make the Velocity, acceleration and currents smoother. The Joint Position as shown in the result is smooth.
from universal_robots_externalcontrol_urcap.
Velocity and Position command for the Joint 0 sent from our package to /ur_hardware_interface
for a sine wave motion recorded using rosbag :
from universal_robots_externalcontrol_urcap.
@fmauch
It looks there is obvious added velocity noise from the 'ur_hardware_interface', when it outputs to the robot.
Despite the command input to the 'ur_hardware_interface' was smooth.
Also adjusting the value in the PID gains or velocity_ff in https://github.com/UniversalRobots/Universal_Robots_ROS_Driver/blob/master/ur_robot_driver/config/ur5e_controllers.yaml made no observable difference in performance.
from universal_robots_externalcontrol_urcap.
You are using the scaled trajectory controller to interface the robot. This controller is generating trajectories based on the input given. In the example above, a trajectory with one setpoint is given. The Setpoint should be reached in 20 ms. The controller now creates a trajectory from the current configuration to the target configuration using a spline interpolation (This is basically, how the joint trajectory controller works). This generated motion is then sampled by the hardware interface (through the controller implementation) in each control cycle (with 500Hz) to generate commands sent to the robot.
Thus, the robot is not "simply going there".
The "noise" mentioned in #26 (comment) comes from the fact, that a servoj
command is used to execute the commands. The actual behavior of this servoj
command can be altered by changing the values for servoj_gain
and servoj_lookahead_time
.
For real smooth velocities, a velocity-based controller such as the scaled_vel_joint_traj_controller
could be used. Please see the controller documentation for details on the available controllers.
from universal_robots_externalcontrol_urcap.
Thank you for the information. @fmauch
We have tested that reducing the servoj_gain
reduces the jitters significantly. It seems putting it to 100 (minimal) instead of 2000 (default also maximum) gives the best smoothness in simulation.
Hopefully it will not compromise too much on the control precision?
from universal_robots_externalcontrol_urcap.
Related Issues (15)
- Check for issues with a blocked remote port HOT 2
- Build with SDK version 1.10.0 HOT 1
- Screendump
- Simple test server HOT 3
- Cannot run URCap program within a UR5 due to `Play` button is disabled HOT 2
- not able to open socket reverse_socket to host 172. ... at port 50001 in WSL2 HOT 6
- Suggestion: Inject the remote's IP address into the script code
- External Control doesn't work on Macbook HOT 3
- UR20 support? HOT 4
- Cannot get the USB recognized properly by the teaching pendant HOT 1
- "Connection Refused" after normal setup, when pressing "play" on a UR5 teach pendant HOT 9
- Source code not up2date? HOT 4
- Multiple instances of node in ur program not possible HOT 26
- Connecting to a machine with an active firewall blocks for a long time HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from universal_robots_externalcontrol_urcap.