0% found this document useful (0 votes)
15 views75 pages

Ch1.COA Tutorial

Uploaded by

nahit533
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views75 pages

Ch1.COA Tutorial

Uploaded by

nahit533
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 75

CHAPTER 1

DIGITAL LOGIC and DIGITAL SYSTEMS


Introduction
• Computer architecture refers to those attributes of a system
visible to a programmer or, put another way, those attributes
that have a direct impact on the logical execution of a
program.
• Examples of architectural attributes include
• the instruction set, the number of bits used to represent various
data types (e.g., numbers, characters), I/O mechanisms, and
techniques for addressing memory.
• Computer organization refers to the operational units and
their interconnections that realize the architectural
specifications.
• Organizational attributes include those hardware details
transparent to the programmer,
• such as control signals; interfaces between the computer and peripherals; and
History and Evolution of Computers
• architectural attributes and organizational attributes get
changed through time to bring powerful computer. Those
change in time is called Evolution of Computers.
• The first mechanical adding machine was invented by
Blaise Pascal in 1942.
• Later in 1971, Barson Gottfried Wilhelm Von Leibuiz of
Germany invented the first calculator for multiplication.
• Charles Babbage, a professor at Cambridge University is
considered to be the father of modern digital computers.
Cont’d
• Babbage designed a “Difference Engine” in the year
1822.
• In 1842, Babbage came out with new idea of analytical
engine that was intended to be completely automatic.
• It was to be capable of performing the basic arithmetic
problem at an average speed of 60 additions per
minute.
EARLY COMPUTERS
The Mark I computer (1937-1944)
• This was the first fully automatic calculating machine
designed by Howard. A. Aiken of Harvard University in
collaboration with IBM (International Business Machines) co-
operation.
• All this machine proved to be
– Extremely Reliable
– Very Complex In Design
– Huge In Size
• It was basically an electromechanical device, since both
mechanical and electronic components were used in its
design with 3000 electrical switches to control its operation.
• It was approximately 50 feet long and 8 feet high.
Cont’d
• ABC (Atanasoff -Berry Computer)[1939-1942]
• This electronic machine was developed by Dr. John Atanasoff to
solve certain mathematical equations.
• Clifford Berry , assistant of John Atanasoff also contributed a lot
towards ABC’s development.
• It used 45 vacuum tubes, for internal logic and capacitors for
storage.
• The ENIAC (Electronic Numerical Integrator and Calculator )
[1943-1946]
• The ENIAC was the first all electronic computer.

• It was developed at Moore School of Engineering of the Pennsylvania,


USA by a team led by professors J.Presper Eckert, and John Mauchly
• ENIAC was developed as a result of military need. It took up the wall
space in a 20x40 square feet room and used 18000 vacuum tubes.
• The addition of 2 numbers where achieved in 200 microseconds and
Cont’d
• The EDVAC (electronic discrete variable automatic
computer)
• The problem with ENIAC was its board. This was later
solved by the concept of “stored programs”.
• Developed by Dr.john Von Neumann.
• The basic idea behind the stored program is that a
sequence of instructions as well as data can be stored in the
memory of the computer for the purpose of automatically
directing the flow of operations.
• This concept considerably influenced the development of
modern digital computers.
• The EDVAC was designed on stored program concept.
• The UNIVAC I (Universal Automatic Computer) (1951)
• The UNIVAC was the first digital computer.
• Many UNIVAC machines were produced, the first of which was
installed in census bureau in 1951 and was continuously used
for 10 years.
• In 1952, the IBM corporation introduced 701 commercial
computer.
THE COMPUTER GENERATIONS
• The first generation (1942-1955)
• The early computers like ENIAC,EDVAC, etc …. and other
computers of their time were made possible by the
invention of “Vacuum tube” which was a fragile glass
device that could control and amplify electronic signals.
• These vacuum tube computers are referred to as first
generation computers.
• Vacuum tubes were used to perform logic operations and to
store data.
• This technology began the modern era of electronic
digital computers.
Cont’d
• Second generation (1955-1964)
• The transistor, a smaller and more reliable successor to the vacuum
tube, was invented in 1947.
• The Second generation emerged with the transistors being the brain
of the computer.
• The manual assembly of individual components and the cost of labor
involved at this assembly stage made the commercial production of
these computers difficult and costly.
• Third generation (1964-1975)
• Advances in electronics technology continued and the advence of
“micro electronics” technology made it possible to integrate large
number of circuit elements into very small surface of a silicon known
as “chips”.
• This new technology was called Integrated Circuits (IC).
Cont’d
• Fourth generation computers (1975-1985)
• Initially the IC contained only about 10-20 components.
• This technology was named SSI (Small Scale Integration).
• Later with the advancement in technology for manufacturing IC’s it
became possible to integrate up to a 100 components on a single chip.
This technology came to be known as Medium Scale Integration.
• Then came the era of Large Scale Integration (LSI) when it was
possible to integrate over 30,000 components on a single chip.
• FIFTH GENERATION (1985 onwards)
• These are also termed as knowledge information processing systems.
• These generations are with new parallel architecture, new memory
organization and new languages.
• These are functionally and conceptually different from the first four
generations.
• Most of these are used in artificial intelligence, Satellite connectivity etc.
First Second Third Fourth Fifth

