Usually a PC at least has 2 serial and 1 parallel interfaces.
These interfaces are special devices and are mapped as follows:

these are the RS232 serial devices 0-n where n depends on your hardware.

these are the RS232 serial devices 0-n where n depends on your hardware.

these are the parallel devices 0-n where n depends on your hardware.

these are the joystick devices 0-n where .

The difference between the /dev/ttyS* and /dev/cua* devices is how
a call to open() is handled. The /dev/cua* devices are supposed to be used
as callout devices and thus get other default settings by a call to open()
than the /dev/ttyS* devices which will be initalized for incoming and
outgoing calls. By default the devices are controlling devices for the
process that opened them.
Normally ioctl() requests should handle all these special devices, but
POSIX preferred to define new functions to handle asynchronous
terminals heavily depending on the struct termios. Both methods require
including <termios.h>.