• Computer serial port. What is a COM port? Device, COM port control COM port modes

    A modern personal computer would never have gained such enormous popularity if it only performed computing functions. The current PC is a multifunctional device, with the help of which the user can not only carry out any calculations, but also perform a lot of different things: print text, control external devices, communicate with other users using computer networks, etc. All this enormous functionality is achieved with the help of additional devices - peripherals, which are connected to a personal computer through special connectors called ports.

    Personal computer ports

    Port- an electronic device running directly on the PC motherboard or on additional boards installed in a personal computer. The ports have a unique connector for connecting external devices – peripherals. They are intended for data exchange between a PC and external devices (printers, modems, digital cameras, etc.). Quite often, in the literature you can find another name for ports - interfaces.

    All ports can be divided into two groups:

    • External- for connecting external devices (printers, scanners, plotters, video devices, modems, etc.);
    • Domestic- for connecting internal devices (hard drives, expansion cards).

    External ports of a personal computer

    1. PS/2- port for connecting a keyboard;
    2. PS/2- port for connecting a mouse;
    3. Ethernet- port for connecting a local network and network devices (routers, modems, etc.);
    4. USB- port for connecting external peripheral devices (printers, scanners, smartphones, etc.);
    5. LPT- parallel port. Serves to connect now outdated models of printers, scanners and plotters;
    6. COM- RS232 serial port. Used to connect devices such as dial-up modems and old printers. Now outdated, practically not used;
    7. MIDI- a port for connecting game consoles, midi keyboards, musical instruments with the same interface. Recently it has been practically replaced by the USB port;
    8. Audio In- analog input for linear output of audio devices (tape recorders, players, etc.);
    9. Audio Out- analog audio signal output (headphones, speakers, etc.);
    10. Microphone- microphone output for connecting a microphone;
    11. SVGA- a port for connecting video display devices: monitors, modern LED, LCD and plasma panels (this type of connector is obsolete);
    12. VID Out- the port is used to output and input low-frequency video signals;
    13. DVI- a port for connecting video display devices, more modern than SVGA.

    Serial port (COM port)

    One of the oldest ports, installed in PCs for more than 20 years. You can find it quite often in literature classic name – RS232. Data exchange using it occurs in serial mode, that is, the transmission and reception lines are one-bit. Thus, information that is transmitted from a computer to a device or vice versa is divided into bits that follow each other sequentially.

    The data transfer rate provided by this port is not high, and has a standardized range: 50, 100, 150, 300, 1200, 2400, 4800, 9600, 14400, 38400, 57600, 115200 Kbps.

    A serial port was used to connect such “slow” devices to a PC as the first printers and plotters, dial-up modems, mice, and even to communicate between computers. No matter how slow its speed, in order to connect the devices to each other, only three wires were required - the data exchange protocol was so simple. It is clear that for full operation a larger number of conductors in the cord was required.

    Today, the serial port is practically no longer used and is completely supplanted by its younger, but also faster “brother” - USB port. It should be noted, however, that some manufacturers still equip their motherboards with a COM port. However, the name itself - “serial port” is still used by software developers. For example, Bluetooth devices and cell phone ports are often presented as a “serial port.” This may be a little confusing, but this is done because they also transfer data serially, but at a higher speed.

    If for some reason you may need a COM port, but your PC does not have one, then for this purpose you can use an adapter that connects to a modern USB port, which is available on all modern PCs, and on the other hand, such an adapter has serial port connector. There is, however, one limitation: if the software accessed directly the hardware of a real COM port, then it will not work with such an adapter. In this case, you need to purchase a special board that is installed inside your PC.

    Structurally, the PC serial port has a male connector (with protruding pins):


    Today, the 25-pin serial port connector has practically fallen out of use and has not been installed on a PC for several years. If the manufacturer provides the motherboard with a COM port, then it is a 9-pin DB9 connector.

    It is an interface for connecting devices such as printers, scanners and plotters.

    Allows you to simultaneously transmit 8 bits of data, albeit in one direction - from the computer to the periphery. In addition to this, it has 4 control bits (as with data bits, control bits are transferred from the PC to the external device), and 4 status bits (these bits can be “read” by the computer from the device).

    In recent years, the LPT port has been improved, and it has become two-way, that is, it has become possible to transmit data bits through it in both directions. Today it is outdated and practically not used, although motherboard manufacturers still include it in its composition.

    Enthusiasts and radio amateurs often use this port to control any non-standard devices (crafts, etc.).

    USB interface

    USB– this is an abbreviation of the full name of the port – universal serial bus (“universal serial bus”).

    It is one of the most widely used ports on a personal computer today. And this is no coincidence - its technical characteristics and ease of use are truly impressive.

    The data exchange speed for the USB 2.0 interface can reach 480 Mbit/s, and for the USB3.0 interface – up to 5 Gbit/s (!).

    Moreover, all versions of this interface are compatible with each other. That is, a device using interface 2.0 can be connected to a USB3.0 port (in this case, the port will automatically reduce the speed to the desired value). Accordingly, a device using a USB 3.0 port can be connected to a USB 2.0 port. The only condition is that if normal operation requires a speed higher than the maximum speed of USB 2.0, then the normal functioning of the peripheral device will not be possible in this case.

    In addition, the popularity of this port is also due to the fact that the developers included one very useful feature in it - this port can serve as a power source, for an external device connected to it. In this case, no additional unit is required to connect to the electrical network, which is very convenient.

    For the USB 2.0 port version, the maximum current consumption can reach 0.5A, and for the USB3.0 version – 0.9A. It is not recommended to exceed the specified values, as this will lead to failure of the interface.


    Developers of modern digital devices are constantly striving for minimization. Therefore, structurally, this port can have, in addition to a standard connector, also a mini-version for miniature devices - mini-USB. It has no fundamental differences from a standard USB port other than the design of the mini-USB connector itself.


    Almost all modern devices have a USB port for connecting to a PC. Ease of installation - the connected device is recognized by the operating system almost immediately after connection, making it possible to use such a port without special “computer” knowledge. Printers, scanners, digital cameras, smartphones and tablets, external drives are just a small list of peripheral equipment that currently uses this interface. A simple principle - “plug and play” made this port truly a bestseller among all currently available personal computer interfaces.

    Fire-Wire port (Other names - IEEE1394, i-Link)

    This type of interface appeared relatively recently - since 1995. It is a high-speed serial bus. Data transfer rates can reach up to 400 Mbit/s in the IEEE 1394 and IEEE 1394a standard, 800 Mbit/s and 1600 Mbit/s in the IEEE1394b standard.

    Initially, this interface was designed as a port for connecting internal drives (SATA type), but the licensing policy of Apple, one of the developers of this standard, required payment for each controller chip. Therefore, today only a small number of digital devices (some models of cameras and video cameras) are equipped with this type of interface. This type of port never became widespread.



    The importance of this interface can hardly be overestimated; as a rule, it is what is used to connect a personal computer to a local network or to access the Internet in most cases. Almost all modern PCs, laptops and netbooks are equipped with an Ethernet port built into the motherboard. This is easy to verify if you examine the external connectors.

    To connect external devices, a special one is used, which has identical connectors at both ends. connectors – RJ-45, containing eight contacts.


    The cable is symmetrical, therefore, the order in which the devices are connected does not matter - any device of your choice can be connected to any of the identical cable connectors - a PC, router, modem, etc. It is marked with the abbreviation - UTP, common name is “twisted pair”. In most cases, for both home and office use, a cable of the fifth category, UTP-5 or UTP-5E, is used.

    The speed of data transmitted over an Ethernet connection depends on the technical capabilities of the port and is 10 Mbit/s, 100 Mbit/s and 1000 Mbit/s. It should be understood that this throughput is theoretical, and that in real networks it is somewhat lower due to the peculiarities of the Ethernet data transfer protocol.

    Also, you should keep in mind that not all manufacturers install high-speed chips in their Ethernet controllers, since they are very expensive. This leads to the fact that in practice, the actual data transfer speed is much lower than that indicated on the packaging or in the specification. As a rule, almost all Ethernet cards are compatible with each other and from top to bottom. That is, newer models that have the ability to connect at speeds of 1000 Mbit/s (1 Gbit/s) will work without problems with older models at speeds of 10 and 100 Mbit/s.

    To visually monitor the integrity of the connection, the Ethernet port has Link and Act indicators. Link indicator - lights green when the physical connection is correct and working, i.e. the cable between the devices is connected, it is intact, the ports are working. The second Act indicator (“activity”) is usually orange and flashes while transmitting or receiving data.

    Internal ports of a personal computer

    As mentioned above, internal ports are designed for connecting peripherals such as hard drives, CDs and DVD-ROMs, card readers, additional COM and USB ports, etc. Internal ports are located either on the motherboard, or on additional expansion cards installed in the system bus.

    A now outdated interface for connecting older models of hard drives (“hard drives”, HDD). After the creation of the SATA interface, it was called the PATA interface, or ATA for short. PATA – ParallelAdvanced Technology Attachment. This parallel data transfer interface for connecting drives was developed in mid-1986 by the now famous company WesternDigital.


    Depending on the manufacturer, the motherboard may contain from one to four IDE channels. Modern manufacturers, as a rule, leave only one IDE port for compatibility, and recently it has also been excluded from the motherboard, having been completely replaced by the modern SATA interface.

    The data transfer speed in the latest version of the EnhancedIDE interface can reach 150 Mbit/s. Devices are connected using an IDE cable having 40 or 80 cores for the old or new interface type, respectively.



    Typically, you can connect up to two devices simultaneously to one IDE port using a single cable. In this case, using jumpers on the drives that determine the “seniority” of devices operating in pairs, the operating mode is selected - on one device - "master", and for the other "subordinate" (slave).

    You can connect either the same type of device, for example, two hard drives or two DVD-ROMs, or different devices in any combination - DVD-ROM and HDD or CD-ROM and DVD-ROM. The connector for connection does not matter, you should just pay attention that the two connectors for connecting peripherals are shifted for convenience to one of the ends of the cable.

    You should also keep in mind that by connecting a “fast” device designed for an 80-wire cable using an old 40-wire cable, you will greatly reduce the exchange speed. In addition, if one of the devices in a pair has an old (slow) ATA interface, then the data transfer speed in this case will be determined precisely by the speed of this device.

    If there are two IDE ports and two drives inside the PC, to increase the data exchange speed, you must connect each drive to a separate IDE port.

    This interface is a development of its predecessor, the IDE interface, with the only difference that, unlike its “older friend,” it is not a parallel, but a serial interface. SATA – SerialATA.

    Structurally, it has only seven conductors for its operation and a much smaller area of ​​​​both the connector itself and the connecting cable.


    The data transfer speed of this interface is significantly higher than the outdated IDE and, depending on the SATA version, is:

    1. SATARev. 1.0 – up to 1.5 Gbit/s;
    2. SATARev. 2.0 – up to 3 Gbit/s;
    3. SATARev. 3.0 – up to 6 Gbit/sec.

    Just like the IDE interface, the cord for connecting devices is “universal” - the connectors are the same on both sides, but unlike its “brother”, now using one SATA cable you can connect only one device to one SATA port.

    But there is hardly any need to be upset about this. Manufacturers made sure that the number of ports was sufficient for a wide variety of applications, installing up to 8 SATA ports on one motherboard. The third revision SATA port connector is usually bright red.

    Additional ports

    Most motherboards are equipped by manufacturers with an additional number of USB ports, and sometimes with another, additional COM port.


    This is done for the convenience of the user. Most modern desktop PC cases have USB connectors installed on the front panel for convenient connection of external drives. In this case, you do not need to reach to the back wall of the system unit and “get into” the USB connector, which is located on the rear panel.

    This connector is on the front panel and connects to an additional USB port installed on the motherboard. Among other things, the USB interfaces located on the rear panel may simply not be enough, due to the large number of peripheral devices, in this case you can purchase additional bracket with USB connectors and connect them to additional ports.


    All of the above applies to other ports installed on the motherboard. For example, a COM or FireWireIEEE1394 serial port may simply not be displayed on the back panel of a personal computer, but it is still present on the motherboard. In this case, it is enough to buy the appropriate cable and take it out.

    It would be technically incorrect to call these connectors ports, although the method of connecting additional cards to them is still somewhat similar to other conventional ports. The principle is the same - plug it in and turn it on. In most cases, the system will find the device itself and request (or install automatically) drivers for it.


    Such buses are used to install, for example, an external graphics card, a sound card, an internal modem, a video input card, and other additional expansion cards that allow the PC to expand its functions and capabilities.

    PCI and PCIe buses are incompatible with each other, so before purchasing an expansion card, you need to find out which system buses are installed on the motherboard of your PC.

    PCIex 1 and PCIex 16 are modern implementations of the older PCI bus, developed in 1991. But unlike its predecessor, it is a serial bus, and in addition, all PCIe buses are connected in a star topology, while the old PCI bus was connected in parallel to each other. In addition, the new tire has the following advantages:

    1. Possibility of hot replacement of boards;
    2. The bandwidth has guaranteed parameters;
    3. Control of data integrity during reception and transmission;
    4. Controlled energy consumption.

    PCI Express buses differ in the number of conductors connected to the slot, through which data is exchanged with the installed device (PCIex 1, PCIex2, PCIex 4, PCIex 8, PCIex 16, PCIex 32). The maximum data transfer speed can reach 16 Gbit/s.

    Computer + mobile phone: effective interaction Goltsman Viktor Iosifovich

    COM and USB ports

    COM and USB ports

    Ports are devices through which a computer can exchange information with external equipment. Strictly speaking, the ports themselves are microcircuits located inside the computer, and the connectors connected to them are located on the back wall of the system unit (Fig. 1.3).

    Rice. 1.3. Port connectors.

    First, a serial port appeared in computers. Otherwise it is called a COM port or RS-232. A cable consisting of several wires ending in a 9-pin connector is connected to the COM port. Information through this port is transmitted in the form of a sequence of electrical impulses. Through one wire (Tx) the computer transmits information to an external device, and through the other (Rx) it receives.

    The RS-232 standard has remained unchanged for over ten years. There are two serial ports on the computer motherboard – COM1 and COM2. On the back wall of any system unit there is at least one serial port connector (COM1). The second port (COM2) in modern computers is usually simply not located on the rear wall, although there is a connection block for it on the motherboard.

    It is recommended to connect devices to the serial port while the computer is turned off. In practice, this requirement is usually ignored, which sometimes leads to failure of either the connected device or the port itself.

    COM port settings can be configured as follows.

    1. Launch device Manager. To do this, click the button Start and select Control Panel. Double-click on the icon System. On the tab Equipment click the button Device Manager.

    2. Double click on the item COM and LPT ports.

    3. Select the port whose settings you want to change and run the command Properties. A window will open (Fig. 1.4).

    Rice. 1.4. Port parameters.

    On the tab Port Settings windows Properties: Serial port (COM2) Several options are available. Of these, we may need the first parameter Speed ​​(bit/s), which determines the speed at which the port is capable of transmitting and receiving data. The default is 9600 bps. It is assumed that any device connected to the port is capable of operating at this speed. However, many modern devices, including modems and data cables for cell phones, can exchange data with a computer at much higher speeds. Therefore, if the connected device is stable at a low transfer rate, you can try increasing the value to 57,600 or 115,200 bps - data will be transferred much faster.

    4. Select the desired port speed value from the list and click the button OK.

    Other serial port settings usually do not need to be changed. You can return all port settings to their original values ​​by clicking the button Restore defaults.

    USB bus ports (universal serial bus) are necessarily present in any modern computer (see Fig. 1.2). This standard for connecting external devices gradually replaced the serial port. Data here, as well as through the COM port, is transmitted over two wires. The third wire supplies the connected devices with a supply voltage of +5 V.

    The maximum data transfer speed through the USB port is almost 1000 times higher than through the serial port. True, when connecting a phone, which is a big “slow-witted”, this is unimportant. More importantly, the standard guarantees the possibility of “hot” connection of devices to USB ports while the computer is running. In addition, USB ports do not require configuration. IN Device Manager Displays information about the current consumed by each device connected to the USB ports.

    There are three types of USB connectors, differing only in shape and size (Fig. 1.5).

    A “regular” flat type A connector is used to connect the cable to the computer. The same connector is equipped with miniature adapters that are inserted directly into the USB port on the system unit. It is especially convenient to connect such an adapter when additional ports are located on the front panel of the system unit. If there are no USB connectors on the front panel, and it is difficult to get to the back of the computer every time, an extension cable with type A connectors on both ends will help.

    Rice. 1.5. USB connectors.

    Type B connector is used to connect the cable to peripheral devices: printers and modems.

    To connect to portable devices (phones, cameras), use a mini-USB or mini-B connector.

    From the book Computer + Mobile Phone: Effective Interaction author Goltsman Viktor Iosifovich

    COM and USB ports Ports are devices through which the computer can exchange information with external equipment. Strictly speaking, the ports themselves are microcircuits located inside the computer, and the connectors connected to them are located on the rear wall of the system unit (Fig.

    From the book PC Hardware [Popular tutorial] author Ptashinsky Vladimir

    Chapter 10 Expansion Buses: Slots and Ports Bus-bus-opa, bus-bus-nay... A once popular song about computers In previous chapters, we were introduced to the various internal and external components of a computer. Now let's look at what all these components are used for

    From the book DIY Linux server author

    1.7.6. Ports and daemons The further presentation of the material is based on the fact that you already know what a server is and what services you will have to configure. In the paragraph How the book is organized (clause 1.5), it was described in detail which chapters described the setup of a particular service. Right here

    From the book Self-instruction manual for working on a computer author Kolisnichenko Denis Nikolaevich

    2.2.8. Additional USB ports USB (Universal Serial Bus) - universal serial bus. Many devices are connected to USB: USB disks, digital cameras, digital video cameras, printers, scanners, modems, there are even USB keyboards and USB mice. It is clear that with such a variety

    From the book Asterisk™: The Future of Telephony Second Edition author Meggelen Jim Wang

    How to find FXO and FXS ports on the TDM400P board In Fig. Figure 4.1 shows the TDM400P board with FXS and FXO modules. The photo is black and white, so it is impossible to distinguish the colors, but number 1 is the FXS module, green, and number 2 is the FXO module, orange and red. In the lower right corner of the picture you can see

    From the book Mysteries and Secrets of the Computer author Orlov Anton A

    Chapter 10. Ports. Proxy. Firewall When most computer technology users see the word “port,” they usually associate it with abbreviations such as COM, LPT, PS/2. That is, simply the names of “sockets” where you can attach any peripheral

    From the book System Programming in Windows Environment by Hart Johnson M

    I/O Completion Ports Chapter 14 describes I/O completion ports, which provide another mechanism to avoid race conditions between threads by limiting the number of threads. I/O completion ports enable small

    From the book TCP/IP Architecture, Protocols, Implementation (including IP version 6 and IP Security) by Faith Sydney M

    CHAPTER 14 Asynchronous I/O and Completion Ports I/O operations are inherently slower than other types of processing. The reasons for this slowdown are the following factors: Delays due to time spent searching

    From the book Programming Technologies author Kamaev V A

    I/O completion ports I/O completion ports, supported only on NT platforms, combine the capabilities of overlapping I/O and independent threads and are most often used in server programs. To find out what requirements

    From the book The C Language - A Guide for Beginners by Prata Steven

    Example: Server Using I/O Completion Ports Program 14.4 is a modified version of the serverNP program (Program 11.3) that uses I/O completion ports. This server creates a small pool of server threads and a larger pool

    From the book Programming for Linux. Professional approach by Mitchell Mark

    From the book Laptop [secrets of effective use] author Ptashinsky Vladimir

    10.2.5 Application Ports The client must identify the service it wants to access. This is done through the specification of the host service's IP address and its TCP port number. Like UDP, TCP port numbers range from 0 to 65535. Ports range from 0 to 1023

    From the author's book

    6.4. SYSTEMS OF PROGRAMS EXCHANGING DATA THROUGH PORTS Such exchange is usually implemented during multiprocessor (multi-machine) processing. The port of each program represents a program for accumulating and verifying both input and output data in the corresponding

    From the author's book

    SYSTEM DEPENDENT FEATURES: I/O PORTS OF INTEL 8086/8088 MICROPROCESSORS Let's look at various input/output devices, because now we want to discuss the question of how to adapt the implementation of the C compiler to the requirements of a particular computer

    From the author's book

    7.3.4. Serial Ports The /proc/tty/driver/serial file contains configuration and statistical information about serial ports. These ports are numbered starting from zero. The setserial command also allows you to work with port settings, but the /proc/tty/driver/serial file, among other things,

    From the author's book

    Connectors and ports All modern laptops are equipped with USB ports, to which you can connect almost all modern peripheral devices. The USB 2.0 interface provides data transfer at speeds of up to 60 Mbit/s and is backward compatible with USB 1.1. This one is tricky

    Recently, the serial method of data transmission has been replacing the parallel one.
    You don’t have to look far for examples: the emergence of USB and SATA buses speaks for itself.
    Indeed, since a parallel bus is difficult to scale (lengthen the cable, increase the bus clock frequency), it is not surprising that technologies are turning their backs to parallel buses.

    Serial interfaces

    Today there are a great many different serial data transfer interfaces.
    In addition to the already mentioned USB and SATA, you can also recall at least two well-known standards RS-232 and MIDI (also known as GamePort).
    What they all have in common is the sequential transmission of each bit of information, or Serial Interface.
    There are a great many advantages of such interfaces, and the most important of them is a small number of connecting wires, and therefore a lower price.

    Data transfer

    Serial data transmission can be implemented in two ways: asynchronous and synchronous.

    Synchronous data transmission involves synchronizing the operation of the receiver and transmitter by including clock information in the transmitted signal or by using a special synchronization line.
    The receiver and transmitter must be connected by a special synchronization cable, which ensures that the devices operate at the same frequency.

    Asynchronous transmission involves the use of special bits that mark the beginning and end of data - a start (logical zero) and a stop (logical one) bit.
    It is also possible to use a special parity bit, which determines whether the number of one bits to be transmitted is even or odd (depending on the convention adopted).
    At the receiving end, this bit is analyzed, and if the parity bit does not correspond to the number of one bits, then the data packet is sent again.

    It is worth noting that such a check allows you to detect an error only if only one bit was transmitted incorrectly; if several bits were transmitted incorrectly, this check becomes incorrect.
    The sending of the next data packet can occur at any time after sending the stop bit, and, naturally, must begin with the start bit.
    Is anything clear?

    Well, if all computer technologies were simple, then any housewife would have long ago been creating new protocols in parallel with dumplings...
    Let's try to look at the process differently.
    Data is transmitted in packets, much like IP packets, along with the data there are also information bits, the number of these bits can vary from 2 to 3 and a half.
    And half?!
    Yes, you heard right, exactly half!

    The stop bit, or rather the transmitted signal corresponding to the stop bit, can have a duration longer than the signal corresponding to the one bit, but shorter than for two bits.
    So, a packet always starts with a start bit, which is always zero, followed by data bits, then a parity bit, and then a stop bit, which is always one.
    Then, after some arbitrary period of time, the march of the beats against Moscow continues.

    This method of transmission implies that the receiver and transmitter must operate at the same speed (well, or almost at the same speed), otherwise the receiver will either not have time to process the incoming data bits, or will mistake the old bit for a new one.
    In order to avoid this, each bit is gated, that is, sent synchronously with a special signal - a “strobe”, generated inside the device.
    There are a number of specific speeds for asynchronous devices - 50, 75, 110, 150, 300, 600, 1200, 2400, 4800, 9600, 19,200, 38,400, 57,600 and 115,200 bits per second.

    You've probably heard that the unit of measurement for data transfer speed is “baud” - the frequency of changes in line state, and this value will coincide with the data transfer speed only if the signal can have one of two values.
    If several bits are encoded in one signal change (and this occurs in many modems), the transmission speed and the line change frequency will be completely different values.

    Now a few words about the mysterious term “data packet”.
    A packet in this case refers to a set of bits transmitted between the start and stop bits.
    Their number can vary from five to eight.
    One might wonder why five to eight bits?
    Why not transfer, say, a kilobyte of data within a packet at once?

    The answer is obvious: when transmitting small data packets, we may lose by sending three service bits with them (from 50 to 30 percent of the data), but if the packet is damaged during transmission, we can easily recognize it (remember about the parity bit?) and quickly transmit him again.
    But it will be difficult to detect an error in a kilobyte of data, and it will be much more difficult to transmit it.

    An example of an asynchronous serial data transfer device is a computer COM port, a favorite modem designed by Trussardi, and a mouse connected to the same port, which stupid secretaries for some reason always try to put into PS/2.
    All these devices operate via the RS-232 interface, or rather via the asynchronous part of it, since the standard also describes synchronous data transfer.

    AMD Radeon Software Adrenalin Edition 19.9.2 Optional Driver

    The new AMD Radeon Software Adrenalin Edition 19.9.2 Optional driver improves performance in Borderlands 3 and adds support for Radeon Image Sharpening technology.

    Windows 10 Cumulative Update 1903 KB4515384 (Added)

    On September 10, 2019, Microsoft released a cumulative update for Windows 10 version 1903 - KB4515384 with a number of security improvements and a fix for a bug that broke Windows Search and caused high CPU usage.

    A special feature of this port compared to other “serial” technologies is the fact that there are no timing requirements between 2 bytes. There are timing requirements only between the bits of one byte (including start, stop and parity), the reciprocal of the time pause between the bits of one byte is called the baud rate - the baud rate. Also in this technology there is no concept of “package”.

    Other "serial" technologies, such as X.25, USB or Ethernet, have a "packet" concept, and impose strict timing requirements between all bits of a single packet.

    For this reason, in Cisco IOS terminology, this port was called async - in contrast to synchronous serial, i.e. X.25. For the same reason, the Windows module that implements PPP over this port is called AsyncMac.sys (the PPP standard separately describes the implementation of PPP, which uses the concept of “packet”, over a serial port that does not have this concept).

    Some industrial communications protocols impose strict timing requirements between serial port bytes. Such protocols are extremely difficult to implement in multitasking operating systems with weak real-time support, such as Windows, and therefore often require MS-DOS and outdated software from almost 20 years ago on the control computer.

    Purpose

    The most commonly used standard for the serial port of personal computers is RS-232C. Previously, the serial port was used to connect a terminal, later for a modem or mouse. It is now used to connect to, to communicate with hardware for the development of embedded computing systems, satellite receivers, cash registers, as well as with facility security system devices.

    Using a COM port, you can connect two computers using a so-called “null modem cable” (see below). It has been used since the days of MS-DOS for transferring files from one computer to another, in UNIX for terminal access to another machine, and in Windows (even modern ones) for a kernel-level debugger.

    The advantage of the technology is the extreme simplicity of the equipment. The disadvantage is low speed, large connector sizes, as well as often high requirements for the response time of the OS and driver and a high number of interrupts (one per half of the hardware queue, i.e. 8 bytes).

    Connectors

    On motherboards from leading manufacturers (for example, Intel) or ready-made systems (for example, IBM, Hewlett-Packard, Fujitsu Siemens Computers), the following symbol is used for the serial port:

    The most commonly used D-shaped connectors, standardized in 1969, are 9-pin and 25-pin (DB-9 and DB-25, respectively). Previously, DB-31 and round eight-pin DIN-8 were also used. The maximum transmission speed in the normal version of the port is 115,200 baud.

    Relevance

    There are standards for emulating a serial port over USB and over Bluetooth (this technology was largely designed as a “wireless serial port”).

    Nevertheless, software emulation of this port is still widely used today. For example, almost all mobile phones emulate a classic COM port and modem within themselves to implement tethering - computer access to the Internet via the phone’s GPRS/EGDE/3G equipment. In this case, USB, Bluetooth or Wi-Fi are used for physical connection to the computer.

    Also, software emulation of this port is provided to “guests” of VMWare and Microsoft Hyper-V virtual machines, the main purpose of which is to connect a Windows kernel-level debugger to the “guest”.

    Equipment

    The connector has contacts:

    DTR (Data Terminal Ready - readiness to receive data) - output on the computer, input on the modem. Indicates that the computer is ready to use the modem. Resetting this line causes an almost complete reboot of the modem to its original state, incl. hanging up (some control registers survive such a reset). On UNIX, this occurs when all applications have closed files on the serial port driver. The mouse uses this wire to receive power.

    DSR (Data Set Ready - readiness for data transfer) - input on the computer, output on the modem. Indicates that the modem is ready. If this line is at zero, then in some operating systems it becomes impossible to open the port as a file.

    RxD (Receive Data) - input on the computer, output on the modem. A stream of data entering a computer.

    TxD (Transmit Data) - output on the computer, input on the modem. A stream of data coming from a computer.

    CTS (Clear to Send - readiness to send) - input on the computer, output on the modem. The computer is required to pause data transmission until this wire is set to one. Used in the hardware flow control protocol to prevent overflow in the modem.

    RTS (Request to Send - request to send) - output on the computer, input on the modem. The modem is required to suspend data transmission until this wire is set to one. Used in hardware flow control protocol to prevent hardware and driver overflows.

    DCD (Carrier Detect - presence of carrier) - input on the computer, output on the modem. Set to one by the modem after establishing a connection with the modem on the other side, reset to zero when the connection is broken. The computer hardware may issue an interrupt when such an event occurs.

    RI (Ring Indicator - ringing signal) - input on the computer, output on the modem. Set by the modem to one after detecting the ringing signal of a telephone call. The computer hardware may issue an interrupt when such an event occurs.

    SG (Signal Ground) - common signal wire of the port, is not common land, as a rule, isolated from the computer case or modem.

    A null modem cable uses two crossed pairs: TXD/RXD and RTS/CTS.

    The standard (since the original IBM PC) port hardware is called UART 16550 (currently included in the SuperIO chip on the motherboard along with a number of other devices). Since the time of the IBM PC, a hardware byte queue has appeared in it, which greatly reduces the number of interrupts issued by the device.

    Programmatic access to the COM port

    UNIX

    There is a registry section for each port. These sections have the following names:

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Serial\Parameters\Serial10000

    where the last value “Serial10000” is a unique number for each new COM port added to the system, for the second one – “Serial10001”, etc.

    To communicate with devices that support Bluetooth, some programs (for example, such programs include: a program that synchronizes the contact list with a mobile phone; a program that retrieves GPS coordinates from a GPS receiver) requires a COM port on the user's computer.

    Programs that use COM ports to support communication using Bluetooth wireless technology, directly developed by Microsoft, include:

    • HotSync used in handheld computers
    • ActiveSync, used in pocket PCs

    OS/2

    The existing COM.SYS driver supports only 4 COM ports, each of which must have its own interrupt line. To service COM ports with a common interrupt line, you must use the SIO driver.

    Null modem cable

    Main article: Null modem cable

    In some cases, it is possible to use a simplified version of the cable, in which only pins 2, 3 and 5 are used.

    See also

    • Serial Port Signals

    Notes

    Links

    • Translation of the COM port programming guide in POSIX operating systems
    • Programming the port in java - allows you to work from Windows, unlike official packages from Sun.
    • Programming a COM port in C++ for Windows. Ready-made library, source codes, sample programs.
    • Yashkardin V.L. Serial port. Programming a COM port in Windows and MS-DOS. SoftElectro (2009). Archived from the original on February 8, 2012.

    Serial port (serial port, serial port or COM port-, communications port) is a dual-directional serial interface.

    Why is the port called serial? Because all information on this port is transmitted in steps equal to one bit. It transfers data bit by bit, unlike a parallel port.

    Despite the fact that some other interfaces, such as Ethernet, FireWire and USB, use serial data exchange, the name “serial port” is assigned to a port that has a standard RS-232C.

    This port, in comparison with other "serial" technologies, has a distinctive feature: it does not have any timing requirement between 2 bytes. Timing requirements exist only between the bits of a single byte. The reciprocal of the time pause between the bits of one byte is called the “baud rate” (baud rate). In addition, in this technology there is no such thing as a “package”. Other "serial" data transfer technologies (X.25, USB or Ethernet) use "packets" and also have strict timing requirements between bits of one packet.

    Regarding communication protocols with industrial equipment, there are strict timing requirements between serial port bytes. Implementation of these protocols in multitasking operating systems with weak real-time support is very difficult. These systems include Windows. That is why MS-DOS or older software is often used to work with these protocols.

    The most common standard for a serial port is RS-232C. Previously, the serial port was used to connect a terminal, later it was used to connect a modem or mouse. Currently, it is used as a means of connecting to uninterruptible power supplies, as well as as a means of communication with embedded computing system development hardware, satellite receivers, cash registers and security system devices.

    Thanks to the COM port, it becomes possible to connect two PCs to each other using the so-called “null modem cable”. This method has been used since the days of MS-DOS to transfer files from one computer to another. On UNIX systems it was used for terminal access to another machine, and on Windows operating systems it was used as a kernel-level debugger.

    The serial port, quite popular at one time in IBM-compatible PCs, is now obsolete. However, it should be noted that it is still often used in industrial and highly specialized equipment, as well as on some modern computers. The serial port is actively being replaced by the USB and FireWire interface.

    However, there are special standards for serial port emulation over USB and over Bluetooth. By the way, it’s interesting, but it was Bluetooth technology that the developers designed as a wireless version of the serial port. Software port emulation is still widely used today. Thus, almost all mobile phones today emulate a COM port and modem within them in order to implement tethering (computer access to the Internet via GPRS/EGDE/3G). But directly for the physical connection to the computer, USB, Bluetooth or Wi-Fi technologies are used.

    In addition, software serial port emulation is possible for guest users of VMWare and Microsoft Hyper-V virtual machines. The main purpose of this procedure is to connect the Windows kernel level debugger to the guest client.

    Advantages of a COM port

    The main advantage of this technology is its ease of connection.

    Disadvantages of COM port

    The main disadvantages of this port are its low speed, large connector sizes, and high requirements for operating system response time. Also, this standard has a high number of interrupts (one interrupt every 8 bytes).

    Connectors

    The most common standard connectors are 9- and 25-pin (DB-9 and DB-25, respectively), which were standardized in 1969. These are D-shaped connectors. In addition to them, others were used, but from the same family: DB-31 and round eight-pin DIN-8.

    The maximum transmission speed (in the standard version) reaches 115,200 baud.

    Equipment

    The connector has the following contacts:

    • DTR(Data Terminal Ready) - output to PC, input - to modem. Responsible for the readiness of the computer to work with the modem. The reset causes an almost complete reboot of the modem. In the case of a mouse, this wire is used to provide power.
    • DSR(Data Set Ready) - input to PC, output - to modem. Responsible for modem readiness. If the line is zero, then on some operating systems it is impossible to open the port as a file.
    • RxD(Receive Data) - input to PC, output - to modem. Indicates the flow of data entering the PC.
    • TxD(Transmit Data) - output to PC, input - to modem. Indicates the flow of data coming from the PC.
    • CTS(Clear to Send) - input to PC, output - to modem. The computer must pause the data transfer process until this wire is set to one. Used in the hardware flow control protocol to prevent overflow on the modem.
    • RTS(Request to Send) - output to PC, input - to modem. The modem must pause the data transfer process until the wire is set to one. Used in hardware flow control protocol to prevent hardware/driver overflow.
    • DCD(Carrier Detect) - input to PC, output - to modem. After establishing a connection with the modem on the other side, it is raised to one, reset to zero if the connection is lost. PC hardware can generate an interrupt if such an event occurs.
    • R.I.(Ring Indicator) - input to PC, output - to modem. After determining the ringing signal of a telephone call, it is raised by the modem to one. The PC hardware can generate an interrupt if such an event occurs.
    • S.G.(Signal Ground) - the common signal wire of the port. Important:land is not common. Typically the wire is insulated from the PC or modem case.

    A null modem cable uses two crossed pairs: TXD/RXD and RTS/CTS.

    UART 16550- standard port equipment. Today it is included in the SuperIO chip on the motherboard. Since the days of the IBM PC, it has been equipped with a hardware byte queue. It significantly reduces the number of interruptions that occur.