MC_ReadActualPosition

MC_ReadActualPosition 1:

The current axis position can be read with the function block MC_ActualPosition.

Inputs


VAR_INPUT
Enable   : BOOL;
END_VAR

Enable

The command is executed as long as Enable is active.

Outputs


VAR_OUTPUT
Valid    : BOOL;
Busy     : BOOL;
Error    : BOOL;
ErrorID  : UDINT;
Position : LREAL;
END_VAR

Valid

Indicates that the Position output is valid.

Busy

Indicates that the function block is active.

Error

Becomes TRUE if an error occurs.

ErrorID

If the error output is set, this parameter supplies the error number

Position

Current axis position

Inputs/outputs


VAR_IN_OUT
Axis    : AXIS_REF;
END_VAR

Axis

Axis data structure

The axis data structure of type AXIS_REF addresses an axis uniquely within the system. Among other parameters it contains the current axis status, including position, velocity or error status.