1985
Time Frame 1942-1955 1955-1964 1964-1975 1975 - 1985
onwards

Integrated
LSI (Large VLSI (very
Circuit Vacuum Circuit
Transistor scale Large scale
Component Tube (Silicon
Integration ) Integration)
Chip)

Magnetic
Internal drum, Tape Magnetic Magnetic Integrated Integrated
Storage & Punched Cores Disks Circuits Circuits
cards

Memory
Capacity 4,000 32,000 128,000 100 million >100 million
(Characters)

IBM 360,
Popular IBM 650, IBM-1401, IBM 303X,
Honeywell ?
computers Univac – I CDC 36000 Univac 6000
200
Fundamental Building Blocks
LOGIC GATES
• Logic gates are the basic building blocks of a digital
computer.
• Logic gates are digital circuits that have two or more logic
inputs/electronic signals(except for NOT gate) and produce
a single output with a logic level based on the input.
• The input and output logic levels applied to these gates are
represented as Boolean variables.
Truth table
• A truth table is a table that describes the behavior of a logic
gate.
• It lists the value of the output for every possible
combination of the inputs and can be used to simplify the
number of logic gates and level of nesting in an electronic
circuit.
• Number of combinations or rows for truth table:
2n = Number of inputs combinations / row
n = number of inputs
2 = means binary number (0 or 1), constant
Two input truth table: 2n = 22 = 4 rows / combinations
Let us consider variables A and B for input, and Out for
output.
A B Out

0 0
0 1
1 0
1 1
Basic Logic Gates
• AND Gate
• An AND gate is an electronic circuit that generates an output signal of
1 only if all input signals are 1.
• An AND gate is the physical realization of logical multiplication.
• AND gate can have more than two inputs.
• The output of the AND gate with inputs A, B, and C is 1 only if A, B and C
are 1.
05/20/2025 18

Truth table and the block diagram for an AND gate

INPUT OUTPUT

A B Q= A.B

0 0 0

1 0 0

0 1 0

1 1 1
Cont’d
• OR Gate

• An OR gate is an electronic circuit that generates an

output signal of 1 if any of the input signals is 1.


• An OR gate is the physical realization of logical addition.

• OR gate can have more than two inputs.

• The output of the OR gate with inputs A, B, and C is a 1 if

A or B or C is a 1.
05/20/2025 20

Truth table and the block diagram


for an OR gate

INPUT OUTPUT

A B Q= A+B

0 0 0

0 1 1

1 0 1

1 1 1
Cont’d
• NOT gate
• NOT gate is an electronic circuit that generates an output
signal which is the reverse of the input signal.
• A NOT gate is the physical realization of the
complementation or logical inversion.
• A NOT gate is also known as an inverter because it inverts
the input.
• A NOT gate always has a single input.
• Connecting two NOT gates in series gives an output equal to
the input.
05/20/2025 22

