Whole document tree
    

Whole document tree

Select a serial port

3.2. Select a serial port

Linux names its serial ports in the UNIX tradition. The first serial port has the file name /dev/ttyS0, the second serial port has the file name /dev/ttyS1, and so on.

This differs from the IBM PC tradition. The first serial port is named COM1:, the second serial port is named COM2:, and so on. Up to four serial ports can be present on a IBM PC/AT computer and its successors.

Most boot loaders have yet another naming scheme. The first serial port is numbered 0, the second serial port is numbered 1, and so on.

The result is that the first serial port is labeled COM1: on the chassis of the IBM PC; is known as /dev/ttyS0 to Linux; and is known as port 0 to the boot loader.

The examples in this HOWTO use this first serial port, as that is the serial port which most readers will wish to use.

Table 3-1. Many names for the same serial port

IBM PCLinux kernelMost boot loaders
COM1:/dev/ttyS00
COM2:/dev/ttyS11
COM3:/dev/ttyS22
COM4:/dev/ttyS33