VAL_WriteJoint

VAL_WriteJoint 1:

FUNCTION_BLOCK VAL_WriteJoint

This function block allows to initialize a joint position inside a database

Syntax

Definition:

FUNCTION_BLOCK VAL_WriteJoint
VAR_INPUT
    Execute       : BOOL := FALSE;
    UserDatabase  : BOOL := FALSE;
    JointIdx      : INT := -1;
    Joint1        : REAL := 0;
    Joint2        : REAL := 0;
    Joint3        : REAL := 0;
    Joint4        : REAL := 0;
    Joint5        : REAL := 0;
    Joint6        : REAL := 0;
    SaveOnDisk    : BOOL := TRUE;
END_VAR
VAR_OUTPUT
    Busy     : BOOL := FALSE;
    Done     : BOOL := FALSE;
    Error    : BOOL := FALSE;
    ErrorID  : UDINT := 0;
END_VAR
VAR_IN_OUT
    AxesGroup  : T_StaeubliRobot;
END_VAR

VAL_WriteJoint 2: Inputs

Name

Type

Description

Execute

BOOL

Rising edge triggers function execution

UserDatabase

BOOL

True=Data of the user database will be used; False= Use data of the plc database

JointIdx

INT

Index of the joint position in the bank

Joint1

REAL

Coordinate for axis 1

Joint2

REAL

Coordinate for axis 2

Joint3

REAL

Coordinate for axis 3

Joint4

REAL

Coordinate for axis 4

Joint5

REAL

Coordinate for axis 5 - not applicable for 4 axis robots-

Joint6

REAL

Coordinate for axis 6 - not applicable for 4 axis robots-

SaveOnDisk

BOOL

True=Tool data stored onto the controller's flashdisk. False=Data not stored--> faster FB execution

VAL_WriteJoint 3: Outputs

Name

Type

Description

Busy

BOOL

Set when function block is executing. Reset when Done or Error is set

Done

BOOL

This output is set when function block has terminated with success

Error

BOOL

This output is set when function block has terminated with error

ErrorID

UDINT

Error code

VAL_WriteJoint 4:/VAL_WriteJoint 5: Inputs/Outputs

Name

Type

Description

AxesGroup

T_StaeubliRobot

Data block for a robot