F_EcGetSyncUnitName

F_EcGetSyncUnitName 1:

The name of an EtherCAT Sync Unit can be read via its object ID using this function. The return value of the function signals whether the call was successful and outputs the relevant error code in the event of an error.

F_EcGetSyncUnitName 2: Return value

METHOD F_EcGetSyncUnitName : HRESULT

Name

Type

Description

F_EcGetSyncUnitName

HRESULT

Signals whether the call was successful and outputs the relevant error code in the event of an error.

F_EcGetSyncUnitName 3: Inputs

VAR_INPUT
    oidSyncUnit : OTCID; // object ID of sync unit
END_VAR

Name

Type

Description

oidSyncUnit

OTCID

The object ID of the Sync Unit is specified at this input. This can be found in the process image of the EtherCAT master.

F_EcGetSyncUnitName 4: Outputs

VAR_OUTPUT
    sSyncUnitName : STRING(63);
END_VAR

Name

Type

Description

sSyncUnitName

STRING

Returns the name of the sync unit.

Requirements

Development environment

Target platform

PLC libraries to include

TwinCAT v3.1.4024.48

PC or CX (x86, x64, ARM)

Tc2_EtherCAT >= 3.4.2.0