FB_KinLockTrafoParam

FB_KinLockTrafoParam 1:

Once the transformation parameters have been modified with the aid of FB_KinUnlockTrafoParam, the function block FB_KinLockTrafoParam locks the transformation parameters again, so that write access is no longer possible.

FB_KinLockTrafoParam 2: Inputs

VAR_INPUT
    bExecute              : BOOL;
    oidTrafo              : UDINT;
END_VAR

Name

Type

Description

bExecute

BOOL

The command is triggered by a rising edge at this input.

oidTrafo

UDINT

Object ID of the kinematic transformation object. See sample below.

FB_KinLockTrafoParam 3: Outputs

VAR_OUTPUT
    bBusy                 : BOOL;
    bDone                 : BOOL;
    bError                : BOOL;
    nErrorId              : UDINT;
END_VAR

Name

Type

Description

bBusy

BOOL

The output becomes TRUE when the command is started with bExecute and remains TRUE as long as the function block executes the command. While bBusy is TRUE, no new command is accepted at the inputs. If bBusy becomes FALSE again, the function block is ready for a new command. At the same time one of the outputs bDone or bError is set.

bDone

BOOL

The output becomes TRUE when the command was executed successfully.

bError

BOOL

The output bError is set to TRUE, if an error occurred during the command execution.

nErrorId

UDINT

Contains the command-specific error code of the most recently executed command. Details of the error code can be found in the ADS error documentation or in the NC error documentation (error codes from 0x4000).

Sample

SCARA transformation - sample object ID

FB_KinLockTrafoParam 4:
VAR
    bUserExecute         : BOOL;
    fbFB_LockTrafoParam  : FB_KinLockTrafoParam;
    oidTrafo             : UDINT := 16#01010070; (*Trafo object id*)
END_VAR
fbFB_LockTrafoParam(
    bExecute := bUserExecute,
    oidTrafo := oidTrafo,
    bBusy=>,
    bDone=>,
    bError=>,
    nErrorId=> );