COA Notes
COA Notes
Introduction
The Central Processing Unit (CPU) is the electronic circuitry within a computer that carries out
responsible for executing instructions and performing calculations. It serves as the "brain" of the
computer and is responsible for interpreting and carrying out instructions from computer
programs. The CPU typically consists of several key components, including the Arithmetic
Logic Unit (ALU), which performs arithmetic and logical operations, and the Control Unit,
which manages the execution of instructions and the flow of data within the CPU and between
other components of the computer system. The CPU also includes registers, which are small,
high-speed storage locations used to store data temporarily during processing. The CPU fetches
instructions from memory, decodes them to determine the operation to be performed, fetches the
required data from memory or registers, executes the operation, and then stores the result back in
memory or a register. This process is carried out repeatedly to execute the instructions of a
computer program.
Registers
It is a memory location within the actual processor that works at very fast speeds. It stores
instructions which are waiting to be decoded or executed. It is small, high-speed storage location
within the Central Processing Unit (CPU) of a computer system. Registers are used to store
temporary data, addresses, and control information that the CPU needs to perform calculations
and execute instructions. Registers are often directly accessible by the CPU and are much faster
than accessing data from system memory. Registers are used to hold data that is being processed
by the CPU during computation, as well as to store intermediate results and memory addresses.
They are an important component of the CPU's operation, as they enable the CPU to quickly
access and manipulate data while performing calculations and executing instructions.
Processor
component of a computer system that carries out instructions and performs arithmetic, logic, and
Complex Instruction Set Computers (CISC) processors are a type of processor architecture that
emphasizes the completion of complex instructions in as few cycles as possible. CISC processors
are designed to handle a large number of complex, multi-step instructions that can be executed
efficiently on the processor itself. These processors can do complex operations, which can be
carried out in just one instruction. They have many different addressing modes and a wide range
of instructions that can be used. For example, a CISC processor might have a 'complicated'
instruction designed into the hardware called 'POWER'. This can take one number from a
register, find the power of that number, held in a different register, and then store the result in yet
a third register. So, 2 to the power 4 would be calculated as 16 and this would be stored in a third
register. This would all be done using one complex instruction, which might take about 3 or 4
Reduced Instruction Set Computers (RISC) processors are a type of processor architecture that
emphasizes simplicity and efficiency in instruction execution. RISC processors are designed to
use a smaller and more streamlined set of instructions, each of which performs a single, basic
operation. This approach allows RISC processors to execute instructions quickly and efficiently,
making them ideal for high-performance computing tasks. There are also CPUs that are known
as RISC (pronounced „risk‟), or Reduced Instruction Set Computers. RISC processors such as
ultra-SPARC and ALPHA use a much smaller, simpler set of instructions than CISC processors
and so to carry out any particular programming task may take many “fetch decode execute”
cycles. RISC processors, however, are much more efficient at processing huge blocks of data
than CISC.
There are four key factors about CPU architecture that affect its performance:
1. Cores
A CPU can contain one or more processing units. Each unit is called a core. A core contains an
ALU, control unit and registers. It is common for computers to have two (dual), four (quad) or
even more cores. CPUs with multiple cores have more power to run multiple programs at the
same time.
2. Clock speed
The clock speed - also known as clock rate - indicates how fast the CPU can run. This is
measured in megahertz (MHz) or gigahertz (GHz) and corresponds with how many instruction
3. Cache size
Cache is a small amount of memory which is a part of the CPU - closer to the CPU than RAM. It
is used to temporarily hold instructions and data that the CPU is likely to reuse.
4. Processor type
CPU ARCHITECTURE
Control Unit
This unit controls the operations of all parts of the computer but does not carry out any actual
It is responsible for controlling the transfer of data and instructions among other units of
a computer.
It obtains the instructions from the memory, interprets them, and directs the operation of
the computer.
It communicates with Input/output devices for transfer of data or results from storage.
Arithmetic Section
Logic Section
Arithmetic Section
Function of the arithmetic section is to perform arithmetic operations like addition, subtraction,
multiplication, and division. All complex operations are done by making repetitive use of the
above operations.
Logic Section
Function of the logic section is to perform logic operations such as comparing, selecting,
Registers
processing unit. The registers are an integral part of the CPU. They are a type of memory that
can be accessed very quickly compared to other types of memory. The pieces of information they
hold are needed by the CPU to run each program instruction during a 'fetch-decode-execute
cycle' or can be used to hold values that are generated as part of the ALU working on data. There
A BUS is a data connection between two or more devices connected to the computer. For
example, a bus enables a computer processor to communicate with the memory or a video card
to with the memory. These buses carry different types of signals. The same types of buses carry
only one type of signal. These buses help to increase the efficiency and accuracy of working. A
These devices work with the help of buses. PC motherboards have buses for expansion and
DATA BUS: The datal bus controls the traffic of data. It helps to send data, according to
ADDRESS BUS: Data bus helps to connect the Microprocessor (CPU) and Memory
(RAM).
CONTROL BUS: The address bus carries the address of the location of memory.
This is the basic operation (instruction) cycle of a computer (also known as the fetch decode
execute cycle). During the fetch execute cycle; the computer retrieves a program instruction from
its memory. It then establishes and carries out the actions that are required for that instruction.
The cycle of fetching, decoding, and executing an instruction is continually repeated by the CPU
1. Fetch
The first step the CPU carries out is to fetch some data and instructions (program) from main
memory then store them in its own internal temporary memory areas. These memory areas are
called 'registers'. For this to happen, the CPU makes use of a vital hardware path called the
'address bus'. The CPU places the address of the next item to be fetched on to the address bus.
Data from this address then move from main memory into the CPU by travelling along another
2. Decode
The next step is for the CPU to make sense of the instruction it has just fetched. This process is
called 'decode'. The CPU is designed to understand a specific set of commands. These are called
the 'instruction set' of the CPU. Each make of CPU has a different instruction set. The CPU
decodes the instruction and prepares various areas within the chip in readiness of the next step.
3. Execute
This is the part of the cycle when data processing actually takes place. The instruction is carried
out upon the data (executed). The result of this processing is stored in yet another register. Once
the execute stage is complete, the CPU sets itself up to begin another cycle once more.
Instruction Set
Instruction sets are instruction codes to perform some task. It is classified into five categories.
The instruction set, also called ISA (instruction set architecture) is part of a computer that
pertains to programming, which is basically machine language. The instruction set provides
commands to the processor, to tell it what it needs to do. The instruction set consists of
addressing modes, instructions, native data types, registers, memory architecture, interrupt, and
computers today. Different computer processors can use almost the same instruction set while
Both the Intel Pentium and AMD Athlon processors use nearly the same x86 instruction set. An
instruction set can be built into the hardware of the processor, or it can be emulated in software,
using an interpreter. The hardware design is more efficient and faster for running programs than
Practical Exercise
Clock Speed
Manufacturer
Generation
2. Case Study: Verification of CPU Specifications for a Computer Build
Scenario: A company is planning to build a high-performance workstation for graphic design and
video editing tasks. The IT department is tasked with selecting the appropriate CPU based on
specific requirements and verifying that the chosen CPU meets the desired specifications for the
computer build.
Highlight the specifications needed to achieve this scenario and document the steps taken.
Understand Computer Memory Organization
This learning outcome covers explaining memory organisation, various storage technologies,
cache and virtual memory, prescribing memory specifications for a user and verifying memory
permanently. Memory devices utilize integrated circuits and are used by operating
systems, software, and hardware. ○ is the storage space in the computer, where data is to
terms of response times, with processor registers at the top of the pyramid structure and
uses hardware and software to allow a computer to compensate for physical memory
shortages by temporarily transferring data from random access memory (RAM) to disk
storage.
Cached memory: a small-sized type of volatile computer memory that provides high-
speed data access to a processor and stores frequently used computer programs,
Volatile Memory: This loses its data, when power is switched off.
Non-Volatile Memory: This is a permanent storage and does not lose any data when
Volatile Memory: This loses its data, when power is switched off.
Non-Volatile Memory: This is a permanent storage and does not lose any data when
The total memory capacity of a computer can be visualized by hierarchy of components. The
memory hierarchy system consists of all storage devices contained in a computer system from
the slow Auxiliary Memory to fast Main Memory and to smaller Cache memory.
Cache Memory
Cache Memory
Cache memory is a very high speed semiconductor memory which can speed up the CPU. It acts
as a buffer between the CPU and the main memory. It is used to hold those parts of data and
program which are most frequently used by the CPU. The parts of data and programs are
transferred from the disk to cache memory by the operating system, from where the CPU can
access them.
Cache deals with the tags so as to identify which block of main memory is present in each cache
slot
Advantages
The advantages of cache memory are as follows;
It stores the program that can be executed within a short period of time.
Disadvantages
It is very expensive.
Primary memory holds only those data and instructions on which the computer is currently
working. It has a limited capacity and data is lost when power is switched off. (Volatile) It is
generally made up of semiconductor devices. These memories are not as fast as registers. The
data and instruction required to be processed resides in the main memory. It is divided into two
Random access memory (RAM) is the best known form of computer memory. RAM is
considered "random access" because you can access any memory cell directly if you know the
Types of RAM:-
Static RAM (SRAM) is a type of random-access memory that uses latching circuits (flip-flops)
to store data bits. It is faster and more expensive than Dynamic RAM (DRAM) but does not
require refreshing like DRAM does. SRAM is commonly used in cache memory and other
applications where high speed and low power consumption are important.
Dynamic RAM (DRAM) is a type of random-access memory that stores each bit of data in a
separate capacitor within an integrated circuit. DRAM needs to be refreshed to maintain the
stored data as the capacitors leak charge over time. DRAM is slower and less expensive than
SRAM, but it is more commonly used in computers and other devices for main memory due to
It is a type of memory that retains data even when power is turned off. This is achieved by using
a combination of volatile and non-volatile memory technologies. NVRAM typically stores data
using either battery-backed SRAM or flash memory. NVRAM is often used in applications
where it is essential to retain certain data even in the event of a power failure or system
shutdown. Examples of such applications include storing BIOS settings in a computer, storing
configuration data in networking devices, and storing critical data in industrial control systems.
It is a category of Random Access Memory (RAM) that retains stored data even if the
NVRAM uses a tiny 24-pin dual inline package (DIP) integrated circuit chip, which helps
it to gain the power required to function from the CMOS battery on the motherboard.
NVRAM monitors several system parameters, such as Ethernet the MAC address, serial
NVRAM is a non-volatile memory type that provides the random access facility.
Primary Memory
ROM (Read Only Memory)
It is the memory from which we can only read but cannot write on it. This type of memory is
non-volatile. The information is stored permanently in such memories during manufacture. ROM
stores such instructions that are required to start a computer. This operation is referred to as
bootstrap. ROM chips are not only used in the computer but also in other electronic items like
ROM - Read Only Memory : is a type of non-volatile memory that stores data permanently and
cannot be electronically modified after manufacture. The data in ROM is typically programmed
by the manufacturer and is maintained even when the power is turned off
type of read-only memory (ROM) that allows users or manufacturers to program custom data
onto the memory chip after manufacture. PROM can be programmed by blowing fuses on the
chip to set the desired data pattern. Once the data has been programmed onto a PROM chip, it
cannot be changed or erased. This makes PROM similar to Mask ROM, as the data programmed
onto PROM is permanent. However, the advantage of PROM is that it allows for customization
PROM was widely used in early computer systems and embedded systems to store firmware,
boot loaders, configuration data, and other essential data that needed to be permanently stored
and not easily modified. With the development of more advanced types of programmable ROM,
such as EEPROM and flash memory, PROM has become less common in modern electronic
devices.
EPROM - Erasable Programmable Read Only Memory: Erasable Programmable Read-Only
Memory (EPROM) is a type of read-only memory (ROM) that can be rewritten and
electrical charge to specific memory cells, which changes the stored data. The unique feature of
EPROM is that it can be erased by exposing the memory chip to ultraviolet (UV) light, typically
using a special UV eraser device. This erases the previously stored data, allowing the chip to be
reprogrammed with new data. EPROM can be erased and reprogrammed multiple times, making
it a versatile memory option for applications that require frequent updates or changes to the
stored data. EPROM was commonly used in early computer systems, embedded systems, and
electronic devices where the firmware or software needed to be updated periodically. It played a
memory solution. However, EPROM has been largely replaced by Electrically Erasable
Programmable Read-Only Memory (EEPROM) and flash memory in modern electronic devices
due to their faster erase and reprogram times and lower power consumption.
electrically erased and reprogrammed multiple times. EEPROM does not require ultraviolet light
for erasing, making it more convenient to use than EPROM. It can be programmed and erased in-
circuit, which means that the chip does not need to be removed from the circuit board for these
operations. EEPROM works by storing data in memory cells that can be individually erased and
reprogrammed using electrical signals. This allows for easy and flexible updates to the stored
data without the need for specialized equipment or UV light. EEPROM is commonly used in
electronic devices where small amounts of data need to be stored and updated, such as in
firmware, system configurations, and calibration data. It is particularly useful in applications that
require regular updates or changes to the stored information, as it allows for easy reprogramming
without the need for physical removal of the memory chip. EEPROM has largely replaced
EPROM in modern electronic devices due to its faster erase and reprogram times, lower power
consumption, and ease of use. It is widely used in consumer electronics, automotive systems,
industrial automation, and other applications that require reliable and flexible non-volatile
memory solutions.
Memory) is a type of non-volatile memory that combines the features of EEPROM and flash
memory. Flash EEPROM is electrically erasable like EEPROM, but it allows for bulk erasing of
entire blocks of memory at once, making it more efficient for updating and reprogramming large
amounts of data. Flash EEPROM memory is commonly used in electronic devices for storing
system firmware, operating system code, application software, and other types of data that need
to be retained even when power is turned off. It is widely used in USB drives, solid-state drives
(SSDs), memory cards, and embedded systems. Flash EEPROM memory allows for fast read and
write operations, and it can be updated more easily and quickly compared to traditional
EEPROM memory. It is also more cost-effective than EEPROM due to its larger storage
Secondary Memory
This type of memory is also known as external memory or non-volatile. It is slower than the
main memory. These are used for storing data/information permanently. The CPU does not
directly access these memories; instead they are accessed via input-output routines. The contents
of secondary memories are first transferred to the main memory, and then the CPU can access it.
It is a non-volatile memory.
Data is permanently stored even if power is switched off.
Depending on whether secondary memory device is part of CPU or not, there are two types of
It is a storage device that uses integrated circuit assemblies as memory to store data. SSD are
also known as solid-state disks although SSDs do not have physical disks. Form-factors and
protocols such as SATA and SAS of traditional hard disk drive (HDD) may be used by SSD,
greatly simplifying usage of SSDs in computers. New form factors such as the M.2 form factor,
and new I/O protocols such as NVM Express have been developed to address specific
Characteristics
There are no moving mechanical components in SSD. This makes them different from
conventional electromechanical drives such as hard disk drives (HDDs) or floppy disks,
Run silently, have quicker access time and lower latency compared to electromechanical
devices.
This is an electronic data storage medium that can be written to and read from using a low
powered laser beam. Optical storage devices save data as patterns of dots that can be read using
light. A laser beam is the usual light source. The data on the storage medium is read by bouncing
the laser beam off the surface of the medium. Dots can be created using the laser beam (for
media that is writable such as CD-Rs). The beam is used in a high-power mode to actually mark
the surface of the medium, making a dot. This process is known as „burning‟ data onto a disc.
Magnetic Storage Device
A magnetic disk is a storage device that uses a magnetization process to write, rewrite and access
data. It is covered with a magnetic coating and stores data in the form of tracks, spots and
sectors. Hard disks and zip disks are common examples of magnetic disks.
Virtual Memory
Virtual Memory is a technique to increase the main memory capacity. It uses data swap
technology and hard disk area is used as virtual memory. It is a technique that is implemented
using both hardware and software. It maps memory addresses used by a program, called virtual
Large programs can be written, as virtual space available is huge compared to physical
memory.
Physical Size RAM: modules vary in physical size based on the type of computer they're used
for and the number of pins on the module. Dual Inline Memory Modules (DIMMs) with 168 pins
are 5.25 inches long. DIMMs with fewer pins are typically smaller, with more pins meaning a
physically larger module. DIMMs are commonly used in desktop computers, whereas laptops
typically use Small Outline Dual Inline Memory Modules (SODIMMs). SODIMMs use the same
computer can only hold so much RAM and while going over the specified limit won't harm your
computer, your PC will only use as much of it as it was designed to use. Amount is commonly
measured in gigabytes (GB), though older or low-end computers may measure maximum RAM
in megabytes (MB). Some computers have two slots to install memory, others have four and
Type of memory: The memory type is important because this is where the majority of RAM's
compatibility issues lie. Multiple variations of Double Data Rate (DDR) memory technology are
used in various computers. 1 Objective Cache memory increases CPU access speed. Virtual
memory increases the main memory capacity. 2 Memory Unit Cache memory is a memory unit
and is very fast to access. Virtual memory is a technique and involves hard disk and is slower to
access. 3 Management CPU and related hardware manages cache memory. Operating System
manages virtual memory. 4 Size Cache memory is small in size. Size of virtual memory is much
larger than cache memory. 5 Operation Cache memory keeps recently used data. Virtual memory
keeps the programs which are not getting accommodated in main memory. DDR2 is faster than
DDR memory, while DDR3 memory is faster than both. If your computer requires DDR3
Memory Speed: Memory speed is frequently denoted by "PC-" followed by a number that
denotes the peak transfer rate and bandwidth of that type of memory. For example, PC-2400's
peak transfer rate is around 2,400 megabytes per second (MB/s). The peak transfer rate basically
denotes the best performance possible for that memory. "PC2" and "PC3" simply refer to DDR2
and DDR3 memory, respectively. The specifications may list the memory under a name known
as the "friendly name," which looks something like "DDR3-1066." In this case, 1066 represents
the data transfer rate in millions per second. All together, the memory specification may read
Introduction
Definition of terms
between the computer system and external devices. Input devices allow users to input data or
commands into the computer, while output devices display or provide results to the user. The
input-output operation involves transferring data between the computer's memory and
input/output devices.
Peripheral: A peripheral device is an internal or external device that connects to a computer but
does not contribute to the computer's primary function, such as computing. It helps end users
Bus: A bus is a subsystem that transfers data between computer components inside a computer
or between computers.
A peripheral is a device that can be attached to the computer processor. Peripheral devices can be
external, such as a mouse, keyboard, printer, monitor or scanner. Peripheral devices can also be
Input devices
Output devices
Storage devices
Input Devices
A device that feeds data into a computer processor is called an input device. Input can take a
variety of forms, from commands you enter from the keyboard to data from another computer or
device.
A device that shows data from a computer processor is an output device. Output can also appear
in a variety of forms - text, video, graphics, and so on. Examples of common output devices;
Backing Storage Devices
Backing storage is a device which holds and retains data. These devices allow the user to save
data in a more permanent way than RAM so that data is not lost and may be used at a later time.
Peripheral specifications
These specifications should match the user’s needs. If the user needs to save/store data, they will
need storage, a device categorized as storage will be ideal. The user specification may entail a
I/O Processing
I/O processor is a processor separate from the CPU designed to handle only input/output
processes for a device or the computer. The I/O processor is capable of performing actions
without interruption or intervention from the CPU. The CPU only needs to initiate the I/O
processor by telling it what activity to perform. Once the necessary actions are performed, the
Doing these actions allow the I/O processor to act as a bus to the CPU, carrying out activities by
directly interacting with memory and other devices in the computer. A more advanced I/O
processor may also have memory built into it, allowing it to perform actions and activities more
quickly.
BIU takes care of all data and addresses transfers on the buses for the EU (Execution Unit) like
sending addresses, fetching instructions from the memory, reading data from the ports and the
memory as well as writing data to the ports and the memory. EU has no direct connection with
System Buses so this is possible with the BIU. EU and BIU are connected with the Internal Bus.
BUS: is a communication system that transfers data between components inside a computer, or
between computers
Interface: is a hardware circuitry between the microcomputer and the I/O devices. It provides all
the input/output transfer. They connect/interface the computer and the peripherals.
Types of buses
Each bus defines its set of connectors to physically plug devices, cards or cables together. There
are two types of buses: internal and external. Internal buses are connections to various internal
components. External buses are connections to various external components. There are different
kinds of slots that internal and external devices can connect to.
Internal
Types of Slots
There are many different kinds of internal buses, but only a handful of popular ones. Different
computers come with different kinds and number of slots. It is important to know what kind and
number of slots you have on your computer before you go out and by a card that matches up to a
PCI (Peripheral Component Interconnect) is common in modern PCs. This kind of bus is being
succeeded by PCI Express. Typical PCI cards used in PCs include: network cards, sound cards,
modems, extra ports such as USB or serial, TV tuner cards and disk controllers. Video cards
have outgrown the capabilities of PCI because of their higher bandwidth requirements.
PCI Express
PCI Express was introduced by Intel in 2004. It was designed to replace the general-purpose PCI
expansion bus and the AGP graphics card interface. PCI express is not a bus but instead a point-
to-point connection of serial links called lanes. PCI Express cards have faster bandwidth then
PCI cards which make them more ideal for high-end video cards.
PCMCIA
PCMCIA (also referred to as PC Card) is the type of bus used for laptop computers. The name
PCMCIA comes from the group who developed the standard: Personal Computer Memory Card
International Association. PCMCIA was originally designed for computer memory expansion,
but the existence of a usable general standard for notebook peripherals led to many kinds of
devices being made available in this form. Typical devices include network cards, modems, and
hard disks.
AGP
AGP (Accelerated Graphics Port) is a high-speed point-to-point channel for attaching a graphics
graphics. AGP has been replaced over the past couple years by PCI Express. AGP cards and
motherboards are still available to buy, but they are becoming less common.
Types of Cards
Video Card
A video card (also known as graphics card) is an expansion card whose function is to generate
and output images to a display. Some video cards offer added functions, such as video capture,
TV tuner adapter, ability to connect multiple monitors, and others. Most video cards all share
similar components.
They include a graphics processing unit (GPU) which is a dedicated microprocessor optimized
for 3D graphics rendering. It also includes video BIOS that contains the basic program that
governs the video card’s operations and provides the instructions that allow the computer and
software to interface with the card. If the video card is integrated in the motherboard, it may use
the computer RAM memory. If not, it will have its own video memory called Video RAM.
This kind of memory can range from 128MB to 2GB. A video card also has a RAMDAC
(Random Access Memory Digital-to-Analog Converter) which takes responsibility for turning
the digital signals produced by the computer processor into an analog signal which can be
understood by the computer display. Lastly, they all have outputs such as an HD-15 connector
(standard monitor cable), DVI connector, S-Video, composite video or component video.
Sound Card
A sound card is an expansion card that facilitates the input and output of audio signals to/from a
computer under control of computer programs. Typical uses for sound cards include providing
the audio component for multimedia applications such as music composition, editing video or
audio, presentation/education, and entertainment. Many computers have sound capabilities built
in, while others require additional expansion cards to provide for audio capability.
Network Card
A network card is an expansion card that allows computers to communicate over a computer
network. It allows users to connect to each other either by using cables or wirelessly. Although
other network technologies exist, Ethernet has achieved near-ubiquity for a while now. Every
Ethernet network card has a unique 48-bit serial number called a MAC address, which is stored
External
Types of Connections
USB
USB (Universal Serial Bus) is a serial bus standard to interface devices. USB was designed to
allow many peripherals to be connected using a single standardized interface socket and to
Other convenient features include providing power to low-consumption devices without the need
for an external power supply and allowing many devices to be used without requiring
manufacturer specific, individual device drivers to be installed. USB is by far the dominating bus
Firewire (technically known as IEEE 1394 and also known as i.LINK for Sony) is a serial bus
interface standard for high-speed communications and isochronous real-time data transfer,
frequently used in a personal computer. Firewire has replaced Parallel ports in many
applications. It has been adopted as the High Definition Audio-Video Network Alliance (HANA)
standard connection interface for A/V (audio/visual) component communication and control.
PS/2
The PS/2 connector is used for connecting some keyboards and mice to a PC compatible
computer system. The keyboard and mouse interfaces are electrically similar with the main
difference being that open collector outputs are required on both ends of the keyboard interface
to allow bidirectional communication. If a PS/2 mouse is connected to a PS/2 keyboard port, the
There are different modes of data transfer. We are going to have a look at the following:
Programmed I/O
a. Programmed I/O
Programmable I/O is one of the I/O techniques other than the interrupt-driven I/O and direct
memory access (DMA). The programmed I/O is the simplest type of I/O technique for the
exchanges of data or any types of communication between the processor and the external
devices. With programmed I/O, data is exchanged between the processor and the I/O module.
The processor executes a program that gives it direct control of the I/O operation, including
sensing device status, sending a read or write command, and transferring the data. When the
processor issues a command to the I/O module, it must wait until the I/O operation is complete.
If the processor is faster than the I/O module, this is wasteful of processor time. The overall
operation.
The processor then executes that instruction by issuing a command to the appropriate I/O
module.
The I/O module will perform the requested action based on the I/O command issued by
the processor (READ/WRITE) and set the appropriate bits in the I/O status register.
The processor will periodically check the status of the I/O module until it finds that the
operation is complete.
To execute an I/O-related instruction, the processor issues an address, specifying the particular
I/O module and external device, and an I/O command. There are four types of I/O commands
unit may be instructed to rewind or to move forward one record. These commands are
Test: Used to test various status conditions associated with an I/O module and its
peripherals. The processor will want to know that the peripheral of interest is powered on
and available for use. It will also want to know if the most recent I/O operation is
Read: Causes the I/O module to obtain an item of data from the peripheral and place it in
an internal buffer. The processor can then obtain the data item by requesting that the I/O
Write: Causes the I/O module to take an item of data (byte or word) from the data bus
needs to make or receive a data transfer sends a signal. This will cause a program interrupt to be
set at a time appropriate to the priority level of the I/O interrupt. Relative to the total interrupt
system, the processors enter an interrupt service routine. The function of the routine will depend
upon the system of interrupt levels and priorities that is implemented in the processor. The
interrupt technique requires more complex hardware and software, but makes far more efficient
For input, the device interrupts the CPU when new data has arrived and is ready to be retrieved
by the system processor. The actual actions to perform depend on whether the device uses I/O
For output, the device delivers an interrupt either when it is ready to accept new data or to
given tasks continuously. When an input is available, such as when someone types a key on the
keyboard, then the CPU is interrupted from its work to take care of the input data. The CPU can
work continuously on a task without checking the input devices, allowing the devices themselves
to interrupt it as necessary.
2. I/O module gets data from peripheral whilst CPU does other work.
Interrupt Processing
A device driver initiates an I/O request on behalf of a process.
The device driver signals the I/O controller for the proper device, which initiates the
requested I/O.
The device signals the I/O controller that is ready to retrieve input, the output is complete
The CPU receives the interrupt signal on the interrupt-request line and transfer control
The interrupt handler determines the cause of the interrupt performs the necessary
The CPU returns to the execution state prior to the interrupt being signaled.
Different from Programmed I/O and Interrupt-Driven I/O, Direct Memory Access is a technique
for transferring data within main memory and external device without passing it through the
CPU.
It is a way to improve processor activity and I/O transfer rate by taking-over the job of
transferring data from the processor, and letting the processor do other tasks. This technique
overcomes the drawbacks of other two I/O techniques which are the time consuming process
when issuing command for data transfer and tie-up the processor in data transfer while the data
processing is neglected. It is more efficient to use the DMA method when a large volume of data
has to be transferred.
For DMA to be implemented, the processor has to share its‟ system bus with the DMA module.
Therefore, the DMA module must use the bus only when the processor does not need it, or it
must force the processor to suspend operation temporarily. The latter technique is more common
When the processor wishes to read or send a block of data, it issues a command to the DMA
Read or write command, sending through read and write control lines.
Number of words to be read or written, communicated on the data lines and stored in the
Starting location in memory to read from or write to, communicated on data lines and
transfers the entire block of data directly to or from memory without going through the
processor. When the transfer is complete, the DMA module sends an interrupt signal to the
Printer – Speed (Pages per minutes), Colour or non-colour, resolution (dpi), type (impact