Plug-n-Play is an inherent part of the PCI specifications. Any add-on cards, which do not adhere to itsprotocols, are not PCI-compliant.DMA or Bus-Mastering on the PCI BusDirect Memory Access (DMA) is a technique by which two system resources on a bus can transfer databetween themselves without any CPU involvement.In the PCI bus specification, these two devices are called “initiator” and “target,” i.e. the initiator devicetakes control of the data, address and control lines of the bus and writes the data to the target device.The PCI Bus implements DMA by allowing any device to become a bus-master and write data to a targetdevice. The correct PCI language for DMA is PCI bus-mastering.A PCI Bus-master is a hardware device that takes control of the data, address and control lines of the busand uses them to transfer data to a target device. A PCI Slave is a hardware device in a bus-based systemthat accepts data transfers coming from a Master. A slave is almost always a “target” device.A good analogy of bus-mastering exists in most businesses in the shape of a telephone system. Officesgenerally have a receptionist who answers all incoming calls and directs them to different employees,depending on whom the caller wants to talk to.This is a good example of Slave mode operation. The receptionist is the “Central Processing Unit (CPU)”of the system, all the employees are “target devices” and the caller is the “initiator.”Slave mode does not require very sophisticated hardware, but requires considerable “processing power”(the receptionist’s time) and slows down the routing of the “transactions” (calls).Some companies have implemented “Direct Inbound Dialing (DID)”, a system in which each employee hasa unique telephone number. A caller can reach an employee, without having to go through the receptionist,by dialing their number.DID is analogous to bus-mastering: the “initiator” (caller) takes control of the bus (the telephone line) andconnects with the “target” (employee) without having to disturb the CPU (receptionist).It is fairly clear that bus-mastering is more efficient not only because the CPU (receptionist) can do othertasks while all the bus transactions (calls) take place, but also because it is faster.The obvious question, which arises in the case of a Multi-Master bus, is; how is the bus arbitrated? In otherwords, how does the system know who is the current bus-master and how does a device become a busmaster?The arbiter is always included with the motherboard or CPU card. Unfortunately, there is no clearspecification for bus arbitration in PCI, so the exact schemes are dependent upon the motherboard or CPUbeing used. Nonetheless, bus arbitration is almost always handled in a safe and predictable manner,making PCI a very stable and well-defined system.The PCI bus allows any of the system resources to become a bus-master. For example, it is possible for anadd-on card, such as a <strong>CompuScope</strong>/PCI, to be a master at one point in time and another add-on card, suchas a DSP card, to be the master at a later time. Naturally, the CPU is also allowed to be the bus-master.Page 12<strong>CompuScope</strong> <strong>SDK</strong> <strong>Manua</strong>l
Memory Mode Operation of the PCI Bus <strong>CompuScope</strong>CardsIn memory mode, PCI Bus <strong>CompuScope</strong> cards digitize the analog signal and store the resulting digital datain on-board memory. This memory can be accessed by the CPU (or any other PCI device) only after theacquisition has stopped.A/DRAMP C I B U SOn-board <strong>CompuScope</strong> memory is therefore single-port memory. If the A/D is writing into it, neither theCPU nor any other PCI device can access it.The on-board memory is designed to accept data from the A/D converters at the highest sampling speeds ofthe card. For example, the on-board memory on <strong>CompuScope</strong> 8500 has a cycle time of 2 nanoseconds per8 bit sample, or 500 MB/s.The maximum record length of the signal being captured by a PCI bus <strong>CompuScope</strong> card is determined bythe amount of on-board memory. The captured data can than be transferred to the PC memory at the speedallowed by the PCI bus. In bus-mastering mode, a <strong>CompuScope</strong> card is capable of sustained PCI datatransfer rates of up to 100 Megabytes/sec (depending on the motherboard). In Slave mode, the transfer rateis up to 10 Megabytes/sec.Data throughput across the PCI BusThe PCI bus is capable of transferring data from an add-on card to the CPU memory using either Slave orMaster moves. PCI Bus <strong>CompuScope</strong> cards allow both types of data transfers to take place. Anapplication program can select which mode to use by using a driver function. This driver function writesthe appropriate control words into the PCI controller on-board the <strong>CompuScope</strong>/PCI cards.Number of PCI Slots in one ChassisThe PCI bus can usually have no more than 3 or 4 add-on slots, due to the unterminated nature of the bus.Each add-on device has strict restrictions on how much it can load the bus.It is possible to have more than 3 or 4 PCI slots on the same backplane if the slots are part of differentbuses (called peer buses) and each bus has no more than 3 or 4 peer slots. For instance, a Gage InstrumentMainframe is available with 16 contiguous PCI slots.<strong>CompuScope</strong> <strong>SDK</strong> <strong>Manua</strong>l Page 13