Home› Programming
Discussion
Back to discussions page
PierreOlivier_Proulx
Beta Tester VIsion 1.1 Program, Vacuum Beta tester Posts: 69 Handy
How to port a UR program made with the old package to the new URCaps |
245 views
|
Answered | |
/ Most recent by Catherine_Bernier
in Programming
|
1 comment |

If you made programs with the old gripper and sensor packages, you can still use them with the new URCaps. Here is how to do it.
First, for the gripper, you can open your urp program in Polyscope and try executing it. You should see an error message that tells you that some functions is defined twice.
This is because the urcap embeds the functions directly in the program preamble so we do not need the BeforeStart section anymore. Comment those lines as in the next screenshot and try to run the program. You will still get this error.

This error arises because we changed some functions names because of a naming conflict with the sensor package. To solve the problem you can either suppress those functions or rename them. Since they are probably not used in a production program, the fastest would be to suppress them.


Here is the list of the functions that were renamed:
Regarding the sensor programs, you should be able to run it directly without modifications as we decided to keep the old template in order to retrieve the force/torque values.
First, for the gripper, you can open your urp program in Polyscope and try executing it. You should see an error message that tells you that some functions is defined twice.
This is because the urcap embeds the functions directly in the program preamble so we do not need the BeforeStart section anymore. Comment those lines as in the next screenshot and try to run the program. You will still get this error.

This error arises because we changed some functions names because of a naming conflict with the sensor package. To solve the problem you can either suppress those functions or rename them. Since they are probably not used in a production program, the fastest would be to suppress them.


Here is the list of the functions that were renamed:
- rq_print_fault_code -> rq_print_gripper_fault_code
- rq_print_num_cycles -> rq_print_gripper_num_cycles
- rq_print_driver_state -> rq_print_gripper_driver_state
- rq_print_firmware_version -> rq_print_gripper_firmware_version
- rq_print_driver_version -> rq_print_gripper_driver_version
- rq_print_probleme_connection -> rq_print_gripper_probleme_connection
Regarding the sensor programs, you should be able to run it directly without modifications as we decided to keep the old template in order to retrieve the force/torque values.
Tagged:
Then, you can delete and replace your gripper command for the move, position, speed and force by the "Gripper" node from the URcaps.
Let me know how it goes!
[email protected]
https://www.linkedin.com/in/catherinebernier