A contact pattern is a character text string that represents the state of the digital points controlled and monitored by the Device Control block. You can use a contact pattern to:
- Monitor the digital points specified in the Input box.
- Control the digital points specified in the Output box.
- Specify the Initial Value of the digital points specified in the Output box when SAC is first started.
Each letter in a contact pattern corresponds to an output or input address defined in the block's dialog box. The following table lists and describes the characters used in building the contact pattern.
The letter... |
Represents... |
O |
An open digital point. |
C |
A closed digital point. |
X |
The current state of a digital point. Use this letter if an output address is not defined or if a particular digital point's state is immaterial. |
You can use contact patterns in conjunction with the Device Control block's programming statements. Programming statements monitor and control the digital points specified as input and output addresses. You can enter up to 12 programming statements. Each statement can be up to 34 characters long.
For example, to control the state of the digital points specified in the Output Addresses column you might enter a contact pattern similar to the following:
OUTPUT CCOOXXCO
The following table identifies the correspondence between each digital address specified in the Output Addresses column and the eight letters in the sample contact pattern above.
Output Address |
Contact Pattern |
07 |
First character (C) |
06 |
Second character (C) |
05 |
Third character (O) |
04 |
Fourth character (O) |
03 |
Fifth character (X) |
02 |
Sixth character (X) |
01 |
Seventh character (C) |
00 |
Eighth character (O) |
You can also use a contact pattern to monitor the state of the digital points specified in the Input Addresses box:
The correspondence between each digital address specified in the Input Addresses box and the 16 letters in the contact pattern is similar to the preceding table. The left-most letter corresponds to the top address, 15, and the letter on the far right corresponds to the bottom address, 00.