Articles Download Safety & Security Forum myUR Go to Main Site

Universal Robots A/S
Energivej 51
DK-5260 Odense S

T: +45 8993 8989
sales@universal-robots.com

 
  • Articles
  • Download
  • Safety & Security
  • Forum
  • myUR
  • Go to Main Site
  • Support
  • Articles
  • Switch between different TCP in a program

Switch between different TCP in a program

This is an example of how to switch between different TCP’s using the GUI interface.

Last modified on Jan 29, 2025

Examples are valid for:

First example is only valid from CB3 with software 3.1 and forward. Also valid for e-Series, all software versions.

Second example is valid for both CB2 and CB3, all software versions

 

  • Multiple TCP’s can be designated in both the Initialize window upon start up, and in the installation file and the “TCP Configuration” tab.
  • The position and orientation can be set for each of the different TCP’s created, but the payload and center of gravity must be set/changed throughout the program itself.

 Tcp Cog

First example (Valid for CB3 with minimum 3.1 software)

While making a program using the structure editor, whenever a change in TCP is required, one can use the “Set” command. In this window you can select the TCP desired (which was previously created in the notes above).

Also in this window you set the total payload in kg, this value consists of both the end effector weight, as well as the object that is picked up during that portion of the program.

If the CoG is shifted much when picking up the object, it’s recommended to use the script function set_payload(m,CoG). Read more about this function in the script manual. The script manual can be downloaded in the download section.

set_payload(m, CoG)

  • m = mass in kilogram
  • CoG = Center of Gravity (CoGx, CoGy, CoGz) in meters

This total payload, in the “Set” command, must be implemented during and after an object is picked so that an accurate payload is communicated to the robot at all times.

The below two examples has a default TCP with a set position, orientation, and a weight of 1kg

This example shows the new overall payload of 2kg since it now is gripping the 1kg load. Shows the payload being set back to 1kg
Set Tcp 1And2

This example shows the change from “TCP” to “TCP_1” and back again. It also shows the payload to being set to 2kg and back to 1kg again.
Set Tcp 3And4

 When changing TCP’s with different X,Y,Z it’s important to tick the Recalculate in the Move command where the TCP is change. Otherwise the new TCP is not taken into account doing its trajectory.
Recal

The function "Set TCP" in the Move tap(below the "Recalculate motions") can be read about in the user manual. User manual can be downloaded in the download section or on our may website.

Second example (Valid for CB2 and CB3, all software versions)

By default it is only possible to setup one TCP in the Installation-tab.
However by using the script code set_tcp() it is possible to change the TCP on the fly.
set_tcp() requires a pose p[x,y,z,rx,ry,rz] as parameter

NOTE: When changing TCP on the fly using set_tcp(), only variable waypoints or script lines will be affected by set_tcp().

In this sample a subprogram contains four teached waypoints. These four waypoints are used in script lines in the robot program and will be affected by the changed TCP.
The program switches between two TCP's:

tcp_1 = p[0,0,0,0,0,0]
tcp_1 is with zero offset
Program 1
tcp_2 = p[0,0,0.1,0,d2r(30),0]
Note: d2r() This code is not available in all software version and the calculation: (degree/180)*3.14149262 need to be used.
tcp_2 is with 100 mm offset in Z-direction and an angle of 30 degrees
Program 2

Program example for both first and second example is attached.

Attached files


SwitchBetweenTCP.zip
logo

Product

  • UR3e Robot
  • UR5e Robot
  • UR10e Robot
  • UR16e Robot
  • UR20 Robot
  • UR+ Products

Company

  • About us
  • Contact us
  • Careers We're hiring
  • UR merchandise

Training / Resources

  • Academy
  • Technical Resources
  • Articles
  • FAQ

Insights

  • Blog
  • Case stories
  • Content library
  • News centre
  • Podcast
  • Webinars & Events

Get in touch

  • Ask an Expert
  • Schedule a no-cost assessment
  • Find a distributor
  • Customer support

Connect with us

  • LinkedIn
  • Facebook
  • Twitter
  • YouTube
  • Instagram
  • Universal Robots A/S
  • Energivej 51
  • DK-5260 Odense S
  • T: +45 89 93 89 89
  • sales@universal-robots.com
  • US Corporate Office
  • 27-43 Wormwood St.
  • 02210 Boston, MA.
  • +1-844-GO-COBOT
  • ur.na@universal-robots.com
  • Copyright @ Universal Robots 2025
  • Cookie policy
  • Privacy policy
  • Universal Robots A/S
  • Energivej 51
  • DK-5260 Odense S
  • T: +45 89 93 89 89
  • sales@universal-robots.com
  • US Corporate Office
  • 27-43 Wormwood St.
  • 02210 Boston, MA.
  • +1-844-GO-COBOT
  • ur.na@universal-robots.com

Copyright © Universal Robots 2025

Cookie policy
Privacy policy