Truth table and the block diagram


for a NOT gate

INPUT OUTPUT

A Q= A

0 1

1 0
Cont’d
• NOR GATE (Combines OR and NOT)
• A NOR gate is an electronic circuit that generates an output
signal of 1 when all input signals are 0 and it will be a 0 if
any input represents a 1.
• NOR gate is a complemented OR gate.
• The symbol  is used to represent NOR operation in Boolean
expression. Thus
A B = (A+B)= A.B
• The NOR gate can then be seen to be an OR gate followed by a
NOT gate.
05/20/2025 24

Truth table and the block diagram for a NOR


gate
INPUT OUTPUT

A B Q= A.B

0 0 1

1 0 0

0 1 0

1 1 0
• NAND GATE (Combines AND & NOT)
• A NAND gate is an electronic circuit that generates an output
signal of 1 if any one of the input is a 0 and will be a 0 when all
input signals are 1.
• NAND gate is a complemented AND gate.
• The symbol  is used to represent NAND operation in Boolean
expression. Thus
A B = (A.B)= A+B
• The NAND gate can then be seen to be an AND gate followed by a
NOT gate.
05/20/2025 26

Truth table and the block diagram for an Ex-


OR gate

INPUT OUTPUT

A B Q= A.B+A.B

0 0 0

1 0 1
0 1 1
1 1 0
05/20/2025 27

Logic expressions
Functional Units of Digital System
Input unit
Input units are used by the computer to read the data.
The most commonly used input devices are keyboards, mouse, joysticks,
trackballs, microphones, etc.
Whenever a key is pressed, the corresponding letter or digit is
automatically translated into its corresponding binary code and transmitted
over a cable to either the memory or the processor.
Central processing unit
Central processing unit commonly known as CPU can be referred as an
electronic circuitry within a computer that carries out the instructions given by
a computer program by performing the basic arithmetic, logical, control and
input/output (I/O) operations specified by the instructions.
Memory unit
The Memory unit can be referred to as the storage area in which programs are
kept which are running, and that contains data needed by the running
programs.
The Memory unit can be categorized in two ways namely, primary memory
and secondary memory.
Arithmetic & logical unit
Most of all the arithmetic and logical operations of a
computer are executed in the ALU (Arithmetic and Logical
Unit) of the processor.
It performs arithmetic operations like addition, subtraction,
multiplication, division and also the logical operations like
AND, OR, NOT operations.
Control unit
The control unit is a component of a computer's central
processing unit that coordinates the operation of the
processor.
It tells the computer's memory, arithmetic/logic unit and
input and output devices how to respond to a program's
instructions.
The control unit is also known as the nerve center of a
computer system
Output Unit
The primary function of the output unit is to send the
processed results to the user. Output devices display
Digital Logic Circuits
The digital circuitry in digital computers and other digital systems is
designed, and its behavior is analyzed, with the use of a
mathematical discipline known as Boolean algebra.
Boolean algebra – a symbolic logic invented by English
mathematician George Boole in 1854.
Each variable in Boolean algebra has either of the two values: true
or false.
The original purpose of this two-state algebra was to solve
logic problems.
It is ideally suited to digital circuit analysis.
05/20/2025 32

Basic Theorems
A+B=B+A AB = BA
A + (B +C) = (A +B) + C A (BC) = (AB) C
A (B + C) = AB +AC A + BC = (A + B) (A + C)
A+0=A A*1=A
A+1=1 A*0=0
A+A=A A*A=A
A + A’= 1 A * A’ = 0
(A’)’ = A A’’ = A
(A + B)’ = A’B’ (AB)’ = A’ + B’
A + AB = A A (A + B) = A
A + A’B = A +B A (A’ + B) = AB
Simplification Using Boolean Algebra
• A simplified Boolean expression uses the fewest gates
possible to implement a given expression.

AB+A(B+C)
B +B(B+C)

C
05/20/2025 34

