Data structure#

Data structure#

(1)R2PLC_DigitalSignalStatus (10 byte) : robot digital signal status data direction: robot →PLC

data

BYTE1

general_digital_input[0..7]

DIN[0]

BYTE2

general_digital_input[8..15]

DIN[1]

BYTE3

tool_digitial_input[0..7]

DIN[2]

BYTE4

general_digital_output[0..7]

DIN[3]

BYTE5

general_digital_output[8..15]

DIN[4]

BYTE6

tool_digital_output[0..7]

DIN[5]

BYTE7

fun_digital_input[0..7]

DIN[6]

BYTE8

fun_digital_output[0..7]

DIN[7]

BYTE9

safety_state_input

DIN[8]

BYTE10

safety_state_output

DIN[9]

Note: The global variable DIN in the above example is used as an example.

See the DUCO CORE Hardware Manual for terminal definitions

general_digital_input: general DI status of the control cabinet.

tool_digitial_input: DI state of the end of robot

general_digital_output: general DO status of the control cabinet

tool_digital_output: DO status of the end of robot

fun_digital_input: function DI status of the control cabinet

fun_digital_output: indicates the DO status of the control cabinet function

Safety controller status safety_state Structure description

safety_state_1

safety_state_2

bit0

ystem_emergency_stop

config_safety_output0

bit1

external_emergeny_stop

config_safety_output1

bit2

protective_stop_input

reserved

bit3

operation_mode_input

reserved

bit4

3_position_enable_input

reserved

bit5

config_safety_input0

reserved

bit6

config_safety_input1

reserved

bit7

reserved

reserved

config_safety_input: safety input set by the interface

config_safety_output: safety output set by the interface

(2) R2PLC_Reserved (6 byte) : Robot digital signal status data direction: robot →PLC

BYTE1..6

reserved [0..5]

DIN[10…15]

(3)R2PLC_RobotState(32float): robot state information output data direction: robot →PLC

Float1..7

joint_pos(rad)

DIN[16…43]

Float8..13

tcp_pose(tcp relative to the

base coordinate system)

DIN[44…67]

Float14..19

tcp_force

DIN[68…91]

Float20..25

tcp_offset

DIN[92…115]

Float26..29

tcp_load (Center of mass,mass)

DIN[116…131]

Float30..32

reserved

DIN[132…143]

Note: The global variable DIN in the above example is used as an example.

(4) R2PLC_BitOutputReg (10 byte) : bit output register, output the robot’s current bit register status information data direction: robot →PLC

BYTE1

fun_registers_output[1..8]

DIN[144]

BYTE2

fun_registers_output[9..16]

DIN[145]

BYTE3

bool_registers_output[1..8]

DIN[146]

BYTE4

bool_registers_output[9..16]

DIN[147]

BYTE5

bool_registers_output[17..24]

DIN[148]

BYTE6

bool_registers_output[25..32]

DIN[149]

BYTE7

bool_registers_output[33..40]

DIN[150]

BYTE8

bool_registers_output[41..48]

DIN[151]

BYTE9

bool_registers_output[49..56]

DIN[152]

BYTE10

bool_registers_output[57..64]

DIN[153]

Note: The global variable DIN in the above example is used as an example.

(5) R2PLC_WordOutputReg (64 byte) :Word output register Data direction: robot →PLC

Word1..32

word_output_register [1..32]

DIN[154…217]

Note: The global variable DIN in the above example is used as an example.

(6)R2PLC_FloatOutputReg (32 float) : floating-point output register Data direction: robot →PLC

Float1..32

float_output_register [1..32]

DIN[220…347]

Note: The global variable DIN in the above example is used as an example.

(7)R2PLC_RobotInfo (16 float) : end alignment speed and other information data direction: robot →PLC

Float1

Read global speed percentage

DIN[348…351]

Float2

Read Jog speed percantage

DIN[352…355]

Float3

Read the terminal closing

speed

DIN[356…359]

Float4

Read real/simulation mode

DIN[360…363]

Float5

Read error ID (the system’s

last error ID)

DIN[8]

Float6..16

Reserved

DIN[368…411]

Note: The global variable DIN in the above example is used as an example.

(8)PLC2R_Digital_Output_Command (3 byte) : Robot related control command Input data direction: PLC→ robot

BYTE1

general_digital_ouput[1..8]

DOUT[0]

BYTE2

general_digital_ouput[9..16]

DOUT[1]

BYTE3

tool_digital_output[1..8]

DOUT[2]

Note: The global variable DOUT is used as an example.

(9) PLC2R_Reserved (7 byte) : Reserved data direction: PLC→ robot

BYTE1..7

Reserved

DOUT[3…9]

Note: The global variable DOUT is used as an example.

(10) BitInputReg(10 byte): universal bit input register Data direction: PLC→ robot

BYTE1

fun_input_register[1..8]

DOUT[10]

BYTE2

fun_input_register[9..16]

DOUT[11]

BYTE3..10

bit_input_register[1..64]

DOUT[12…19]

Note: The global variable DOUT is used as an example.

(11) PLC2R_WordInputReg (64 byte): Word input register Data direction: PLC→ robot

BYTE1..32

word_input_register[1..32]

DOUT[20…83]

Note: The global variable DOUT is used as an example.

(12)PLC2R_FloatInputReg(32 float): general floating-point input register data direction: PLC → robot

Float1..32

float_input_register[1..32]

DOUT[84…211]

Note: The global variable DOUT is used as an example.

(13)PLC2R_RobotInfo (16 float): global speed percentage and other information data direction: PLC → robot

Float1

Set the global speed

percentage

DOUT[212…215]

Float2..16

Reserved

DOUT[216…275]

Note: The global variable DOUT is used as an example.