However, to be honest with you, your question coincidentally occurs at the same time I'm actually trying to help another customer trying to do the exact same thing as you. I cannot give any guarantee right now that this will work (or be easy) since it's the first time I'm trying to solve this, but I feel what you are trying to do should be feasible using socat relays. if you are willing to give this a try, you could start by trying the following:
2. Still on your ROS machine, run: "chmod 777 /dev/ttyUSB0" to provide the symbolic link read and write permissions
6. Then, back on your ROS machine: rosrun robotiq_2f_gripper_control Robotiq2FGripperRtuNode.py /dev/ttyUSB0 which hopefully will run with no errors (only a warning). You should now also see the gripper's led color switch from red to blue.
7. On your ROS machine, you can now try running the simple controller script: rosrun robotiq_2f_gripper_control Robotiq2FGripperSimpleController.py to interact with the gripper.
This command should output only one line, confirming that the port "54321" is indeed opened and listening. If you are able to see the gripper's led switching from red to blue at step #6 above, this is a very good sign (i.e. communication is working). However, chances are you could still suffer from latency issues afterwards too. If you reach that point however, I will most likely be able to provide a patch for you to make it work.
I know this is a lot of information and I would still recommend to connect your gripper directly to your ROS machine if possible. Doing so, you will most probably avoid a lot of potential troubles. However, if it is impossible for you to do so, I'll be happy to assist you the best I can, however without any guarantee unfortunately I'm afraid.
Please don't hesitate to write back to me, should you have any other questions or concerns.
@jproberge I sucessfully ran `Robotiq2FGripperRtuNode.py` and `Robotiq2FGripperSimpleController.py` following your instructions which is extremely detailed, thanks so much!! I'm using a AUBO i5 robot instead UR robot. At first `rosrun robotiq_2f_gripper_control Robotiq2FGripperRtuNode.py /dev/ttyUSB0` gave me an Attribute Error:
xxwang@MS-7A54:~/ROS_Workspaces/ros_k4a_auboi5_ws$ rosrun robotiq_2f_gripper_control Robotiq2FGripperRtuNode.py /dev/ttyUSB0
Traceback (most recent call last):
File "/home/xxwang/ROS_Workspaces/ros_k4a_auboi5_ws/src/robotiq/robotiq_2f_gripper_control/nodes/Robotiq2FGripperRtuNode.py", line 89, in <module>
mainLoop(sys.argv[1])
File "/home/xxwang/ROS_Workspaces/ros_k4a_auboi5_ws/src/robotiq/robotiq_2f_gripper_control/nodes/Robotiq2FGripperRtuNode.py", line 75, in mainLoop
status = gripper.getStatus()
File "/home/xxwang/ROS_Workspaces/ros_k4a_auboi5_ws/src/robotiq/robotiq_2f_gripper_control/src/robotiq_2f_gripper_control/baseRobotiq2FGripper.py", line 107, in getStatus
status = self.client.getStatus(6);
File "/home/xxwang/ROS_Workspaces/ros_k4a_auboi5_ws/src/robotiq/robotiq_modbus_rtu/src/robotiq_modbus_rtu/comModbusRtu.py", line 95, in getStatus
output.append((response.getRegister(i) & 0xFF00) >> 8)
AttributeError: 'ModbusIOException' object has no attribute 'getRegister'
Then I found I'm not the only one running into this trouble, plenty of users reported the same or similar issues on github, and I found no general solution to this. I reckoned then this `getRegister` error is quite obscure, and it can be due to a bunch of more specific errors. I tried every method [previously mentioned](https://github.com/ros-industrial/robotiq/issues/167) but none did resolve this issue. I finally found the true error for me is that the gripper not being 'connected' with the AUBO Robot (controller) —— 'connect' button inside gripper plugin must be pressed on Robot teach pendant before running `Robotiq2FGripperRtuNode.py`.
Above is my feedback and a little supplementary, and thank you for your suggestions!
Hi @lmmartiner,
Unfortunately, ROS is no longer officially supported by Robotiq.
However, you can still find the ROS packages here: https://github.com/ros-industrial/robotiq
Depending on which product, you might also be able to find some useful information in the following posts:
https://dof.robotiq.com/discussion/comment/6353#Comment_6353
Best regards,