EXAMPLES:
1. Y = AB’ +AB
= A ( B’ +B )
=A
2. Y = AB + AC + BD + CD
=A(B+C)+D(B+C)
= ( A + D ) ( B + C)
3. Z = ( A’ + B ) ( A + B )
= A’A + A’B + BA + BB
= 0 + A’B + BA + BB
= A’B + BA + B
= B ( A’ + A + 1)
=B
Map Simplification
• The Map method involves a simple, straightforward

procedure for simplifying Boolean expressions.


• The map method is also known as Karnaugh map or K-

map.
• Each combination of the variables in a truth table is called

a mid-term.
• When expressed in a truth table a function of n variables will

have 2^n min-terms, equivalent to the 2^n binary numbers


obtained from n bits.
• Example:
• There are four min-terms in a two variable map.
• Therefore, the map consists of four squares, one for each min-
term.
• The 0's and 1's marked for each row, and each column designates
the values of variable x and y, respectively.
• Reading assignment
• Find the K-Map simplification for three input variables?
Standard Forms of Boolean Expressions
All Boolean expressions, regardless of their form,
can be converted into either of two standard forms:
• The sum-of-products (SOP) form
• The product-of-sums (POS) form

Standardization makes the evaluation, simplification,


and implementation of Boolean expressions much
more systematic and easier.
The Sum-of-Product (SOP) Form
• An SOP expression   In an SOP form, a
when two or more single overbar
product terms are cannot extend
summed by Boolean over more than
addition. one variable;
• Examples: however, more
AB  ABC than one variable
ABC  CDE  B CD in a termAcan
B C have
A B  A BC  AC an overbar:
• Also:  ABC
example:
A  A B C  BCD is OK!
05/20/2025 39
General Expression  SOP
• Any logic expression can be changed into SOP form by
applying Boolean algebra techniques.
ex:
A( B  CD)  AB  ACD
AB  B (CD  EF )  AB  BCD  BEF
( A  B )( B  C  D)  AB  AC  AD  BB  BC  BD
( A  B )  C ( A  B )C ( A  B )C  AC  BC

05/20/2025 40
The Standard SOP Form
• A standard SOP expression is one in which all the
variables in the domain appear in each product term in
the expression.
• Example:
AB CD  A B CD  ABC D
• Standard SOP expressions are important in:
• Constructing truth tables
Converting Product Terms to Standard SOP
• Step 1:
• Multiply each nonstandard product term by a term
made up of the sum of a missing variable and its
complement.
• This results in two product terms.
• As you know, you can multiply anything by 1 without
changing its value.
• Step 2:
• Repeat step 1 until all resulting product term contains
all variables in the domain in either complemented or
uncomplemented form.
• In converting a product term to standard form, the number
of product terms is doubled for each missing variable.
Cont’d
• Example
• Convert the following Boolean expression into standard
SOP form:
AB C  A B  ABC D
AB C  AB C ( D  D )  AB CD  AB CD

A B  A B (C  C )  A B C  A B C
A B C ( D  D )  A B C ( D  D )  A B CD  A B CD  A B C D  A B C D

