create Method

XenseGripper.create(mac_addr=None)

Creates an XenseGripper instance.

Parameters:

mac_addr (str, optional) – Provide the correct MAC communication address. For how to query the MAC address, see: ezros.

Returns:

A gripper instance that implements the Gripper interface.

Return type:

XenseTCPGripper

Example Code

Connect to the gripper via MAC address

from xensegripper import XenseGripper

# Create a connected gripper instance using the MAC address
gripper = XenseGripper.create(mac_addr="9a14e81bb832")

tips

If you don’t know the gripper’s MAC address, you can use the ezros tool to query it. For details, please refer to Using the EzROS Command-Line Tool.