VAL_MoveRelative
FUNCTION_BLOCK VAL_MoveRelative
This function block allows to commands a movement to a position calculated with specified offsets from a point located in a bank of a database.
The offset might be applied in the following coordinate system:
- Tool
- User Frame
Syntax
Definition:
FUNCTION_BLOCK VAL_MoveRelative
VAR_INPUT
Execute : BOOL := FALSE;
InterpolateJ : BOOL := FALSE;
EnableBlending : BOOL := FALSE;
UserDatabase : BOOL := FALSE;
BankID : INT := -1;
PointIdx : INT := -1;
ToolIdx : INT := -1;
MdescIdx : INT := -1;
Offsets : T_Trsf;
ShiftInFrame : BOOL := FALSE;
Uframe : INT := -1;
END_VAR
VAR_OUTPUT
Busy : BOOL := FALSE;
Done : BOOL := FALSE;
Error : BOOL := FALSE;
ErrorID : UDINT := 0;
MovementID : INT := -1;
END_VAR
VAR_IN_OUT
AxesGroup : T_StaeubliRobot;
END_VAR
Inputs
Name | Type | Description |
---|---|---|
Execute | BOOL | Rising edge triggers function execution |
InterpolateJ | BOOL | True=Joint interpolated movement; False=Linear movement |
EnableBlending | BOOL | True=use blending parameter of motion descriptor; False= robot stops at destination. |
UserDatabase | BOOL | True=Use user database; False=Use plc database |
BankID | INT | Number of the bank in which the point is located |
PointIdx | INT | Index of the Point data in the bank |
ToolIdx | INT | Index of the Tool in the bank to use for the commanded movement |
MdescIdx | INT | Index of the motion descriptor in the bank. |
Offsets | Relative distances in each dimensions for approaching the end-position. | |
ShiftInFrame | BOOL | True= Offset are applied in user frame. False= Offset are applied in Tool (default) |
Uframe | INT | Index of the user frame in which offsets are applied. This parameter is effective when parameter ShiftInFrame is True. |
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 |
MovementID | INT | Identifier for this commanded movement |