ros-industrial / robotiq

Robotiq packages (http://wiki.ros.org/robotiq)
BSD 2-Clause "Simplified" License
228 stars 378 forks source link

Feedback of gripper position #178

Open Krause92 opened 3 years ago

Krause92 commented 3 years ago

Hi,

I'm working with the 2f_gripper_action_server. In the Feedback message there is an apparently incorrect calculation of the gripper finger's position:

https://github.com/ros-industrial/robotiq/blob/66961ec6b6c9c493f13410d16ce32cea1648babf/robotiq_2f_gripper_action_server/src/robotiq_2f_gripper_action_server.cpp#L66

if the gripper is fully opened input.gPO is zero. If it is fully closed we got 255. (see https://assets.robotiq.com/website-assets/support_documents/document/2F-85_2F-140_Instruction_Manual_CB-Series_PDF_20190329.pdf on page 53).

This implies result.position = params.max_gap_ - input.gPO * dist_per_tick; for the resulting gipper finger positon.