Switched Dual Channel
In a switched dual channel communications setup, the outstations communicate with the Geo SCADA Expert server via one of two Direct Channels. The outstations are grouped into a Switched Outstation Set and they all use the same direct channel at any given time. Both direct channels are associated with the Switched Outstation Set (see Defining Channel Settings for a Switched Set). The Set’s configuration Form is used to specify which channel is deemed to be the ‘Preferred Line’ (channel).
The channel that the Geo SCADA Expert server uses to communicate with the outstations depends on:
Channel State
If Geo SCADA Expert deems that the channel being used by the outstations has failed, providing that the other channel:
- was healthy when it was last used by the outstations
or:
- has not been used by the Outstation Set since system or driver start-up
Geo SCADA Expert will automatically switch all of the outstations onto that other channel, to help ensure that communications and data retrieval continue. With Switched Outstation Sets, you can specify the number of outstations that Geo SCADA Expert is to detect as failed before automatic switching occurs. However, should Geo SCADA Expert detect that the currently used channel has failed, it will switch the outstations to the other channel regardless of the number of outstations that it has detected as failed on the current channel.
If the other channel was last reported to be in a failed state when used by the outstations and the channel that the outstations are currently using is reported as failed or is taken out of service, no automatic switching will occur. Instead, you need to use the Switch Line pick action to switch the outstations to the other channel. For more information, see below.
If the channel that the outstations are using is taken out of service, Geo SCADA Expert will automatically switch all of the outstations onto the other channel, providing that the other channel is In Service. This will occur regardless of the number of outstations that Geo SCADA Expert has detected as failed on the current channel.
Geo SCADA Expert will automatically switch all of the outstations onto that other channel, to help ensure that communications and data retrieval continue. With Switched Outstation Sets, you can specify the number of outstations that Geo SCADA Expert is to detect as failed before automatic switching occurs. However, should Geo SCADA Expert detect that the currently used channel has failed, it will switch the outstations to the other channel regardless of the number of outstations that it has detected as failed on the current channel.
If the other channel was last reported to be in a failed state when used by the outstations and the channel that the outstations are currently using is reported as failed or is taken out of service, no automatic switching will occur. Instead, you need to use the Switch Line pick action to switch the outstations to the other channel. For more information, see below.
If the channel that the outstations are using is taken out of service, Geo SCADA Expert will automatically switch all of the outstations onto the other channel, providing that the other channel is In Service. This will occur regardless of the number of outstations that Geo SCADA Expert has detected as failed on the current channel.
Outstation Set Configuration
You configure a Switched Outstation Set so that one direct channel is preferred to another (see Defining Channel Settings for a Switched Set). The Geo SCADA Expert server attempts to use the preferred channel first.
Outstation State
If the number of failed outstations in the Outstation Set exceeds a defined limit (as specified on the Outstation Set’s Form), Geo SCADA Expert automatically switches communications to the alternate channel. The exception to this is if the other channel was in a failed state when last used by the outstations in the set. In such a situation, you need to use the Switch Line pick action to switch the outstations to the other channel. You might want to consider incorporating the Switch Line pick action into, for example, a Structured Text Program that runs in the background and checks the state of several ‘nominated’ outstations—for more information, see below.
Any action that causes the outstations to use a particular channel
For example, an operator action, such as a Switch Line pick action to instruct the Geo SCADA Expert server to use an alternate channel, or a Schedule that instructs the Geo SCADA Expert server to switch between the available channels on a regular basis. (Scheduled switching allows you to check that both channels are in working order. We recommend that you set up Scheduled switching on your system to periodically check that both channels continue to remain fully functional (see Using Schedules to Automate Regular Functions).)
Communications via a ‘Healthy’ direct channel can be reported as failed when one or more outstations are disconnected, cables are damaged, there is signal interference, or the communications equipment is damaged or faulty. By switching channels, the Geo SCADA Expert server may be able to establish communications and avoid the detected problems.
Outstations that use switched dual channels are expected to communicate with Geo SCADA Expert via the ‘preferred’ channel whenever that channel is healthy.
Should Geo SCADA Expert determine that the preferred channel has failed, it will switch the outstations to the other (‘backup’) channel (providing that channel is deemed to be healthy). You should then investigate the failure of the ‘preferred’ channel and, if possible, rectify the problem. Once rectified, use the Switch Line pick action to switch the outstations back to using the preferred channel.
Alternatively, you could use Structured Text to produce a program that periodically checks whether Geo SCADA Expert has detected that one or more nominated outstations have failed and if so:
- Automatically ‘line hunts’ for whichever channel becomes healthy first
- Switches the outstations to use that channel.
(The state of a channel will only update when Geo SCADA Expert has successfully communicated via that channel. Once you have rectified a problem that Geo SCADA Expert has detected with a channel, that channel’s state will remain failed until Geo SCADA Expert has attempted to use that channel. Be aware that a channel’s state is independent of any outstations that are attached to it—for the state of a channel to go healthy, it merely has to receive a validly framed unsolicited or solicited message for that protocol. As such, the channel state merely indicates the state of the port local to the server, whereas an outstation’s state indicates the state of the communications path between the outstation and the Geo SCADA Expert server.)
For an example program, see Switched Dual Channel.
Example 1 - An Example Switched Dual Channel Setup
Four Direct outstations are configured to communicate in a switched dual channel setup. They are associated with a Switched Outstation Set. The outstation set’s configuration specifies that the outstations communicate via Channel A or Channel B.
The Geo SCADA Expert server attempts to establish communications with the outstations via Channel A. The channel is ‘Healthy’ but the Geo SCADA Expert server cannot establish communications with the first outstation as there is signal interference. The Geo SCADA Expert server switches to the alternate channel (Channel B) and requests data from each outstation.
All of the outstations communicate via Channel B as the switched dual channel setup only allows the outstations to communicate via one of the two channels.
Example 2 - Use an ST Program to Switch Channels Automatically
Four Direct outstations are associated with a Switched Outstation Set and communicate in a switched dual channel setup. The outstations in the set use Channel A as the preferred communications channel.
Geo SCADA Expert detects that the line specified as Channel A has failed. Geo SCADA Expert switches outstation communications to the ‘backup’ channel, Channel B.
A Structured Text program continuously runs in the background. The program monitors the state of two ‘nominated’ outstations on the switched set (outstations 1 and 2). Once Geo SCADA Expert has detected that Channel A has failed, the Structured Text program periodically attempts to ‘toggle’ between the channels.
Engineers investigate the reported failure of Channel A and rectify the problem.
The next time that the Structured Text program attempts to ‘toggle’ between the channels, it detects that Channel A has recovered and uses the set’s Switch Line pick action to switch the outstations back to communicate via that channel.
The syntax used for the Structured Text program is based on the following:
PROGRAM AutoSwitchToChannelA
METHOD
SwitchedLine AT %M(.Switched Set.SwitchLine):DINT;
END_METHOD
VAR
RTU1state AT %M(.Outstation 1.State):BYTE;
RTU2state AT %M(.Outstation 2.State):BYTE;
END_VAR
VAR
RTU1Failed : BOOL;
RTU2Failed : BOOL;
TOGGLE : DINT :=0;
END_VAR
RTU1Failed := RTU1state = 3 OR RTU1state = 12;
RTU2Failed := RTU2state = 3 OR RTU2state = 12;
IF RTU1Failed AND RTU2Failed THEN
SwitchedLine(TOGGLE);
END_IF;
END_PROGRAM
where:
‘.Switched Set’
is the name and path of the outstation set ‘.Outstation n’
is the name and path of each nominated outstation
The program checks whether both outstations are in the Failed state (3), or in the Healthy, A Failed state (12) and if so, uses the set’s SwitchLine method to toggle the lines.
Further Information
Structured Text programs and the syntax that Geo SCADA Expert supports: see the Geo SCADA Expert Guide to Logic.
Geo SCADA Expert naming conventions and the arguments that particular database fields and methods support: see the Database Schema.