check_tool_limit()

Definition

check_tool_limit(tool)

Features

Check whether the tool to be applied can be configured, and if not, return the corresponding error number indicating the cause. During program execution, you can set temporary tools through set_temp_tool(). Additionally, verify if the tool is an allowable tool using check_tool_limit(). In the case of set_temp_tool(), if the setting value exceeds the permitted limit, the program will terminate; however, that command only returns the error number. You can pre-check the tool to be set using that command and identify the cause of any errors.

Parameters

Value

Data Types

Default Value

Description

tool

class.config_tool


Tool Setup Infomation

Class

class.config_tool

Field

Data Types

Description

obj

list

Object information for that class

weight

float

Tool Mass (kg)

xyz

float[3]

Center of gravity information (mm)

inertia

float[6]

Inertia Information (kg·mm2)

Return

Value

Description

1

Success

0

The mass has a negative value.

-1

The mass is over the maximum limit.

-2

The cog norm is greater than 1000 mm.

-3

The inertia tensor has negative values on its diagonal.

-4

The inertia tensor has singular values less than zero.

-5

The center of gravity is too far relative to the weight.

-6

The inertia exceeds the allowable limit for the joint 6.

-7

The inertia exceeds the allowable limit.

Exception

Exception

Description

DR_Error (DR_ERROR_TYPE)

Parameter data type error occurred

DR_Error (DR_ERROR_RUNTIME)

C extension module error occurred

DR_Error (DR_ERROR_STOP)

Program terminated forcefully

Example

Python
tool1 = config_tool([5.2, [0, 40, 250], [0.01, 0.01, 0.01, 0.0, 0.0, 0.0]])
rst = check_tool_limit(tool1)

Keyword

check / check_ / tool/ limit