UNIX Serial Devices

UNIX systems use special files known as devices to give users access to system hardware. These devices are commonly stored in the /dev subdirectory, with one or more files providing access to a specific piece of hardware.

The exact number and names of serial ports on any particular system depend on both the hardware configuration and the version of UNIX. Luckily, you can refer to some common standard implementations as a guide.

Typically, most hardware platforms have four serial ports, referred to as COM1, COM2, COM3, and COM4. Under Linux, the corresponding UNIX device files for these ports are commonly called /dev/ttyS0, /dev/ttyS1, /dev/ttyS2, and /dev/ttyS3. The exact names of these devices might vary slightly, depending ...

Get Practical UNIX now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.