AB C  A B  ABC D  AB CD  AB CD  A B CD  A B CD  A B C D  A B C D  ABC D
POS
• Multiplication of two or more integers and the result we get is known
as the Product of the Sum. It is a crucial component of mathematics
and has many uses. The product of a Sum is a function that computes
the product of two or more numbers.
• For getting the standard POS form of the given non-standard POS
form, we will add all the variables in each product term that do not
have all the variables. By using the Boolean algebraic law (x * x' = 0)
and by following the below steps, we can easily convert the normal
POS function into a standard POS form.
By adding each non-standard sum term to the product of its missing
variable and its complement, which results in 2 sum terms
Applying Boolean algebraic law, x + y z = (x + y) * (x + z)
By repeating step 1, until all resulting sum terms contain all variables
• By these three steps, we can convert the POS function into a standard
POS function.
Combinational Circuits
• A combinational circuit comprises of logic gates whose

outputs at any time are determined directly from the present


combination of inputs without any regard to previous inputs.
• A combinational circuit performs a specific information-

processing operation fully specified logically by a set of


Boolean functions.
• The basic components of a combinational circuit are: input

variables, logic gates, and output variables.


Combinational Circuits
The 'n' input variables The combinational circuit
that performs the addition of
come from an external
two bits is called a half
source whereas the 'm' adder and the one that
performs the addition of
output variables go to an
three bits (two significant
external destination. bits and a previous carry) is
In many applications, the a full adder.

source or destination are


storage registers.
• The design procedure of a combinational circuit involves the

following steps:
• The problem is stated.

• The total number of available input variables and required output variables is

determined.
• The input and output variables are allocated with letter symbols.

• The exact truth table that defines the required relationships between inputs and

outputs is derived.
• The simplified Boolean function is obtained from each output.

• The logic diagram is drawn.


Half - Adder
• A Half-adder circuit needs two binary inputs and two binary outputs.
• The input variable shows the augend and addend bits whereas the output variable
produces the sum and carry.
• We can understand the function of a half-adder by formulating a truth
table.
• The truth table for a half-adder is:

• 'x' and 'y' are the two inputs, and S (Sum) and C (Carry) are the two
outputs.
• The Carry output is '0' unless both the inputs are 1.
• 'S' represents the least significant bit of the sum.
Full - Adder
• This circuit needs three binary inputs and two binary outputs.

• The truth table for a full-adder is:


Basic Flip-Flop
• Flip flops are an application of logic gates.

• A flip-flop circuit can remain in a binary state indefinitely (as

long as power is delivered to the circuit) until directed by an


input signal to switch states.
• Three Types of Flip flop

• S-R flip-flop

• J-K Flip-Flop

• T Flip-Flop
• SR Flip Flop
 This is the most common flip-flop among all.
 This simple flip-flop circuit has a set input (S) and a reset input (R).
 In this system, when you Set “S” as active, the output “Q” would be high,
and “Q‘” would be low.
 Once the outputs are established, the wiring of the circuit is maintained
until “S” or “R” go high, or power is turned off.
The first input condition in the table is R=0, S=0. Since 0 input has no effect on its

output, the Flip-Flop retains its previous state. Hence Q remains unchanged.

The second input condition R=0, S=1 forces the output of NOR gate2 low.

This low output will reach NOR gate1 and when both inputs of NOR gates1 is low, its

inputs Q will be high.

Thus, a 1 at the S input will SET the flip-flop and Q will be equal to 1.
The third input condition R=1, S=0 will force the output of NOR gate1 to low.

This low will reach NOR gate2 and forces its outputs to high. Hence, when R=1, S=0, then Q=0, Q=1.

Thus, the flip-flop is RESET.

The last input condition in the table R=1, S=1 is forbidden since it forces both the NOR gates to the

low state, means both Q=0, and Q=0 at the same time, which violets the basic definition of flip-flop

that requires Q to be the complement of Q.

Hence, this input condition is forbidden and its output is unpredictable.


JK FLIP-FLOP
 In RS flip-flop, the input R= S=1 is called forbidden as it causes an
unpredictable output.
 In JK flip-flop this condition is used by changing the RS flip-flop in some
way.
 In JK flip-flop both input can be high simultaneously and the
corresponding toggle output makes the JK flip-flop a good choice to build
counter- a circuit that counts the number of +ve or –ve clock edges.
 Fig 1.18 shows one way to build a JK flip-flop.
J-K Flip-Flop
T Flip-Flop:
• T Flip-Flop:
 A T flip-flop is like a JK flip-flop. These are basically single-input versions of
JK flip-flops.
 This modified form of the JK is obtained by connecting inputs J and K
together.
 It has only one input along with the clock input.
 These flip-flops are called T flip-flops because of their ability to complement
their state i.e. Toggle, hence they are named Toggle flip-flops.
PLA
• Programmable logic array (PLA)
• has an array of inverters, AND gates and OR gates
• can implement any logic function (given limits on
numbers of inputs and outputs)
Example:
consider a system with four inputs A, B, C and D and
three output X, Y and Z, where
X  A B C D+A B CD
Y  A B CD  ABCD
Z  A B C D  A B CD  ABCD
05/20/2025 58

The structure of a simple PLA


Flip-Flop
• A flip-flop is a binary cell capable of storing one bit of
information.
• It has two outputs, one for the normal value and one for
the complement value of the bit stored in it.
• A flip-flop maintains a binary state until directed by a clock
pulse to switch states.
• Flip-flop exist in one of the two states and in the absence
of input, remains in that state.
• The flip-flop has 2 outputs, which are always complement to
each other.
• These are generally labeled as Q and Q`.
05/20/2025 60

flip-flop (logical circuit)


Register

• a collection of binary storage elements


• included a set of flip-flop
• n-bit register store n-bit binary information
• Frequently used to perform simple data storage and data
movement and processing operations
Cont’d
• fundamental building blocks within computers
• can be constructed using D flip-flops
• some are used for storage, others for
input/output
Counters
• A register that goes through a predetermined sequence
of states upon the application of input pulses is called a
counter.
• The input pulses may be clock pulses or may originate
from an external source.
• They may occur at uniform intervals of time or at random.
• Each input pulse increments the state by 1; the machine
can therefore be viewed as counting the input pulses.
Cont’d
• Counters are found in almost all equipment containing
digital logic.
• They are used for counting the number of occurrences
of an event and are useful for generating timing
signals to control the sequence of operations in digital
computers.
Register Transfer Notation
Introduction
• Symbolic and precise way to describe the effect of an
instruction.
• Example:
MOVE D3,D2
ÞThe contents of register D3 are copied to register D2.
ÞA common notation to designate/leble this is:
D2  [D3]
· Brackets around D3 indicate “contents of”
· Left arrow indicates “receives”
Register Transfer Notation: Instructions
• DEST  Result
• SUB D5, D7
• can be described by:
D7  [D7] - [D5]
• ADD D2, $001004
• Here, $001004 is a memory address. The same notation still
suffices:
$001004  [$001004] + [D2]
Register transfer
• The registers are assumed to be basic components of the
digital system
• Register transfer operation: movement on the data
stored in register and the processing performed on
the data
• Three basic components
• The set of registers in digital systems
• The operations performed on the data
• Control on the sequence of operations
Register Transfer Operations
• Notation for register: uppercase letters (sometime followed by
numbers)
• AR: address register: Specifies the address in memory of the word to be
written from or read into the MBR.
• PC: program counter: Contains the address of the next instruction-pair to
be fetched from memory.
• IP: instruction register: Contains the 8-bit opcode instruction being
executed.
Physical Considerations
Technology Parameters
• Specific gate implementation technologies are characterized by
the following parameters:
• Fan-in – the number of inputs available on a gate
• Fan-out – the number of standard loads driven by a gate output
• Logic Levels –
• the signal value ranges for 1 and 0 on the inputs and 1 and 0 on the outputs
• Noise Margin –
• the maximum external noise voltage superimposed on a normal input value
that will not cause an undesirable change in the circuit output
• Cost for a gate –
• a measure of the contribution by the gate to the cost of the integrated circuit
• Propagation Delay –
• The time required for a change in the value of a signal to propagate from an
input to an output
• Power Dissipation –
• the amount of power drawn from the power supply and consumed by the
05/20/2025 72

Fan-in
For a given logic family, the maximum number of inputs
available on any one gate is called the fan-in.

Fan-in

N
05/20/2025 73

Fan-out
The fan-out of a logic gate is the number of inputs
that the gate can drive without exceeding its worst-
case loading specs.

Fan-out

N
05/20/2025 74

Propagation Delay
• Propagation delay is the time for a change on an input of a gate
to propagate to the output.
• Delay is usually measured at the 50% point with respect to the
H and L output voltage levels.
• High-to-low (tPHL) and low-to-high (tPLH) output signal changes
may have different propagation delays.
• High-to-low (HL) and low-to-high (LH) transitions are defined
with respect to the output, not the input.
• An HL input transition causes:
• an LH output transition if the gate inverts and

• an HL output transition if the gate does not invert.


05/20/2025 75

`
END of chapter one!!
Read more to get more concepts

You might also like