UFactory xArm User manual

UFACTORY
1

UFACTORY
2
Table
1.General Presentation ...............................................................................................................4
1.1. Gripper Introduction ...................................................................................................4
1.2. Setup and Control........................................................................................................4
1.3. Safety...............................................................................................................................5
1.3.1. Warning ...............................................................................................................6
1.3.2. Risk Assessment and Final Application.......................................................6
1.3.3. Intended Use......................................................................................................7
2.Installation..................................................................................................................................8
2.1. Scope of Delivery .........................................................................................................9
2.1.1. General Kit...........................................................................................................9
2.2. Mechanical Installation...............................................................................................9
2.3. Electrical Setup........................................................................................................... 11
2.3.1. Pinout Interface .............................................................................................. 11
3.Control...................................................................................................................................... 13
3.1. Use xArm Studio to Control xArm Gripper ........................................................ 13
3.2. Use Python-SDK to Control xArm Gripper......................................................... 16

UFACTORY
3
3.3. Use ROS-SDK to Control xArm Gripper .............................................................. 16
3.4. Use Modbus-TCP Communication Protocol to Control xArm Gripper ...... 16
3.4.1. Modbus-TCP Communication Format ..................................................... 17
3.4.2. Read xArm Gripper Register ....................................................................... 18
3.4.3. Write xArm Gripper Register....................................................................... 21
3.4.4. xArm Gripper Control Process.................................................................... 26
3.5. Use Modbus-RTU Communication Protocol to Control xArm Gripper...... 26
3.5.1. Modbus RTU Communication Format ..................................................... 26
3.5.2. Read xArm Gripper Register ....................................................................... 27
3.5.3. Write xArm Gripper Register....................................................................... 28
3.5.4. Modbus RTU Example................................................................................... 29
4.Gripper Alarm Code & General Response...................................................................... 32
5.xArm Gripper Technical Specifications ............................................................................ 35
6.After-sales Service................................................................................................................. 36

UFACTORY
4
1. General Presentation
1.1.Gripper Introduction
The gripper is the end-effector of the robotic arm, which can grasp
objects dynamically.
The value range of the gripper opening and closing is: -10 to 850. The
larger the value, the greater the stroke of the gripper, meaning the
smaller the value, the smaller the stroke of the gripper. If the clamping is
not tight, a negative value can be set until it is tightened.
1.2.Setup and Control
The gripper is powered and controlled directly via a single gripper
connection cable that carries a 24V DC supply and Modbus RTU
communication over RS-485.

UFACTORY
5
1.3.Safety
Warning
The operator must have read and understood all of the instructions in
the following manual before handling the xArm Gripper.
Caution
The term "operator" refers to anyone responsible for any of the following
operations on the xArm Gripper:
●Installation
●Control
●Maintenance
●Inspection
●Calibration
●Programming
●Decommissioning
This documentation explains the various components of the xArm
Gripper and general operations regarding the whole life-cycle of the
product from installation to operation and decommissioning.
The drawings and photos in this documentation are representative
examples and differences may exist between them and the delivered
product.

UFACTORY
6
1.3.1. Warning
Caution
Any use of the Gripper in noncompliance of these warnings is
inappropriate and may cause injury or damage.
Warning
●The Gripper needs to be properly secured before operating the robot.
●Do not install or operate a Gripper that is damaged or lacking parts.
●Never supply the Gripper with an alternative current (AC) source.
●Make sure all cord sets are always secured at both ends,Gripper end &
Robot end
●Always satisfy the recommended keying for electrical connections.
●Be sure no one is in the robot and/or gripper path before initializing
the robot's routine.
●Always satisfy the gripper payload.
●Set the gripper speed accordingly, based on your application.
●Keep fingers and clothes away from the gripper while the power is on.
●Do not use the gripper on people or animals.
1.3.2. Risk Assessment and Final Application
The xArm Gripper is meant to be used on an industrial robot. The robot,
gripper and any other equipment used in the final application must be

UFACTORY
7
evaluated with a risk assessment. The robot integrator must ensure that
all local safety measures and regulations are respected. Depending on
the application, there may be risks that need additional protection/safety
measures, for example, the work-piece the gripper is manipulating may
be inherently dangerous to the operator.
1.3.3. Intended Use
The gripper is designed for grasping and temporarily securing or holding
objects.
Caution
The Gripper is NOT intended for applying force against objects or
surfaces.
The product is intended for installation on a robot or other automated
machinery and equipment.
Info
Always comply with local and/or national laws, regulations and directives
on automation safety and general machine safety.
The unit may be used only within the range of its technical data. Any
other use of the product is deemed improper and unintended use.
UFACTORY will not be liable for any damages resulting from any
improper or unintended use.

