COMn
Synopsis
[ComPorts] COMn=a,b
Description
The [ComPorts] section contains an entry for each COM port. These entries define the default settings for COM ports and enable remote logins to InterSystems IRIS® data platform through locally connected or modem-connected serial ports. The number n refers to the physical COM port number. If the [ComPorts] section contains enough entries, n can be multiple digits.
The parameters within COMn apply to Windows platforms only.
Each COMn entry provides two comma-separated values that define the following default settings for COM port number n:
-
a — A set of COM port control parameters (data bits, parity, etc.) in byte-positional format. Byte position is one-based. From left to right:
Byte Position Description Byte 1: Modem Control
-
'1' Use modem control
-
'0' Do not use modem control
-
' ' No change to modem control (default)
Byte 2: Data Bits
-
'5' 5 data bits
-
'6' 6 data bits
-
'7' 7 data bits
-
'8' 8 data bits
-
' ' No change to bit size (default)
Byte 3: Parity
-
'0' No parity
-
'1' Odd parity
-
'2' Even parity
-
'3' Mark parity
-
'4' Space parity
-
' ' No change to the parity setting (default)
Byte 4: Stop Bits
-
'1' 1 stop bit
-
'5' 1.5 stop bits
-
'2' 2 stop bits
-
' ' No change to the stop bit setting (default)
Byte 5: Flow Control
-
'X' Use Xon/Xoff flow control
-
'C' Use CTS/RTS flow control
-
'D' Use DSR/DTR flow control
-
' ' No change to flow control (default)
Byte 6: DTR Setting
-
'0' Disable DTR (set it off, keep it off)
-
'1' Enable DTR (set it on, keep it on)
-
' ' No change to the DTR state (default)
Byte 7: $ZA Error Reporting
-
-
b — The baud rate. If not supplied, the default baud rate is 19200.
Examples
The following example of a [ComPorts] section shows how spaces can be used as values within the COM port control parameter:
[ComPorts]
COM1= ,19200
The first example uses all defaults for the COM port control parameters by providing seven spaces before the comma separator. The meaning is: No change to modem control, no change to bit size, no change to parity setting, no change to stop bit setting, no change to Flow control, no change to DTR state, no change to $ZA error reporting.
[ComPorts]
COM2=1801X11,19200
The second example provides a value of 1801X11 for the COM port control parameters. The meaning is: Use modem control, 8 data bits, no parity, 1 stop bit, use Xon/Xoff flow control, enable DTR, enable $ZA error reporting.
Changing This Parameter
You can change this parameter in the following ways:
-
Edit the CPF in a text editor (as described in Editing the Active CPF).
-
Use the Config.ComPortsOpens in a new tab class.