Using "Encoder 2" as the encoder source

With some MOVI-C® axes, it is possible to connect a 2nd encoder to the inverter. The position value of the 2nd encoder (Encoder 2) is then transferred via the EtherCAT® process data words PI 9 and PI 10.

To use the 2nd encoder as the source for the encoder axis, select the option "Encoder 2" as the "Encoder source" in the configuration menu Encoder axis settings, or set the EncoderSource parameter to "Encoder 2" via the function block MC_SEW_ConfigEncoderAxis.

Call the MC_SEW_EncoderAxis function block and link the name of the logical device of the MOVI-C® axis to the ReferenceToAxis input as follows:

VAR

EncoderAxis : MC_SEW_EncoderAxis;

END_VAR

// Use of the function block to connect encoder 2 of a MOVI-C axis

EncoderAxis(Enable:= TRUE, Axis := NameOfLogDevEncoderAxis,

ReferenceToAxis := NameOfLogDevMovicAxis );