UFACTORY
8
2. Installation
The following subsections will guide you through the installation and
general setup of xArm Gripper.
(1) The Scope of Delivery section
(2) The Mechanical Installation section
(3) The Electrical Setup section
Warning
Before installing:
Read and understand the safety instructions related to the xArm Gripper.
Verify your package according to the Scope of delivery and your order
info.
Have the required parts, equipment and tools listed in the requirements
readily available.
Installing:
Satisfy the environmental conditions.
Do not operate the Gripper, or even turn on the power supply, before it is
firmly anchored and the danger zone is cleared.
Caution the fingers of the gripper which may move and cause injury or
damage.

UFACTORY
9
2.1. Scope of Delivery
2.1.1. General Kit
A Gripper Kit generally includes these items:
xArm Gripper
xArm Gripper signal cable
Cross countersunk head screws M6*8 (4)
2.2. Mechanical Installation
xArm Gripper installation steps (as shown below):
1. Move the robotic arm to a safe position. Avoid touching the robotic
arm mounting surface or other equipment;
2. Power off the robotic arm by pressing the emergency stop button on
the control box;
3. Fix the gripper on the end of the robotic arm with 2 M6 bolts;

UFACTORY
10
4. Connect the robotic arm and the gripper with the gripper connection
cable;
Note:
1. When wiring the gripper connection cable, be sure to power off the robotic arm,
the emergency stop button is in the pressed state and the power indicator of the
robotic arm is off, so as to avoid robotic arm failure caused by hot plugging;
2. Due to the limitation of the length of the gripper connection cable, the gripper
connector and the tool/end effector connector must be on the same side;
3. When connecting the gripper and the robotic arm, be sure to align the
positioning holes at the ends of the gripper and the robotic arm. Since the male

UFACTORY
11
pins of the gripper connection cable are relatively thin, avoid bending the male
pins during disassembly.
2.3. Electrical Setup
Power and communication are established with the xArm Gripper via a
single gripper connection cable. The gripper connection cable provides a
24V power supply to the Gripper and enables serial RS485
communication to the control box.
Warning
Power must be off before connecting the Gripper and the robotic arm via
the gripper connection cable.
2.3.1. Pinout Interface

UFACTORY
12
There are 8 pins inside the cable with different colors, each color
represents different functions, please refer to the following table:
Line sequence
Color
Signal
1
White
24V
2
Brown
24V
3
Green
GND
4
Yellow
GND
5
Gray
485-A
6
Powder
485-B
7
Blue
IN0(Digital input)
8
Red
IN1(Digital input)
Note:
1. For details of the tool/end effector connector of the robotic arm,
please refer to the xArm user manual:
https://www.ufactory.cc/pages/download-xarm

UFACTORY
13
3. Control
3.1.Use xArm Studio to Control xArm Gripper
1. Set up xArm Gripper
⚫Enter [Settings]-[End Effector]
Select the end effector: xArm Gripper
1. The opening and closing speed of the gripper can be adjusted.
2. The self-collision prevention model of the gripper can be turned on by
clicking the button.
3. When "TCP payload compensation" is turned on, the default TCP
payload will be changed to the TCP payload parameter of the gripper.

UFACTORY
14
2. Control xArm Gripper
⚫Control the xArm gripper in the live control
Control Method:
1) By dragging this progress bar, you can control the opening and closing
stroke of the gripper.

UFACTORY
15
⚫Control the xArm gripper through Blockly
xArm Gripper.Blockly
The role of this program: execute this program to control the gripper to
pick the target object at the specified position, and then place the target
object at the target position.
Note:
1) When the gripper is installed on the robotic arm, the TCP Payload of
the gripper should be set in the Blockly program. When the total weight

UFACTORY
16
of the gripper changes after the object is picked, a new TCP Payload
needs to be set.
3.2.Use Python-SDK to Control xArm Gripper
For details on controlling Gripper with python-SDK, please refer to the
link below:
https://github.com/xArm-Developer/xArm-Python-SDK/blob/master/example/wra
pper/common/5004-set_gripper.py
3.3.Use ROS-SDK to Control xArm Gripper
Please refer to Section 5.7.7 in the ReadMe file attached to the ROS
package to control the gripper.
xArm ROS-SDK link :
https://github.com/xArm-Developer/xarm_ros
3.4.Use Modbus-TCP Communication Protocol to
Control xArm Gripper

UFACTORY
17
This section mainly explains how to control the xArm Gripper by using
the Modbus-TCP protocol through xArm control box.
3.4.1. Modbus-TCP Communication Format
Modbus-TCP:
Modbus protocol is an application layer message transmission protocol,
including three message types: ASCII, RTU, and TCP. The standard
Modbus protocol physical layer interface includes RS232, RS422, RS485
and Ethernet interfaces, and adopts master / slave communication.
Modbus TCP Communication Process:
1. Establish a TCP connection
2. Prepare Modbus messages
3. Use the send command to send a message
4. Waiting for a response under the same connection
5. Use the recv command to read the message and complete a data
exchange
6. When the communication task ends, close the TCP connection
Parameter:
Default TCP Port: 502 Protocol: 0x00 0x02

