<< Click to Display Table of Contents >>

Selecting this menu item will open the connection settings dialog (Figure 1).

 

parameters-window

Figure 1: COM port settings

 

COM port

 

Port - COM port number. All possible options are displayed in the list. If you check the "Create virtual serial port" checkbox, the program will create a port with the specified number.

 

Note: COM port settings that you can see below are intended for a physical COM port only.

 

The parameters baud rate, bits, parity, and stop bits let you define the data transfer rate, the number of data bits, parity, and the number of stop bits, respectively.

 

To define a custom data rate, click the "Add custom" button. When a dialog box opens, enter the data rate in bauds, and click "OK." The new data rate will be added to the list.

 

RS 485 interface mode - This option enables the automatic control mode (using the RTS signal). When transmitting data, the program will always set this option active. It may be necessary for RS232-RS485 hardware converters.

 

COM flow control

 

parameters-window-2

Figure 2: Hardware flow control settings

 

Hardware flow control

 

If hardware flow control settings are empty (by default), hardware flow control is disabled. You can combine settings to enable hardware flow control.

 

"Data reception control" stops data transmission by the remote device when the local input buffer is full. "Data transmission control" stops data transmission by your device when the remote device’s input buffer is full.

 

To activate data reception control, check the "Use RTS" or "Use DTR" checkboxes. If this feature is active, the RTS or DTR modem control signals are suspended when the amount of incoming data reaches 90 percent of the buffer size. The remote device must recognize these signals and suspend data transmission while the signals are in a low state.

 

When the applications receive the characters, the buffer use will be reduced to not exceed 10 percent of the buffer size. When that happens, the modem control signals will resume. The remote device must recognize these signals and resume sending data.

 

To activate data transmission control, check the "Require CTS" or "Require DSR" checkboxes. If one or both of these options are turned on, the Windows communication driver will not send data if the remote device does not provide the respective modem state signal (CTS or DSR). The remote device must resume and suspend these signals when it is necessary to control the data flow.

 

Please note that data flow control using RTS and CTS is more popular than using DTR and DSR.

 

Software flow control

 

This subprogram provides one or both automatic software flow control options based on the value considered as a property.

 

"Data reception control" stops data transmission by the remote device when your local input buffer is full. "Data transmission control" stops data transmission by your device when the remote device’s input buffer is full.

 

To activate data reception control, set "On receiving" or "Both" for the "Type" property. If this control is active, Xoff characters will be sent when the amount of incoming data reaches 10 percent of the buffer size. The remote device must recognize the signal and suspend sending data.

 

When the applications receive the characters, the buffer use will be reduced to not exceed 10 percent of the buffer size. At this moment, Xon characters will be sent again. The remote device must recognize these signals and resume sending data.

 

To activate data reception control, set "On transmitting" or "Both" for the "Type" property. In that case, 10 percent or 90 percent of the buffer size will not be used, respectively. If data transmission control is active, the communication driver will suspend sending data each time a Xoff character is received. The driver will not resume sending data until it receives a Xon character or until the user sets "None" for the "Type" property.

 

Software flow control can be set for receiving data, sending data, or both. However, not to use a lot of devices for sending data, set "Receive" for the "Type" property. If data transmission control is active, the remote device (in this case, your device) can send special codes to signal that it suspends or resumes data transmission. By default, the hexadecimal character 0x11 received from the remote device signals the COM port driver to start receiving data, and the hexadecimal character 0x13 signals to finish receiving data.

 

Input/output buffer size - the size of the program’s internal buffer. Some COM port drivers may not support the default buffer size. In that case, set a smaller buffer size.

 

IP settings

 

parameters-window-3

Figure 3: IP settings

 

Protocol types

 

TCP - a reliable protocol, probably the one most widely used in IP networks. The advantage of using this protocol is its ability to maintain and control a connection between computers. TCP also inherently supports data integrity checking. Some of this protocol’s drawbacks are its data transmission redundancy and additional time spent establishing a connection.

 

