Buses
Buses
A computer consists of three basic components: CPU, Memory and Input/output components
If data is to be exchanged among these three components, we need to have an interconnection
structure, which allows transfer of information among all these. This interconnecting structure
must support
The transfer of an instruction or a unit of data from memory to CPU.
The transfer of a unit of data from CPU to memory
Reading of data from input/output device that is, transfers from input/output device to
CPU.
CPU sending data to input/output device.
The transfer of data from input/output devices to memory
The transfer of data from memory to input/output devices.
To support these transfers, the bus interconnection is used
Bus Interconnection
A bus is a set of connections between two or more components/devices that are designed to
transfer several/all bits of a word from a specific source to destination. It is a shared media of
information transfer. A bus consists of multiple communication wires that are also termed lines.
A line is capable of transferring one bit only. Thus, for transferring a word of 16 bits
simultaneously over a bus we need to have 16 bus lines. In addition, some other lines are needed
for controlling this transfer. A bus may be unidirectional (capable of transmitting data in one
direction) or bi-directional. The figure below shows the diagram of a shared bus.
There are different types of buses. These are address bus, data bus and control bus. Data bus
transfers data. Address bus transfers information about the destination of the data. Control bus
carry control signals.
A computer system contains a number of buses, which provide pathways among several devices.
A shared bus that connects the CPU, memory and input/output is called a system bus. A system
bus may consist of 50 to 100 separate lines. These lines can be broadly categorised into three
functional groups:
Data lines: these are collectively called Data Bus
Address lines: these are collectively called Address Bus
Control lines: these are collectively called Control Bus.
Data Bus
The data bus provides a path for moving data between the system modules. It normally consists
of 8, 16 or 32 bit separate lines. The number of lines in data bus is called the width of data bus.
Thus, a data bus width limits the maximum number of bits that can be transferred simultaneously
between two modules e.g., CPU and memory. The width of the data bus also helps in
determining the overall performance of a computer system. For example, if the width of a data
bus is 8 bits and an instruction is of 16 bits then for fetching each instruction two memory
accesses will be needed by the CPU.
Address Bus
The address bus is used to designate the source of data for the data bus. As the memory may be
divided into a linear array of bytes or words, therefore, for reading or writing any information on
to memory, CPU needs to specify the address of a particular location. The address bus supplies
this address. Thus, the width of the address bus specifies the maximum possible memory
supported by a system. For example, if a system has a 16-bit wide address bus then it can have a
main memory size equivalent to 216 = 64K.
Control Bus
The role of control lines (bus) is to control the access to data and address bus, as bus is a shared
medium. The control lines are used for transmission of commands and timing signals (which
validate data and address) between the system modules.
Examples of control lines and their functions
S/N Control line Function
1
2
3
4 BRQ Bus request
5 BGT Bus grant
Advantages
a) Cheaper and simple
b) Least number of lines
Disadvantages
a) Slow arbitration time
b) Priority depends upon physical location
c) Chance of failure is more
Independent Request method
In this, each master has a separate pair of bus request and bus grant lines and each pair has a
priority assigned to it. The built-in priority decoder within the controller selects the highest
priority request and asserts the corresponding bus grant signal.
Advantages
a) Very fast arbitration
b) Very less chance of failure
Disadvantages
a. Cost is high