ShoPorts

ShoPorts is a utility that will detect and display the true base port address 
(in hex) and interrupt request number (IRQ#) for each serial adapter installed
in your PC. With ShoPorts, you can instantly find out the true configurations 
of your serial ports without using a screwdriver.
When you run ShoPorts, the output will appear similar to that shown below:

COM Port Found At Hex Address: 02F8 Tied To IRQ3,  (UART=16550A)
COM Port Found At Hex Address: 03F8 Tied To IRQ4,  (UART=16550A)

The ROM BIOS stores the port addresses for the first four installed serial 
adapters in low memory at address 0000:0400 - 0407 however, these addresses
are not always correct. Programs that "detect" serial ports by reading BIOS
data may report incorrect addresses. They might also assume that your serial
ports are configured using standard IRQs (i.e. COM1 tied to IRQ4, COM2 to 
IRQ3, COM3 to IRQ4 and COM4 to IRQ3). Again, this may  be incorrect. 
The only real way to determine which IRQ a serial adapter uses is to actually
force it to generate an interrupt and then record which interrupt occurs (as 
is done by ShoPorts ). Also, the ROM BIOS only has room for the addresses of 
the first four serial ports whereas it is possible to have many more than 
that installed in your PC. 

Note: The "Standard" addresses for COM1-4 are respectively: 3F8, 2F8, 3E8 and 2E8. 

HOW ShoPorts WORKS:
ShoPorts works by scanning the most likely serial port addresses and searching
for the characteristic signature of an 8250,16450 or 16550 UART. If a UART is 
found, ShoPorts will trap IRQs 2,3,4,5,7,10,11,12 and 15 and then configure 
the UART to generate interrupts when a character is outputted (transmit holding
register empty interrupt). 
Note: ShoPorts will not trap IRQs that are currently active. See technical notes below.
After the IRQ trap is set up, a character is outputted (ASCII 0) and the corresponding 
interrupt, if it occurs, is recorded. Note: Because ShoPorts will output an ASCII 0 to
all serial ports in your PC, you should either turn off or disconnect all serial 
devices (printers, networks, modems, etc.) before running ShoPorts. Serial mice are
not affected by writing to them and therefore do not have to be disconnected.
 
ShoPorts starts scanning for serial ports at address 0100h and checks every eighth
port address (i.e. addresses 0108, 0110, 0118, 0128, etc...)  until it reaches 
address 0400.

Several reserved port addresses are skipped including:
0320 Hex  	-  Address reserved for fixed disk controller
03F0 Hex  	-  Address reserved for floppy diskette controller
03D0-03D8 Hex 	-  Addresses reserved for Color Graphics Adapter
03B0-03B8 Hex  	-  Addresses reserved for Monochrome Adapter

Technical Note: When you run ShoPorts, it first performs a check to see if any of
the IRQ lines that it tests are currently in use by installed TSRs or device drivers.
If ShoPorts detects IRQs that are in use, it will not attempt to generate interrupts 
for these IRQs. It does this to avoid the possibility of an IRQ conflict and 
consequently a system crash. ShoPorts will also generate a message similar to the
following if it detects active IRQs:

NOTE!  IRQ(s)  3,7,11  are currently in use on this PC.
ShoPorts will not be able to test COM ports that use these IRQs.

Suppose, for example, that IRQ 3 is being used by a serial mouse driver when you 
run ShoPorts. When ShoPorts tests each serial port to determine which IRQ it uses,
it will not test for IRQ 3. Thus it will not be able to determine the IRQ for any 
ports configured for IRQ 3. If an IRQ cannot be found for a serial adapter because
it uses a currently active IRQ, ShoPorts will display a question mark for the IRQ 
number. For this example, ShoPorts might display the following:

COM Port Found At Hex Address: 02E8 Tied To IRQ?,  (UART=16550A)
COM Port Found At Hex Address: 02F8 Tied To IRQ?,  (UART=16550A)
COM Port Found At Hex Address: 03E8 Tied To IRQ4,  (UART=16550A)
COM Port Found At Hex Address: 03F8 Tied To IRQ4,  (UART=16550A)

To free up all IRQs so that they are not in use when you run ShoPorts, simply remove
all TSRs and device drivers and re-boot. The easy way to do this is to take a blank 
floppy and make it bootable with the DOS SYS command. Place the blank disk in 
drive A: and type SYS A: at the DOS prompt. After DOS has been transferred to
the diskette, re-boot with the disk still in drive A. This will start up your system
with no device drivers or TSRs and you can re-run ShoPorts to determine the IRQs for
all serial ports. 

Warning: It is slightly possible for ShoPorts to lock up your PC because it reads port
addresses that may be used by other peripheral devices. We highly recommend that you 
de-activate all peripherals and disconnect from networks before running ShoPorts. 
You should also exit from all programs including DOS Shell programs and multitasking
environments (i.e. Windows), and run ShoPorts only from the native DOS prompt. 
