Create an application, running as a Windows service, which redirects data arriving onto a predefined set of serial COM-ports to a TCP/IP point over the network. Each TCP packet should have the number of the read COM port preprended as the first byte of the TCP data. This functionality must be supported both as a client (connected to a IP/TCP address) or as a server (listening on a local TCP port).
The project contains two main parts:
1.- A configuration utility, which allows to configure the set of COM ports to be checked and port/IP address of the server to which application will connect if started as a client or port if application runs as a server. Along with previous setting the configuration utility should allow:
-- to set the BAUD rate for all the COM-ports (drop-down menu),
-- to set the flow control for ports
-- to set parity bits
-- to set stop-bits
2.- An application (central part of the project). The application should support launching in two different ways: as a server or as a client.
-- In case if application is executed as server, then port with number taken from the configuration file will be used for listening to the incoming connections.
---- In case of execution as a client, the application will connect to the configured port and IP address and starts data transmission to that remote connection.
---- The application should check the data on COM ports configured with the configuration utility. If there is any data on the port, the application transmits them from the COM-port data to the network. Each packet should have the number of the port in the beginning of the transmission. The port number should be binary (one byte length) and possibly in human-readable ( ASCII encoded ) two-bytes width number with leading zero.