3.7.0 3.6.0 3.5.0 3.4.0 3.3.0 3.2.2 3.2.1 3.2.0 Korean English Chinese Czech Dutch French German Hungarian Italian Japanese Polish Portuguese Spanish
3.7.0 3.6.0 3.5.0 3.4.0 3.3.0 3.2.2 3.2.1 3.2.0 Korean English Chinese Czech Dutch French German Hungarian Italian Japanese Polish Portuguese Spanish

get_tool_digital_inputs()

get_tool_digital_inputs(bit_list)

Features

This function reads the signal of the robot tool from the digital contact point.
The digital signals of the contact points defined in bit_list are input at one.

Parameters

Parameter Name

Data Type

Default Value

Description

bit_list

list (int)

-

List of contact points to read

  • (I/O contact numbers (1-6) mounted on the robot arm)

Return

Value

Description

int (>=0)

Multiple contacts to be read at once (the value of the combination of the bit list where bit_start =LSB and bit_end=MSB)

Negative number

Failed

Exception

Exception

Description

DR_Error (DR_ERROR_TYPE)

Parameter data type error occurred

DR_Error (DR_ERROR_VALUE)

Parameter value is invalid

DR_Error (DR_ERROR_RUNTIME)

C extension module error occurred

DR_Error (DR_ERROR_STOP)

Program terminated forcefully

Example

Python
# input contacts: No. 1=OFF, No. 2=OFF, and No. 3=ON
res = get_tool_digital_inputs(bit_list=[1,2,3]) # Reads the contacts 1, 2, and 3 at once. 
#res expected value = 0b100 (binary number), 4 (decimal number), or 0x04 (hexadecimal number)

# input contacts: No. 4=ON, No. 5=ON, and No. 6=OFF
res = get_tool_digital_inputs([4,5,6]) 
#res expected value = 0b011 (binary number), 3 (decimal number), or 0x03 (hexadecimal number)

Keyword

get / tool / digital / inputs / get_tool / digital_inputs / tool_digital_inputs


get_tool_digital_inputs(bit_start, bit_end)

Features

This function reads the signal of the robot tool from the digital contact point. The multiple signals from the first contact point (start_index) to the last contact point (end_index) are input at one.

Parameters

Parameter Name

Data Type

Default Value

Description

bit_start

int

-

Beginning contact number for input signals (1~6)

bit_end

int

-

Ending contact number for input signals (1~6)

Return

Value

Description

int (>=0)

Multiple contacts to be read at once

Value of the combination of bits where bit_start =LSB and bit_end=MSB.

Negative number

Failed

Exception

Exception

Description

DR_Error (DR_ERROR_TYPE)

Parameter data type error occurred

DR_Error (DR_ERROR_VALUE)

Parameter value is invalid

DR_Error (DR_ERROR_RUNTIME)

C extension module error occurred

DR_Error (DR_ERROR_STOP)

Program terminated forcefully

Example

Python
# input contacts: No. 1=OFF, No. 2=OFF, and No. 3=ON
res = get_tool_digital_inputs(bit_start=1, bit_end=3) 
#res expected value = 0b100 (binary number), 4 (decimal number), or 0x04 (hexadecimal number)

# input contacts: No. 4=ON, No. 5=ON, and No. 6=OFF
res = get_tool_digital_inputs(4, 6) 
#res expected value = 0b011 (binary number), 3 (decimal number), or 0x03 (hexadecimal number)

Keyword

get / tool / digital / inputs / get_tool / digital_inputs / tool_digital_inputs