Applies To:
  • CitectSCADA

Summary:
Some applications may need control of serial port control lines to raise and lower these.

Until now, this was not possible from cicode.

Some uses of the COMX driver via a third party equipment, need the COMX driver

to restart after faults.


Solution:
New options have been added to the COMX driver.

-e

When the -e option is added to the driver Special Options (in the Ports form) when COMWrite can be used

to change the output signal lines. The format is "~EIAXXXyXXXy".

e.g.

FUNCTION SetRTS()
INT hPort;
STRING buffer = "~EIARTS1";
INT number= 8
    
hPort = ComOpen("PORT1_BOARD1", 0);
    
ComWrite(hPort, buffer, number, 15)
    
ComClose(hPort);

END

sets RTS high

Full options for XXXy are :

SWF0 // Simulate XOFF received
SWF1 // Simulate XON received
RTS1 // Set RTS high
RTS0 // Set RTS low
DTR1 // Set DTR high
DTR0 // Set DTR low
BRK1 // Set the device break line
BRK0 // Clear the device break line

-nt

With some serial interfaces, line faults can cause the COMX read thread to shutdown. This meant the driver would

not recover after the fault. With the -nt option (no terminate), the thread is NOT shutdown. This allows the system to recover.

-nts

Do not terminate at startup if errors occur. Keep retrying to init the driver .

For this to work, the driver must to a COMReset in its InitUnit() code, or Cicode should be

doing this.

Covers NCRs 15527, 15528, 15806, 17482

 

Keywords:
 

Attachments