EasyManua.ls Logo

Pepperl+Fuchs OPC - Page 61

Pepperl+Fuchs OPC
75 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
OPC / OPD / OPE
Appendix
2015-07
61
Library Functions
bool Connect(string ip,int port)
ip: IP of the connected sensor
port: Port of the connected sensor
Response: False if the connection could not be created, otherwise true
Opens a connection to a sensor with the IP and port specified.
void Disconnect()
Disconnects the open connection
bool Connected {get;}
Response: Returns the connection status
void SaveSensorSettings()
Saves the current parameter set in the senso r's memory.
After a confirmation has been received from the sensor, a
SaveDataOnSensorReceived event is triggered.
void LoadSensorSettings()
Requests a parameter set that has been saved with SaveSensorSettings
from the sensor.
After the parameter set has been received from the sensor, a
ParameterDataReceived event is triggered with Modifier = LOAD_Data.
The data can then be retrieved using the GetSingleParameter method.
void GetNetworkSettings()
Requests the sensor's current connection settings from the sensor.
After this data has been received from the sensor, a GetNetworkReceived event
is triggered. This provides the current IP address, network mask, and gateway
for the sensor.
void GetLogMessages(bool on)
on: Switches log messages on
off: Switches log messages off
Defines whether or not the sensor sends log messages. If log messages are
switched on, a LogDataReceived event is triggered each time a log message
is received from the sensor.
void GetAllParametersFromSensor()
Requests the current parameter set from the sensor. After the parameter set has
been received from the sensor, a ParameterDataReceived event is triggered
with Modifier = None. This indicates that the internal list has been updated
with the parameter set. You can then retrieve individual parameters via
GetSingleParameter.
public bool ExistsParameter(string configId, string parameterId)
Used to query whether a particular parameter exists on the sensor
configId: Configuration ID of a parameter
parameterId: Parameter ID of a parameter
Response: True or false, depending on whether the parameter exists
string GetSpecificSingleParameter(ushort version, string
configId, string parameterId)
configId: Configuration ID of a parameter
parameterId: Parameter ID of a parameter
Response: The current value of the specified parameter
Retrieves the current value for a parameter from the senso r; details of the
ve rsion, configId, and parameterId can be taken from the accompanying table.
Returns the value of the parameter, or an empty string if the value was not
retrieved.

Related product manuals