iParServer (FB)ΒΆ
FUNCTION_BLOCK iParServer
Handles iPar-Request for a single slot/subslot of a Field Device.
Default implementation which stores iPar data on filesystem can be replaced by own implemenatation of IIParameterData.
iPar-Server Example
PROGRAM PLC_PRG
VAR
iparServer : iParServer.iParServer;
paramDB : iParServer.DefaultIParameterDB;
iParData : iParServer.DefaultIParData;
END_VAR
iParData.stFilename := 'iParTest'; // default implementation stores data on file system
paramDB(); // file access, do not exec in realtime task !
//call ipar server with module ID of the PROFIsafe module
iparServer(ID := IoDrvProfinetBase.GetID(fmodule), DATA := iParData);
- InOut:
Scope
Name
Type
Comment
Input
IDDWORDIdentifier of a slot / subslot of a Field Device
DATAOutput
xSaveBOOLReceived iPar Save-Notification, Upload of data in progress
xRestoreBOOLReceived iPar Restore-Notification, Download of data in progress
xErrorBOOLError occured, see outputs eErrorCode and dwCommError for details
eErrorCodesee enum iParServer Error
dwCommErrorDWORDError Code of underlying communication layer, see IEC 61158-6 Type 3(Profibus DP) and Type 10 (Profinet IO)