F_EcGetSyncUnitName

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.
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. |
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. |
Outputs
VAR_OUTPUT
sSyncUnitName : STRING(63);
END_VAR
Name | Type | Description |
---|---|---|
sSyncUnitName | STRING | Returns the name of the sync unit. |
Prerequisites
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 |