MC_ReadAxisError

When there is an axis error, the FB MC_ReadAxisError returns the error P-ERR-40001 (ERR_PLC_AX_MC) at its output “ErrorID”. At output “AxisErrorID” the error code of the motion controller is displayed. The associated error message texts are saved in separate text or XML files. All other error codes at the output “ErrorID” not corresponding to the value of the error P-ERR-40001 (ERR_PLC_AX_MC) indicate internal FB errors.

For explanations of the values at outputs “ErrorID” and “AxisErrorID”, refer to DIAG].

Block diagram

FB parameters

VAR_IN_OUT

Variable name

Data type

Description

Axis

AXIS_REF

Axis reference

VAR_INPUT

Variable name

Data type

Description

Enable

BOOL

When the value is TRUE, the error codes for axis error are supplied.

VAR_OUTPUT

Variable name

Data type

Description

Valid

BOOL

If the output is TRUE, the error codes are valid.

Error

BOOL

Is TRUE when an error occurs on the axis.

ErrorID

WORD

Error identifier

AxisErrorID

UDINT

Error code of the axis error from the motion controller.

Behaviour of the FB: