AdsSyncReadDeviceInfoReqEx

Reads the identification and version number of an ADS server.

LONG AdsSyncReadDeviceInfoReqEx(
     LONG  port,
     PAmsAddr  pAddr,
     PCHAR  pDevName,
     PAdsVersion  pVersion
);

Parameters

port

[in] port number of an Ads port that had previously been opened with AdsPortOpenEx or AdsPortOpen.

pAddr

[in] Structure with NetId and port number of the ADS server.

pDevName

[out] Pointer to a character string that will receive the name of the ADS device.

pVersion

[out] Address of a variable of type AdsVersion, which will receive the version number, revision number and the build number.

Return value

Returns the function's error status.

Example

See example 5.