UFACTORY
18
On the problem of users using communication protocols to organize
data in big endian and little endian:
In this article, data analysis is big-endian analysis.
3.4.2. Read xArm Gripper Register
3.4.2.1. Register Function
Read Register
Request
MBTP Header
Transaction Identifier
2 Bytes
0x0001
Protocol Identifier
2 Bytes
0x0002
Length
2 Bytes
6+N*x2
Unit Identifier
1 Byte
0x7C
Internal Use
Internal Use
1 Byte
0x09
Modbus RTU Data
Slave ID (Gripper)
1 Byte
0x08
Function Code
1 Byte
0x03
Register Starting Address
2 Bytes
Address
Quantity of Registers
N*x2 Bytes
N*
Response
MBTP Header
Transaction Identifier
2 Bytes
0x0001
Protocol Identifier
2 Bytes
0x0002
Length
2 Bytes
6+N*x2
Unit Identifier
1 Byte
0x7C
Status Value
1 Byte
0x00
Internal Use
Internal Use
1 Byte
0x09
Modbus RTU Data
Slave ID
1 Byte
0x08
Function Code
1 Byte
0x03
Byte Count
1 Byte
N*x2
Registers Value
N*x2 Bytes
Value
N* = Quantity of Registers
Address = Register Starting Address

UFACTORY
19
Resgister:
Resgister Starting
Address
Registers Value
Get Gripper status
Register
0x0000
2 Bytes
Stop status: 0x0000
Motion status: 0x0001
Clipping status: 0x0010
Get Gripper
position Register
0x0702
4bytes
0xFFFFFFFB-0x00000320
Get Gripper Error
Register
0x000F
2 Bytes
An error occurs: all other return values
indicate an error(except 0)
No error occurred: 0x0000
3.4.2.2. Example
1. Get the xArm Gripper status
Get the xArm Gripper status
Request
MBTP Header
Transaction Identifier
2 Bytes
0x00,0x01
Protocol Identifier
2 Bytes
0x00,0x02
Length
2 Bytes
0x00,0x08
Unit Identifier
1 Byte
0x7C
Internal Use
Internal Use
1 Byte
0x09
Modbus RTU Data
Slave ID (Gripper)
1 Byte
0x08
Function Code
1 Byte
0x03
Register Starting Address
2 Bytes
0x00,0x00
Quantity of Registers
2 Bytes
0x00,0x01
Response
MBTP Header
Transaction Identifier
2 Bytes
0x00,0x01
Protocol Identifier
2 Bytes
0x00,0x02
Length
2 Bytes
0x00,0x08
Unit Identifier
1 Byte
0x7C

UFACTORY
20
Status Value
1 Byte
0x00
Internal Use
Internal Use
1 Byte
0x09
Modbus RTU Data
Slave ID
1 Byte
0x08
Function Code
1 Byte
0x03
Byte Count
1 Byte
0x02
Registers Value
(Robotic arm is in motion status)
2 Bytes
0x00,0x01
2. Get the xArm Gripper position
Get the xArm Gripper position
Request
MBTP Header
Transaction Identifier
2 Bytes
0x00,0x01
Protocol Identifier
2 Bytes
0x00,0x02
Length
2 Bytes
0x00,0x08
Unit Identifier
1 Byte
0x7C
Internal Use
Internal Use
1 Byte
0x09
Modbus RTU Data
Slave ID (Gripper)
1 Byte
0x08
Function Code
1 Byte
0x03
Register Starting Address
2 Bytes
0x07,0x02
Quantity of Registers
2 Bytes
0x00,0x02
Response
MBTP Header
Transaction Identifier
2 Bytes
0x00,0x01
Protocol Identifier
2 Bytes
0x00,0x02
Length
2 Bytes
0x00,0x0A
Unit Identifier
1 Byte
0x7C
Status Value
1 Byte
0x00
Internal Use
Internal Use
1 Byte
0x09
Modbus RTU Data
Slave ID
1 Byte
0x08
Function Code
1 Byte
0x03
Byte Count
1 Byte
0x04
Registers Value
(position: 400)
2 Bytes
0x00,0x00,0xC8,0x43
Other manuals for xArm
3
Table of contents
Other UFactory Robotics manuals

UFactory
UFactory uArm Swift Pro User manual

UFactory
UFactory uArm Controller User manual

UFactory
UFactory uArm Swift Pro Instruction Manual

UFactory
UFactory uArm Swift Pro Instruction Manual

UFactory
UFactory xArm 5 User manual

UFactory
UFactory uArm Controller User manual

UFactory
UFactory uArm Swift Operator's manual

UFactory
UFactory 850 User manual

UFactory
UFactory xArm User manual

UFactory
UFactory uArm Controller User manual