|
Type: |
Function block |
|
Available as of: |
V1.7.3.0 |
|
Inherits from: |
- |
|
Implements: |
- |
This chapter provides information on:
The function block FB_ReceiceVisionDataServer collects the data for a vision protocol and analyzes the data. You can read out the content of the protocol.
You must call the method ClearVisionData before sending (trigger) a new protocol; otherwise the function block generates an exception.
|
Input |
Data type |
Description |
|---|---|---|
|
i_xEnable |
BOOL |
A rising edge FALSE -> TRUE activates the POU, a falling edge TRUE -> FALSE deactivates the POU. A deactivated POU does not execute any action. |
|
i_xDiagQuit |
BOOL |
A rising edge FALSE -> TRUE cancels an active exception of the POU. |
|
Output |
Data type |
Description |
|---|---|---|
|
q_xActive |
BOOL |
TRUE: The POU is active. If the output is TRUE while the i_xEnable is deactivated, the POU must first terminate its ongoing processing before transitioning this output to FALSE. FALSE: The POU is inactive |
|
q_xReady |
BOOL |
TRUE: The POU is ready to operate and can accept user commands. FALSE: The function block is not ready to accept user commands. |
|
q_etDiag |
ET_DiagExt |
POU-specific output on the diagnostic. q_etDiag = ET_Diag.Ok -> Status message q_etDiag <> ET_Diag.Ok -> Diagnostic message |
|
q_etDiagExt |
ET_DiagExt |
POU-specific output on the diagnostic. q_etDiag = GD.ET_Diag.Ok -> Status message q_etDiag <> GD.ET_Diag.Ok -> Diagnostic message |
|
q_sMsg |
STRING[80] |
Event-triggered message that gives more detailed information on the diagnostic state. |
|
q_xClientConnected |
BOOL |
Indicates if there is a connected client. |
|
q_etDiag |
q_etDiagExt |
Enumeration value of q_etDiagExt |
Description |
|---|---|---|---|
|
Ok |
Ok |
0 |
Ok. |
|
Disabled |
11 |
Disabled. |
|
|
WaitUntilDisabled |
10 |
Disabling. |
|
|
ConfigurationFailed |
ConfigurationInvalid |
16 |
Configuration invalid. |
|
ExecutionAborted |
AddressInUse |
18 |
Address is in use. |
|
AnotherProtocolAlreadyExecuting |
20 |
Another protocol is already executing. |
|
|
CertificateFailureServer |
73 |
The certificate is not valid; TCP-Server. |
|
|
CertificateNotFound |
72 |
The certificate could not be found. |
|
|
CertificateNoKey |
76 |
No private key is available. |
|
|
EndSignalOfDataInvalid |
21 |
End signal of data invalid. |
|
|
InitTlsContextFailed |
75 |
Too many sockets are used. |
|
|
ProtocolHeaderInvalid |
5 |
The header of protocol is invalid. |
|
|
StartOfProductDataInvalid |
6 |
The start of the product data is invalid. |
|
|
VisionDataHasNotBeenCleared |
24 |
Vision data has not been cleared. |
|
|
InputParameterInvalid |
InputStringInvalid |
77 |
The received string is invalid. |
|
LimitReached |
AdditionalStringLengthExceeded |
33 |
Length of the additional string was exceeded. |
|
ProductsPerProtocolExceeded |
19 |
Number of products per protocol was exceeded. |
|
|
ProtocolLengthExceeded |
15 |
Protocol length has been exceeded. |
|
|
UserDataLengthExceeded |
32 |
Length of the user data was exceeded. |
|
|
UnexpectedProgramBehavior |
UnexpectedFeedback |
4 |
A feedback value is indeterminable. |
|
Enumeration name: |
AdditionalStringLengthExceeded |
|
Enumeration value: |
33 |
|
Description: |
Additional string length exceeded. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
Length of the additional string was exceeded. |
The length of the additional string exceeds the maximum length of 80 characters. |
Reduce the user data to the maximum length of 80. |
|
Enumeration name: |
AddressInUse |
|
Enumeration value: |
18 |
|
Description: |
Duplicate address. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
The address/port is already used. |
The IP address / port combination is not unique. |
Verify that the combination of IP address and port is unique and not used by another client. |
|
Enumeration name: |
AnotherProtocolAlreadyExecuting |
|
Enumeration value: |
20 |
|
Description: |
Another protocol is already executing. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
Another protocol is already executing. |
A protocol is not completely analyzed while a new protocol is sent. |
Verify that no new protocol is triggered before the current protocol is completely analyzed. |
|
Enumeration name: |
CertificateFailureServer |
|
Enumeration value: |
73 |
|
Description: |
The certificate is not valid; TCP-Server. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
The certificate is not valid. |
The certificate is not stored in Trusted Certificate. |
Move the certificate from Quarantined Certificate to Trusted Certificate and reboot the controller. For further information refer to Handling the TLS-Certification or in the Security Screen ( ) in the Online Help. |
|
Enumeration name: |
CertificateNotFound |
|
Enumeration value: |
72 |
|
Description: |
The certificate could not be found. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
The certificate is not found on the controller. |
An incorrect name for the certificate was selected. |
Ensure that the correct name is selected in Certificate Name. |
|
Enumeration name: |
CertificateNoKey |
|
Enumeration value: |
76 |
|
Description: |
No private key is available. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
No private key is available. |
The certificate has no private key. |
Use a certificate with a private key or the default certificate. |
|
Enumeration name: |
ConfigurationInvalid |
|
Enumeration value: |
16 |
|
Description: |
The configuration is invalid. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
The configuration is invalid. |
No Configuration method has been successfully called. |
Ensure that the Configuration method that was used, (ConfigurationTls() or ConfigurationNoTls() ), was called successfully before enabling the FB_ReceiveVisionDataServer. |
|
Enumeration name: |
Disabled |
|
Enumeration value: |
11 |
|
Description: |
Disabled. |
Status message: The function block is deactivated, no actions are executed. Set FB_ReceiveVisionDataClient.xEnable to TRUE to enable the function block.
|
Enumeration name: |
EndSignalOfDataInvalid |
|
Enumeration value: |
21 |
|
Description: |
End signal of data invalid. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
End signal of data is invalid. |
The end signal (CarriageReturn) of the vision data was not detected. |
Verify that the data is terminated with a last signal CarriageReturn. |
|
Enumeration name: |
InitTlsContextFailed |
|
Enumeration value: |
75 |
|
Description: |
Too many sockets are used. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
Too many sockets are used, only 10 sockets are available. |
Too many sockets for TCP-Connection are open. |
Ensure that not more than 10 sockets are used. 10 sockets are valid for the complete Controller. If other connections are used, ensure these connections are closed correctly. |
|
Enumeration name: |
InputStringInvalid |
|
Enumeration value: |
77 |
|
Description: |
The received string is invalid. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
The received string is invalid. |
The received string is not correct. |
Make sure to send a correct protocol string. |
|
Enumeration name: |
Ok |
|
Enumeration value: |
0 |
|
Description: |
Success |
Status message: Reading the data was successful.
|
Enumeration name: |
ProductsPerProtocolExceeded |
|
Enumeration value: |
19 |
|
Description: |
Maximum number of products per protocol exceeded. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
Number of products per protocol is exceeded. |
The number of products in one vision protocol exceeds the maximum number (Gc_uiMaxNumberOfProductsPerProtocol). |
Adapt the parameter Gc_uiMaxNumberOfProductsPerProtocol. Send the product data in several protocols. |
|
Enumeration name: |
ProtocolHeaderInvalid |
|
Enumeration value: |
5 |
|
Description: |
The header of the protocol is invalid. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
The header of the protocol is invalid. |
The protocol length in the header is 0 (uiProtocolLength). |
Verify that the header provides the correct length of the protocol. |
|
Header of the protocol does not contain the string Vision (sHeaderId). |
Verify that the protocol starts with the string Vision. |
|
|
Header contains invalid characters after the string Vision. |
Verify that the header only contains the string Vision followed by 16 numbers. |
|
|
Another client sends data. |
Verify that the combination of IP address and port is unique and not used by another client. |
Refer to ST_VisionDataHeader.
|
Enumeration name: |
ProtocolLengthExceeded |
|
Enumeration value: |
15 |
|
Description: |
The length of the protocol has been exceeded. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
Protocol length is exceeded. |
The length of the vision protocol exceeds the maximum length (Gc_uiMaxLengthProtocol). |
Adapt the parameter Gc_uiMaxLengthProtocol. Send the product data in several protocols. |
Refer to GPL.
|
Enumeration name: |
StartOfProductDataInvalid |
|
Enumeration value: |
6 |
|
Description: |
The start of a product data is invalid. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
The start of a product data is invalid. |
Product data does not start with object index O. |
Verify that the product data start with O (for example, O1I1X10…). |
|
First characters after the header must be P, A, or CarriageReturn. |
Verify that the product data after the header starts with P, A, or CarriageReturn. |
|
Enumeration name: |
UnexpectedFeedback |
|
Enumeration value: |
4 |
|
Description: |
Internal error detected. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
Feedback was invalid. |
Receiving data was not successful, the server was shut down. |
Restart the server. |
|
Enumeration name: |
UserDataLengthExceeded |
|
Enumeration value: |
32 |
|
Description: |
User data length exceeded. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
User data length is exceeded. |
The length of the user data exceeds the maximum length of 80. |
Adapt the length of the user data. |
|
Enumeration name: |
VisionDataHasNotBeenCleared |
|
Enumeration value: |
24 |
|
Description: |
Vision data has not been cleared. |
|
Issue |
Cause |
Solution |
|---|---|---|
|
Vision data was not cleared. |
Vision data was not been cleared before new data has been received. |
Verify that method ClearVisionData was called before receiving new data. |
|
Enumeration name: |
WaitUntilDisabled |
|
Enumeration value: |
10 |
|
Description: |
Wait until disabled. |
Status message: The function block is going to be disabled.
|
Name |
Description |
|---|---|
|
ClearVisionData |
Clear vision data and prepare the function block to receive new data. |
|
ConfigurationTLS |
Configure the IP address and port the server monitors, and set the TLS settings. |
|
ConfigurationNoTLS |
Configure the IP address and port the server monitors. |
|
GetAdditionalString |
Read out the additional string of the vision protocol. |
|
GetHeader |
Read out the header data of the vision protocol. |
|
GetProducts |
Read out the product data of the vision protocol. |
|
GetVisionString |
Read the vision string. |
|
RegisterLoggerPoint |
Register the function block FB_ReceiveVisionDataServer to the . |