In the days of plug-and-play systems, many people assume that trouble with memory addresses and hardware interrupts is a thing of the past. However, nothing could be further from the truth. Even with plug-and-play devices, conflicts with memory addresses and interrupts are common. In this article, I’ll explain how Windows 98 uses the system’s interrupts and memory addresses.
What are hardware interrupts?
Before you can understand how interrupts work within Windows 98, you need to know a little bit about the nature of the beast. Therefore, I’ll review the concept of interrupts for the benefit of those who haven’t had much hardware experience.
A hardware interrupt, known as an Interrupt Request, or IRQ, is a signal sent over a specific hardware line to a PC’s CPU. The IRQ tells the processor that its assigned hardware device needs its attention. Think of IRQs as 16 students in a class. When a student raises a hand, the teacher responds. If all the students raise their hands at once, the teacher answers each request in order of priority, starting from the lowest number.
Until recently, devices in your system, such as expansion cards, could not share interrupts. However, IRQ processing has changed so that two PCI cards can share an IRQ line. So can USB devices. In addition, it is sometimes possible to share interrupts between an expansion card and a built-in device.
Figure A lists the 16 numbers that correspond to interrupt lines built into PCs, along with their common assignments.
|These numbers correspond to interrupt lines built into PCs.|
When you look at the list in Figure A, keep in mind that it doesn’t hold absolutely true for all systems. But this list should be accurate enough to illustrate the concept of how interrupts work. For example, when a key on the keyboard is pressed, it sends a signal on IRQ 1. The CPU will then process the keystroke.
As you can see from the list, there are 16 interrupts, and almost all of them are used by today’s systems. This means that if you add a device—such as a network card or a sound card—you’ll have to either share an interrupt or disable a device.
In the days of DOS, interrupt sharing was the common approach to solving this problem. At that time, expansion cards usually had a jumper that you could use to set the interrupt number. No two expansion cards could share an interrupt number, but you could share one with the system devices. The most commonly used interrupts for add-on cards were 3, 5, 7, and 10. Needless to say, having so few usable interrupts limited how many expansion cards you could use—but then again, at that time most computers only had three or four expansion slots.
In Windows 98, things work a bit differently. If you’re using a legacy device with a set interrupt, you’ll have to use the Device Manager to disable whatever system device is currently using the interrupt. If you find yourself having to do this, you should look for an interrupt number that’s available on the card and that won’t make you disable an essential device. For example, you might be able to disable one of your COM ports or your printer port (if you don’t have a printer locally attached to the machine).
On the other hand, if you’re using plug-and-play Windows 98 takes care of the hard part for you. You might have noticed in Figure A that several IRQs were reserved for something called the IRQ Holder For PCI Steering. PCI Steering refers to the way that Windows 98 works with PCI cards. It can juggle several PCI cards through a single interrupt, thanks to the PCI steering mechanism. This means that depending on the configuration of your physical hardware, you could have several expansion cards that all appear to be using interrupt 10 or another interrupt.
Memory addresses and I/O ports
When you talk about memory addresses within Windows 98, there are really two types that need to be discussed. First, there’s the memory address. This is the physical address that corresponds to a particular location within your system’s memory. Each device typically reserves an entire range of memory addresses. The size of a memory address range varies from device to device. This area is set aside by Windows 98 and reserved for use exclusively by the device. This is because devices within your system need memory to perform calculations and to execute other device-specific functions.
The other component is the I/O port. The I/O port points to a much smaller range of memory locations. Although the I/O port may consist of several bytes, it tends to be much smaller than memory addresses, which can consume multiple KBs. This location is typically used to communicate with the device. For example, suppose you wanted a network card to transmit a packet. Windows would send the instructions for doing so to the I/O port rather than to the card’s memory address.
For example, suppose you had a network card that used I/O port E400 through E47F and occupied memory range E7000000 through E700007F. In this case, Windows would reserve the E7000000 to E700007F memory range for the device to perform any necessary device-specific functions, such as calls to a register within the device or a device memory reset.
Any time that Windows needed to communicate with the device, it would send instructions to and receive results from the E400 through E47F memory range that’s been designated for I/O communications. The memory addresses and I/O ports function similarly to hardware interrupts as far as configuration is concerned. Both I/O ports and memory addresses must be specific for each device.
However, unlike hardware interrupts, which can sometimes be shared, I/O ports and memory addresses must always be unique. As you might have guessed, some devices within your system use I/O ports and memory addresses. This means that if you’re installing a legacy expansion card, you should take a good look at which memory addresses and I/O ports are already in use before attempting to configure the device.
Plug-and-play devices don’t have this problem. When you install a plug-and- play device, Windows will automatically find a free memory address and I/O port for it. Of course, this is assuming that the device requires an I/O port and a memory address. Although many devices require both a memory address range and an I/O port, some devices simply use one or the other.
Mixing legacy devices with plug-and-play devices
As I’ve mentioned, there are big differences in the way that legacy devices and plug-and-play devices function. Because of this fact, you need to know a few things in order to use legacy devices and plug-and-play devices within the same system.
First, you should always install the legacy devices first. This is because they require manual configuration and the resources they can use are limited. If you install your plug-and-play devices first, there’s a good chance that the plug-and-play devices may consume the only available resources. If, on the other hand, you install the legacy device first, Windows should have no trouble making the plug-and-play devices function on whatever resources are left over.
The other problem with mixing old and new is caused by the way that plug-and-play works. According to the interrupt chart, systems are preconfigured to expect certain devices to use specific IRQs. For example, COM2 is set to IRQ 3 and I/O range 2F8 through 2FF. Standard settings hold true for all the COM ports. Older communications programs expect a modem to use one of the four COM ports at their designated locations. However, if you install a plug-and-play modem, Windows 98 might designate it as COM3 but set it to use interrupt 11 (COM3 is usually interrupt 4), and may set it to some funky I/O port that no one has ever heard of before. If this happens, communications programs that expect COM3 to use specific resources won’t be able to communicate with the modem. The only ways around this problem are by either using external modems attached to a physical COM port or manually rearranging system resources. This rearrangement is done through Device Manager.
Device Manager is the Windows 98 component that allows you to view your system’s hardware configuration. To access Device Manager, open Control Panel and double-click the System icon. When you do, you’ll see the System Properties sheet. Now, select the Device Manager tab. As you can see in Figure B, Device Manager is organized into a tree-like structure, starting with Computer and branching out into specific hardware devices. To view an overall summary of your system, double-click Computer to display a summary of interrupts, I/O ports, memory addresses, or DMAs. You can select a different view by clicking the appropriate radio button, as shown in Figure C.
|Device Manger provides a summary of your system’s hardware configuration.|
|You can view a comprehensive list of system resources through Device Manager.|
Now, suppose you wanted to view or alter the resources consumed by a specific device. To do so, expand the device category by clicking the plus sign next to it and double-clicking on the individual device. For example, if you wanted to look at a network card, you’d expand the Network Adapters category and double-click on the specific card (in this case, a Realtek RTL8139 PCI Fast Ethernet). When you do, you’ll see a properties sheet that’s specific to the individual device. The General tab displays a summary of the device and allows you the option of disabling the device, as shown in Figure D.
|The General tab displays a summary of the device and allows you to disable the device if necessary.|
The Resources tab displays a list of the hardware resources that the device is using. If you need to change a particular resource, you can deselect the Use Automatic Settings check box. Once you’ve done so, you can select the resource that needs to be changed and click the Change Settings button. To make this process easier, the Conflicting Device List displays a summary of which resources, if any, conflict with another device in the system. Figure E shows an example of the Resources tab.
|The Resources tab lets you view and change the hardware resources that the device is using.|
Common conflicts occur between sound cards and network cards (typically IRQ 5), and devices that use serial (COM) ports, such as external modems and Palm Pilot syncing cradles. However, any user may encounter highly specific conflicts. The point to remember is that when two devices are set to use the same IRQ, I/O port, or memory address, they will conflict. It’s just that simple.
In this Daily Drill Down, I’ve explained that although newer systems require less manual configuration than systems did in the past, interrupts and memory addresses are still very much a part of the system. I’ve explained how even many plug-and-play devices still depend on interrupts and memory addresses and how to begin troubleshooting device resource conflicts.
Talainia Posey learned to handle PCs the old-fashioned way: by reading manuals and doing on-the-job troubleshooting. Her experience also includes installing networks for several small companies. When she’s not working on computers, Talainia loves to shop for toys and watch cartoons, or spend time with her cat, Beavis.
The authors and editors have taken care in preparation of the content contained herein, but make no expressed or implied warranty of any kind and assume no responsibility for errors or omissions. No liability is assumed for any damages. Always have a verified backup before making any changes.