FB_Connection - General Information
Type: |
Function Block |
Available as of: |
V1.0.4.0 |
Inherits from: |
— |
Implements: |
— |
The function block FB_Connection handles the communication to a 3rd party transport system controller.
During the enabling phase of the function block, the communication to the transport system is established, and the data of the vehicles and paths that managed are written to the corresponding structures connected at the Input/Output iq_astVehicle and iq_astPath.
The order of the vehicles and paths is set correspondingly to the order in which the data is sent from the transport system controller when requesting the status of the vehicles and path. If there are more vehicles or paths in the transport system system than there are elements in the related arrays, the function block detects an exception and changes its state.
The system limits Gc_udiMaxNumberOfVehicles and Gc_udiMaxNumberOfPaths base on "Host Controller TCP Communication Protocol User's Manual" (990000436 Rev. A), Table A-2 "MagneMotion Transport System Limits" by MagneMotion.
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 actions. |
i_xExecute |
BOOL |
A rising edge orders the function block to send the command specified in the input i_etCommand to the transport system controller which is controlled by this function block. If the input i_xExecute (FB itself, iq_aST_Path and iq_aST_Vehicle) is set = TRUE before the FB is enabled and the FB will be turned on, the FB is detecting this as a rising edge. This is the criteria to execute a command (status requests or movements). Note: the setting i_xExecute = TRUE before enabling the function block is also considered a rising edge. |
i_etCommand |
The command which is send to the vehicle on a rising edge of i_xExecute. |
Output |
Data type |
Description |
---|---|---|
q_xActive |
BOOL |
TRUE: The POU is active and has to be executed. FALSE: The POU is inactive. |
q_xReady |
BOOL |
TRUE: The POU is ready to operate and can accept user commands. FALSE: The POU is not ready to accept commands. |
q_xBusy |
BOOL |
TRUE: The POU is executing the command. FALSE: The POU is waiting for further commands. |
q_xDone |
BOOL |
TRUE: The command has been executed. FALSE: The command is being executed, or none has been issued yet. |
q_etDiag |
General, library-independent statement on the diagnostic. A value unequal to GD.ET_Diag.Ok corresponds to a diagnostic message. |
|
q_etDiagExt |
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 which gives more detailed information on the diagnostic state. |
Input/Output |
Data type |
Description |
---|---|---|
iq_astVehicle |
ARRAY[1..Gc_udiMaxNumberOfVehicles] OF ST_Vehicle |
ARRAY of structures, where the vehicles are handled. The function block writes related data into this array of structures. |
iq_astPath |
ARRAY[1..Gc_udiMaxNumberOfPaths] OF ST_Path |
ARRAY of structures, where the paths are handled. The function block writes related data into this array of structures. |
iq_stControllerParameter |
Parameters related to transport system controller |
q_etDiag |
q_etDiagExt |
Enumeration value |
Description |
---|---|---|---|
OK |
1 |
The transport system controller reports that the component is disabled. |
|
OK |
4 |
The transport system controller reports that the component is disabling. |
|
OK |
2 |
The transport system controller reports that the component is initializing. |
|
OK |
3 |
The component is operational. |
|
ControllerConditionInvalid |
30 |
The controller type is not supported. |
|
ControllerConditionInvalid |
10 |
The transport system controller is not operational. |
|
ControllerConditionInvalid |
13 |
The response from the transport system controller contradicts the expected behavior: A command to a path has resulted in an invalid response from the transport system controller. |
|
ControllerConditionInvalid |
12 |
The response of the vehicle contradicts the expected behavior. |
|
ExecutionAborted |
11 |
The state of the transport system controller cannot be interpreted. |
|
ExecutionAborted |
29 |
A command to a path has been rejected. |
|
ExecutionAborted |
24 |
The response from the transport system controller is out of context. A command to a path has resulted in an inappropriate response. |
|
ExecutionAborted |
23 |
The response type of the transport system controller response is out of context. |
|
ExecutionAborted |
26 |
The response type of the transport system controller response cannot be interpreted. |
|
ExecutionAborted |
27 |
The response type contains an inappropriate value. |
|
FieldBusConditionInvalid |
6 |
Unable to establish a connection to the host. |
|
FieldBusConditionInvalid |
28 |
The connection to the host has been lost. |
|
FieldBusConditionInvalid |
7 |
The connection has been refused by the host. |
|
FieldBusConditionInvalid |
9 |
The function of the transport system controller is degraded. |
|
FieldBusConditionInvalid |
8 |
Unable to send commands to the transport system controller. |
|
FieldBusConditionInvalid |
22 |
Unable to verify if connected to host. |
|
InputParameterInvalid |
17 |
The transport system controller command is indeterminable. |
|
InputParameterInvalid |
31 |
The input exceeds the limit set in GPL. |
|
InputParameterInvalid |
21 |
The direction of the movement cannot be interpreted. |
|
InputParameterInvalid |
18 |
The path command is indeterminable. |
|
InputParameterInvalid |
20 |
The configuration of the PID set cannot be interpreted. |
|
InputParameterInvalid |
19 |
The command is not supported. |
|
LimitReached |
24 |
The response from the transport system controller is out of context. A command to a path has resulted in an inappropriate response. |
|
LimitReached |
14 |
The response from the transport system controller cannot be interpreted: A command to a path has resulted in an inappropriate response. |
|
LimitReached |
33 |
A timeout occurred during the boot operation. |
|
LimitReached |
34 |
A timeout occurred while waiting for the transport system controller to respond. |
|
LimitReached |
35 |
A timeout occurred during path reset. |
|
LimitReached |
32 |
A timeout occurred during the socket status verification. |
|
LimitReached |
25 |
The response of the vehicle is out of context. |
|
LimitReached |
15 |
The response of the vehicle cannot be interpreted. |
|
UnexpectedProgramBehavior |
5 |
The received CRC does not match the recalculated CRC. |
|
UnexpectedProgramBehavior |
14 |
The response from the transport system controller cannot be interpreted: A command to a path has resulted in an inappropriate response. |
|
UnexpectedProgramBehavior |
16 |
The state cannot be interpreted. |
Enumeration name: |
ConnectionFailed |
Enumeration value: |
6 |
Description: |
Unable to establish a connection to the host. |
Issue |
Cause |
Solution |
---|---|---|
- |
Unable to establish a connection to the transport system controller. |
Verify network cables and connectivity. |
Enumeration name: |
ConnectionLost |
Enumeration value: |
28 |
Description: |
The connection to the host has been lost. |
Issue |
Cause |
Solution |
---|---|---|
- |
Unable receive data from the transport system controller. |
Verify network cables and connectivity. |
Enumeration name: |
ConnectionRefused |
Enumeration value: |
7 |
Description: |
The connection has been refused by the host. |
Issue |
Cause |
Solution |
---|---|---|
- |
The host does not allow a connection. |
Verify network cables and connectivity. |
Enumeration name: |
ControllerCommandUnknown |
Enumeration value: |
17 |
Description: |
The transport system controller command is indeterminable. |
Issue |
Cause |
Solution |
---|---|---|
- |
It was attempted to send an unsupported command to the transport system controller. |
Make sure to send only supported commands. The supported commands are defined in ET_ControllerCommand. |
Enumeration name: |
ControllerIsDegraded |
Enumeration value: |
9 |
Description: |
The function of the transport system controller is degraded. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system controller is unable to communicate with the other controllers in the transport system. |
For further information, refer to the MagneMotion documentation. |
Enumeration name: |
ControllerIsNotOperational |
Enumeration value: |
10 |
Description: |
The transport system controller is not operational. |
Issue |
Cause |
Solution |
---|---|---|
- |
An error was detected during execution. |
Contact your Schneider Electric support representative. |
Enumeration name: |
ControllerStateUnknown |
Enumeration value: |
11 |
Description: |
The state of the transport system controller cannot be interpreted. |
Issue |
Cause |
Solution |
---|---|---|
- |
An undefined state of the transport system controller has been detected during execution. |
Contact your Schneider Electric support representative. |
Enumeration name: |
ControllerTypeInvalid |
Enumeration value: |
30 |
Description: |
The controller type is not supported. |
Issue |
Cause |
Solution |
---|---|---|
- |
The controller does not provide the required conditions. |
Verify whether your controller supports this library. |
Enumeration name: |
CrcMissmatch |
Enumeration value: |
5 |
Description: |
The received CRC does not match the recalculated CRC. |
Issue |
Cause |
Solution |
---|---|---|
- |
A CRC mismatch was detected during execution. |
Contact your Schneider Electric support representative. |
Enumeration name: |
Disabled |
Enumeration value: |
1 |
Description: |
The transport system controller reports that the component is disabled. |
Issue |
Cause |
Solution |
---|---|---|
- |
Status message from the transport system controller. |
The function block is disabled. |
Enumeration name: |
Disabling |
Enumeration value: |
4 |
Description: |
The transport system controller reports that the component is disabling. |
Issue |
Cause |
Solution |
---|---|---|
- |
Status message from the transport system controller. |
The function block is disabling. |
Enumeration name: |
Initializing |
Enumeration value: |
2 |
Description: |
The transport system controller reports that the component is initializing. |
The transport system controller is initializing.
Enumeration name: |
InputExceedsGplLimits |
Enumeration value: |
31 |
Description: |
The input exceeds the limit set in GPL. |
Issue |
Cause |
Solution |
---|---|---|
- |
Number of existing paths and/or vehicles used in the system exceeds the limit defined in the GPL. |
Verify whether ST_ControllerParameter.i_udiMaxNumberOfPaths is smaller or equal to GPL.Gc_udiMaxNumberOfPaths and ST_ControllerParameter.i_udiMaxNumberOfVehicles is smaller or equal to GPL.Gc_udiMaxNumberOfVehicles. If not, increase the respective values in the GPL. |
Enumeration name: |
MovementDirectionUnknown |
Enumeration value: |
21 |
Description: |
The direction of the movement cannot be interpreted. |
Issue |
Cause |
Solution |
---|---|---|
- |
A command to move a vehicle to a new destination uses an undefined parameter value. |
Use only existing direction choices in ET_MovementDirection. |
Enumeration name: |
PathCommandUnknown |
Enumeration value: |
18 |
Description: |
The path command is indeterminable. |
Issue |
Cause |
Solution |
---|---|---|
- |
It was attempted to send an unsupported command to a path. |
Make sure to send only supported commands. The supported commands are defined in ET_PathCommand. |
Enumeration name: |
PathRejectedCommand |
Enumeration value: |
29 |
Description: |
A command to a path has been rejected. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
PathResponseInvalid |
Enumeration value: |
13 |
Description: |
The response from the transport system controller contradicts the expected behavior: A command to a path has resulted in an invalid response from the transport system controller. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
PathResponseUnexpected |
Enumeration value: |
24 |
Description: |
The response from the transport system controller is out of context. A command to a path has resulted in an inappropriate response. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
PathResponseUnknown |
Enumeration value: |
14 |
Description: |
The response from the transport system controller cannot be interpreted: A command to a path has resulted in an inappropriate response. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
PidSetUnknown |
Enumeration value: |
20 |
Description: |
The configuration of the PID set cannot be interpreted. |
Issue |
Cause |
Solution |
---|---|---|
- |
An unsupported set of PID values has been used in an attempt to move a vehicle to a new position. |
Use only the following, supported values: 0 - unloaded PID set and 1 - loaded PID set |
Enumeration name: |
ResponseTypeUnexpected |
Enumeration value: |
23 |
Description: |
The response type of the transport system controller response is out of context. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
ResponseTypeUnknown |
Enumeration value: |
26 |
Description: |
The response type of the transport system controller response cannot be interpreted. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
ResponseValueUnknown |
Enumeration value: |
27 |
Description: |
The response type contains an inappropriate value. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
StateUnknown |
Enumeration value: |
16 |
Description: |
The state cannot be interpreted. |
Issue |
Cause |
Solution |
---|---|---|
- |
An error was detected during execution. |
Contact your Schneider Electric support representative. |
Enumeration name: |
TimeoutDuringBootOperation |
Enumeration value: |
33 |
Description: |
A timeout occurred during the boot operation. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system controller is unable to complete its initialization. |
Increase the default value of i_timBootOperationTimeout in ST_ControllerParameter to allow the transport system controller more time to complete initialization. |
TimeoutDuringControllerResponse
Enumeration name: |
TimeoutDuringControllerResponse |
Enumeration value: |
34 |
Description: |
A timeout occurred while waiting for the transport system controller to respond. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system controller does not react. |
Increase the default value of i_timControllerResponseTimeout in ST_ControllerParameter to allow the transport system controller more time to respond to incoming commands. |
Enumeration name: |
TimeoutDuringPathReset |
Enumeration value: |
35 |
Description: |
A timeout occurred during path reset. |
Issue |
Cause |
Solution |
---|---|---|
- |
The system is unable to complete the command. |
Increase the default value of i_timControllerResponseTimeout in ST_ControllerParameter to allow the transport system controller more time to respond to incoming commands. |
TimeoutDuringSocketStatusVerification
Enumeration name: |
TimeoutDuringSocketStatusVerification |
Enumeration value: |
32 |
Description: |
A timeout occurred during the socket status verification. |
Issue |
Cause |
Solution |
---|---|---|
- |
After establishing a connection to the transport system controller via TCP/IP socket, the connection status has to be verified. An error was detected during execution. |
Contact your Schneider Electric support representative. |
Enumeration name: |
UnableToSendRequest |
Enumeration value: |
8 |
Description: |
Unable to send commands to the transport system controller. |
Issue |
Cause |
Solution |
---|---|---|
- |
An connectivity error has been detected. |
Verify network cables and connectivity. If the error persists, contact your Schneider Electric support representative. |
Enumeration name: |
UnableToVerifyConnected |
Enumeration value: |
22 |
Description: |
Unable to verify if connected to host. |
Issue |
Cause |
Solution |
---|---|---|
- |
After establishing a connection to the transport system controller via TCP/IP socket, the connection status has to be verified. An error was detected during execution. |
Contact your Schneider Electric support representative. |
Enumeration name: |
VehicleCommandUnknown |
Enumeration value: |
19 |
Description: |
The command is not supported. |
Issue |
Cause |
Solution |
---|---|---|
- |
There has been an attempt to make a vehicle execute an undefined command. |
Make sure to use only supported commands. The supported commands are defined in ET_VehicleCommand. |
Enumeration name: |
VehicleResponseInvalid |
Enumeration value: |
12 |
Description: |
The response of the vehicle contradicts the expected behavior. |
Issue |
Cause |
Solution |
---|---|---|
- |
The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
VehicleResponseUnexpected |
Enumeration value: |
25 |
Description: |
The response of the vehicle is out of context. |
Issue |
Cause |
Solution |
---|---|---|
- |
Received data from more vehicles than expected. |
Verify that i_udiNumberOfVehicles in ST_ControllerParameter contains the number of existing vehicles in the system. |
Enumeration name: |
VehicleResponseUnknown |
Enumeration value: |
15 |
Description: |
The response of the vehicle cannot be interpreted. |
Issue |
Cause |
Solution |
---|---|---|
- |
Received data about unconfigured vehicle element. The transport system does not respond as expected. |
Contact your Schneider Electric support representative. |
Enumeration name: |
Working |
Enumeration value: |
3 |
Description: |
The component is operational. |
FB_Connection is operational. This means the POU is capable of accepting commands to be sent to the transport system controller.