UDP - a protocol that does not require establishing a connection for data transmission. Like TCP, UDP works as the upper layer in IP networks. But unlike TCP, UDP doesn’t help to deliver data and doesn’t have any built-in error controls. But this protocol allows to directly send and receive data packets, while applications can check data integrity on their own and, if necessary, resend data. UDP can be used, for example, to send small multicast packets. When using this protocol, applications "send and forget."

 

Connection

 

In Tcp Com Bridge, each connection can work as:

 

1.Client. You need to specify the remote computer's IP address and port that runs the TCP/IP server that you want to connect to. The IP address you enter while configuring Tcp Com Bridge can also be a domain name (like www.yourserver.com), or a computer name in the local network. For example, to connect to a computer named "Plant1" in the local network, you can simply enter "Plant1" in the IP address input field, instead of the proper IP address. That may be handy for configuring Tcp Com Bridge as a client if IP addresses in your network are assigned dynamically. So it may be easier to use a computer name instead of an IP address.
2.Server. In this mode, you need to specify the computer's IP address on which the program runs and a port to listen to. If your computer has multiple network adapters (network interface cards), Tcp Com Bridge will display a list of IP addresses for each network interface card (NIC) installed on your computer. In that case, select the IP address of the network interface that you want to use. For Tcp Com Bridge to operate as a server, you must assign it at least one network card with an IP address. In Windows, TCP/IP may be configured for automatic assignment of an IP address for the computer. In that case, you need to ask your system administrator to assign your computer a static IP address and allocate that IP address to the selected network interface. You can also enter 0.0.0.0 as an IP address to make the programs listen to all IP addresses assigned to the computer.

 

IP address and port - The address and port of a remote server (in the client mode) or a local IP address and port (in the server mode).

 

Sending timeout - You can set a time interval for "grouping" data to send all of them in one IP packet. Doing that can speed up sending data if the COM port frequently receives small data portions.

 

The following settings apply only to TCP/IP when the server or client mode is used:

 

TCP keep-alive mode - If this option is turned on, the program will be sending special data packets at the specified interval. Suppose the client (or the server) doesn't respond during the specified timeout. In that case, the program will automatically break the connection as the lack of response indicates a loss of connection with the client (or the server). If you set the "System" keep-alive mode, the program will use interval and timeout values predefined in Windows.

 

Buffer data if TCP/IP port closed - If you turn on this option, the program will put all data received from the COM port into a temporary, internal buffer whose size you can define via the "COM port" tab. When the connection is reestablished, the program will first send the data from the buffer.

 

Server mode

 

These settings (see Figure 4) only apply to the server mode.

 

parameters-window-4

Figure 4: Additional server settings

 

Max clients - You can limit the number of clients simultaneously connected to the server. That lets you optimize the server load if there are too many clients. Zero means that the number of connections is not limited.

 

Allowed IP addresses - This option is active in the server mode and lets you define one or more IP addresses allowed to connect to the server. Any connection attempts originating from other IP addresses will be rejected. This setting is very useful if you transmit data over the Internet or if the server is connected to a big corporate network. You can enter multiple allowed addresses, one address per line. If you leave the field empty, Tcp Com Bridge will accept connection attempts originating from any IP address.

 

The IP COM and COM IP settings let you select the data transfer mode from IP to the COM port and vice versa. You can block data transfer in one or both directions.

 

Enable UPnP - the UPnP function enables auto-discovery of an internet gateway in your local network. If the program finds the gateway, it will send a command to redirect data for the current computer's configured IP port.

 

Special mode - in this mode, the program can create a bridge connection between two TCP clients. One TCP client connection should be initiated from the current computer. In this case, the program provides data exchange between two TCP clients, and the program does not send data to a COM port. This mode allows you to send data from an application that can work in the TCP client mode to a remote computer with a dynamic IP address or behind NAT.

 

Client mode

 

Using these settings (see Figure 5), you can allow or forbid data transfer in the client mode.

 

parameters-window-5

Figure 5: Additional client settings