Professional Documents
Culture Documents
COA Lab Edited
COA Lab Edited
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
Computer Organization and Architecture
COMPUTER ORGANIZATION
ANDARCHITECTURE
SUBJECT CODE-BCS-352
& KCA-152
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
Experiment No: 1
1.1 Objective 1.2 Apparatus required 1.3 Theory 1.4 Observation table 1.5 Calculation 1.6 Result 1.7
Discussion 1.8 Precautions
AND-7408, OR-7432,
EX-OR-7486 EX-NOR-74266
3 IC’s
4 WIRE CUTTER, 01
1.3 THEORY:
Logic gates are idealized or physical devices implementing a Boolean function, which it
performs a logical operation on one or more logical inputs and produce a single output.
Depending on the context, the term may refer to an ideal logic gate, one that has for instance
zero rise time and unlimited fan out or it may refer to a non-ideal physical device.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA
LAB
AND Gate: The AND operation is defined as the output as (1) one if and only if all the inputs are
(1) one. 7408 is the two Inputs AND gate IC.A&B are the Input terminals &Y is the Output terminal.
Y = A.B
OR Gate: The OR operation is defined as the output as (1) one if one or more than 0 inputs are
(1) one. 7432 is the two Input OR gate IC. A&B are the input terminals & Y is the Output terminal.
Y=A+B
NOT GATE: The NOT gate is also known as Inverter. It has one input (A) & one output (Y). IC No.
is 7404. Its logical equation is,
Y = A’
NAND GATE: The IC no. for NAND gate is 7400. The NOT-AND operation is known as NAND
operation. If all inputs are 1 then output produced is 0. NAND gate is inverted AND gate.
Y = (A. B)’
NOR GATE: The NOR gate has two or more input signals but only one output signal. IC 7402 is
two I/P IC. The NOT- OR operation is known as NOR operation. If all the inputs are 0 then the
O/P is 1. NOR gate is inverted OR gate.
Y = (A+B)’
EX-OR GATE: The EX-OR gate can have two or more inputs but produce one output. 7486 is two
inputs IC. EX-OR gate is not a basic operation & can be performed using basic gates.
Y=A B
EX-NOR GATE: The EX-NOR gate can have two or more inputs but produce one output. 7486 is
two inputs IC. EX-NOR gate is not a basic operation & can be performed using basic gates.
Y = (A B)’ = AʘB
OBSERVATION TABLE
1. AND GATE: - Function of AND gate is to give the output true when both the inputs
are true. In all the other remaining cases output becomes false. Following table
justifies the statement:-
A B Y
0 0 0
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
0 1 0
1 0 0
1 1 1
2. OR GATE: - Function of AND gate is to give the output true when any of the inputs
is/or true. In all the other remaining case(when all inputs are false) output
becomes false. Following table justifies the statement:-
A B Y
0 0 0
0 1 1
1 0 1
1 1 1
3. NOT GATE: - Function of NOR gate is to reverse the nature of the input .It converts
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
true input to false and vice versa. Following table justifies the statement :-
A Y
0 1
1 0
UNIVERSAL GATES
4. NAND GATE: - Function of NAND gate is to give the output true when any of the
inputs is/or false. In all the other remaining case(when all inputs are true) output
becomes false. Following table justifies the statement:-
A B Y
0 0 1
0 1 1
1 0 1
1 1 0
5. NOR GATE: - Function of NOR gate is to give the output true when all inputs are
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
false. In all the other remaining cases output becomes false. Following table justifies
the statement:-
A B Y
0 0 1
0 1 0
1 0 0
1 1 0
SPECIAL GATES
6. EX-OR GATE : - Function of EX-OR gate is to give the output true when two inputs
are in different states (if one is true and another is false). In all the other remaining
cases output becomes false. Following table justifies the statement:-
A B Y
0 0 0
0 1 1
1 0 1
1 1 0
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
7. EX-NOR GATE: - Function of AND gate is to give the output true when both the
inputs are same in state(either both are true or both are false). In all the other
remaining cases output becomes false. Following table justifies the statement:-
A B Y
0 0 1
0 1 0
1 0 0
1 1 1
Result:-
All logic gates are verified. Observed output matches theoretical concepts.
PRECAUTION:-
1. Connecting wires should be rubbed with sand papers so that there is no rust.
2. Make sure that the apparatus is switched off while placing ICs and connecting of wires.
4. ICs are placed in a proper way in the breadboard. There is no short of current in the in
same inputs.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
Experiment No: 2
1.1 Objective 1.2 Apparatus required 1.3 Theory 1.4 Observation table 1.5 Calculation 1.6 Result 1.7
Discussion 1.8 Precautions 1.9 Pre-Requisite 1.10 Post- Requisite
OBJECTIVE: To design and construct half adder and half subtractor circuits and verify the truth table
using logic gates.
EX-OR 7486,
NOT 7404
1.3 THEORY:
HALF ADDER:
A half adder has two inputs for the two bits to be added and two outputs one from the sum ‘
S’ and other from the carry ‘ c’ into the higher adder position. Above circuit is called as a carry signal
from the addition of the less significant bits sum from the X-OR Gate the carry out from the AND
gate.
FULL ADDER:
A full adder is a combinational circuit that forms the arithmetic sum of input; it consists of
three inputs and two outputs. A full adder is useful to add three bits at a time but a half adder
cannot do so. In full adder sum output will be taken from X-OR Gate, carry output will be taken from
OR Gate.
The difference can be applied using X-OR Gate, borrow output can be implemented using an
AND Gate and an inverter.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA
LAB
LOGIC DIAGRAM:
HALF ADDER
TRUTH TABLE:
A B CARRY SUM
0 0 0 0
0 1 0 1
1 0 0 1
1 1 1 0
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
FULL ADDER
TRUTH TABLE:
A B C CARRY SUM
0 0 0 0 0
0 0 1 0 1
0 1 0 0 1
0 1 1 1 0
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
1 0 0 0 1
1 0 1 1 0
1 1 0 1 0
1 1 1 1 1
CARRY = AB + BC + AC
RESULT: The half adder and full adder circuits are studied and verified.
PROCEEDURE:
PRECAUTIONS:-
1. Connecting wires should be rubbed with sand papers so that there is no rust.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
3. Make sure that the apparatus is switched off while placing ICs and connecting of wires.
4. ICs are placed in a proper way in the breadboard. There should not be shorting of wires in
the same input.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
Experiment No: 3
1.1 Objective 1.2 Apparatus required 1.3 Theory 1.4 Observation table 1.5 Calculation 1.6 Result 1.7
Discussion 1.8 Precautions 1.9 Pre-Requisite 1.10 Post- Requisite
OBJECTIVE: To design and construct half adder and half subtractor circuits and verify the truth table
using logic gates.
EX-OR 7486,
NOT 7404
1.3 THEORY:
HALF SUBTRACTOR:
The half subtractor is constructed using X-OR and AND Gate. The half subtractor has two
input and two outputs. The outputs are difference and borrow. The difference can be applied using
X-OR Gate, borrow output can be implemented using an AND Gate and an inverter.
FULL SUBTRACTOR:
The full subtractor is a combination of X-OR, AND, OR, NOT Gates. In a full subtractor the
logic circuit should have three inputs and two outputs. The two half subtractor put together gives a
full subtractor .The first half subtractor will be C and A B. The output will be difference output of
full
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA
LAB
subtractor. The expression AB assembles the borrow output of the half subtractor and the second
term is the inverted difference output of first X-OR.
LOGIC DIAGRAM:
HALF SUBTRACTOR
TRUTH TABLE:
A B BORROW DIFFERENCE
0 0 0 0
0 1 1 1
1 0 0 1
1 1 0 0
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
FULL SUBTRACTOR:
TRUTH TABLE:
A B C BORROW DIFFERENCE
0 0 0 0 0
0 0 1 1 1
0 1 0 1 1
0 1 1 1 0
1 0 0 0 1
1 0 1 0 0
1 1 0 0 0
1 1 1 1 1
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
RESULT: The half Subtractor and full Subtractor circuits are studied and verified.
PROCEEDURE:
PRECAUTIONS:-
1. Connecting wires should be rubbed with sand papers so that there is no rust.
4. Make sure that the apparatus is switched off while placing ICs and connecting of wires.
6. ICs are placed in a proper way in the breadboard. There should not be shorting of wires in
the same input.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
EXPERIMENT No. 4
Objective: To design and implement a binary to gray and gray to binary converter.
APPARATUS REQUIRED:
4 WIRE CUTTER, 01
Theory:
The reflected binary code, also known as Gray code after Frank Gray, is a binary numeral system where two
successive values differ in only one bit. The reflected binary code was originally designed to prevent spurious
output from electromechanical switches. Today Gray codes are widely used to facilitate error correction in
digital communications such as digital terrestrial television and some cable TV systems.
Decimal B2 B1 B0 G2 G1 G0
0 0 0 0 0 0 0
1 0 0 1 0 0 1
2 0 1 0 0 1 1
3 0 1 1 0 1 0
4 1 0 0 1 1 0
5 1 0 1 1 1 1
6 1 1 0 1 0 1
7 1 1 1 1 0 0
Logical Equations:
G2 = B2B1'B0' + B2B1'B1 + B2B1B0' + B2B1B0
G1 = B2'B1B0' + B2'B1B0 + B2B1'B0' + B2B1'B0
G0 = B2'B1'B0 + B2'B1B0' + B2B1'B0 + B2B1B0'
Simplification:
G2 = B2B1'(B0' + B0) + B2B1(B0' + B0)
= B2B1' + B2B1
= B2(B1' +B1)
= B2
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
Logic Design:
Logic Equations:
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
Decimal Gray Input Binary Output
Decimal G2 G1 G0 B2 B1 B0
0 0 0 0 0 0 0
1 0 0 1 0 0 1
2 0 1 0 0 1 1
3 0 1 1 0 1 0
4 1 0 0 1 1 1
5 1 0 1 1 1 0
6 1 1 0 1 0 0
7 1 1 1 1 0 1
B2 = G2G1G0' + G2G1G0 + G2G1'G0 + G2G1'G0'
B1 = G2'G1G0 + G2'G1G0' + G2G1'G0 + G2G1'G0'
B0 = G2'G1'G0 + G2'G1G0' + G2G1G0 + G2G1'G0'
Simplification:
B2 = G2G1G0' + G2G1G0 + G2G1'G0 + G2G1'G0'
= G2G1(G0' + G0) + G2G1'(G0 + G0')
= G2G1 + G2G1'
= G2(G1+G1')
= G2
B1 = G2'G1(G0 + G0') + G2G1'(G0 + G0')
= G2'G1 + G2G1'
= G2 XOR G1
B0 = G2'G1'G0 + G2'G1G0' + G2G1G0 + G2G1'G0'
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
Logic Diagram:
Preparation:
Keep a IC pin diagram with you for proper usage of the IC 7486
Insert IC 7486 in the Bread board slots
Make connection as per logic diagram
Result: The circuit is tested and verified with the truth table.
Precaution:
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
Experiment No: 5
STUDY OF DECODERS
1.1 Objective 1.2 Apparatus required 1.3 Theory 1.4 Logic circuit 1.5 Observation table 1.6 Procedure
1.7 Precautions 1.8 Result
1.3 THEORY:
De-multiplexer circuit can also be realized using a decoder circuit with enable.
In digital electronics, a decoder can take the form of a multiple-input, multiple-output logic
circuit that converts coded inputs into coded outputs, where the input and output codes are
different e.g. n-to-2n , binary-coded decimal decoders. Decoding is necessary in applications such
as data multiplexing, 7 segment display and memory address decoding. The example decoder
circuit would be an AND gate because the output of an AND gate is "High" (1) only when all its
inputs are "High." Such output is called as "active High output". If instead of AND gate, the
NAND gate is connected the output will be "Low" (0) only when all its inputs are "High". Such
output is called as "active low output.
3:8 Decoder
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA
LAB
3:8 IC Diagram
1.6 PROCEDURE:
1.7 Precautions:-
1. Connecting wires should be rubbed with sand papers so that there is no rust.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
2. Make sure that the apparatus is switched off while placing ICs and connecting of wires.
4. ICs are placed in a proper way in the breadboard. There is no short of current in the in same
inputs
1.8 RESULT: Multiplexer De-multiplexer and decoders are studied and verified.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
Experiment No: 6
STUDY OF MULTIPLEXERS
1.1 Objective 1.2 Apparatus required 1.3 Theory 1.4 Logic circuit 1.5 Observation table 1.6 Procedure
1.7 Precautions 1.8 Result
1.3 THEORY:
Multiplexers are very useful components in digital systems. They transfer a large number of
information units over a smaller number of channels, (usually one channel) under the control of
selection signals. Multiplexer means many to one. A multiplexer is a circuit with many inputs but
only one output. By using control signals (select lines) we can select any input to the output.
Multiplexer is also called as data selector because the output bit depends on the input data bit that
is selected. The general multiplexer circuit has 2n input signals, n control/select signals and 1
output signal.
De-multiplexers perform the opposite function of multiplexers. They transfer a small number of
information units (usually one unit) over a larger number of channels under the control of
selection signals. The general de-multiplexer circuit has 1 input signal, n control/select signals
and 2n output signals.
4:1 Multiplexer
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA
LAB
8:1 Multiplexers
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
1.6 PROCEDURE:
1.7 Precautions:-
1. Connecting wires should be rubbed with sand papers so that there is no rust.
3. Make sure that the apparatus is switched off while placing ICs and connecting of wires.
1.8 RESULT: Multiplexer De-multiplexer and decoders are studied and verified.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
Experiment No: 7
STUDY OF FLIP-FLOPS
1.1 Objective 1.2 Apparatus required 1.3 Theory 1.4 Observation table 1.5 Procedure 1.6 Precautions 1.7
Result.
3 IC 7400, IC 7404 10
1.3 Theory: - In ca se of sequential circuits the effect of all previous inputs on the outputs is represented by a
state of the circuit. Thus, the output of the circuit at any time depends upon its current state and the input .
These also determine the next stat e of the circuits . the relations hip that exists among the inputs, outputs,
present states and next states can be specified by either the state table or the state diagram.
1.4 Observation Table(State Table): - The state table representation of a sequential circuit consists of three
sections labeled present state next state and output . The present state designates the state of flip-flops before the
occurrence of a clock pulse. The next state shows the states of flip-flops after the clock pulse, and output section
lists the value of the output variables during the present value.
Flip-Flop:-The basic one bit digital memory circuit is known as flip-flop. It can store either 0 or 1.
Flip-flops are classifieds according to the number of inputs.
R-S Flip-Flop:- The circuit is similar to SR latch except enable signal is replaced by clock pulse.
Logic Diagram
D Flip-Flop: -The modified clocked SR flip- flop is known as D-flip-flop. From the truth table of SR flip-flop we
see that the output of the SR flip-flop is in unpredictable state when the inputs are same and high. In many
practical applications, these input conditions are not required. These input conditions can be avoided by
making then complement of each other.
Logic Diagram
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA
LAB
J-K Flip-Flop:- In a RS flip-flop the input R=S=1 leads to an indeterminate output. The RS flip-flop circuit may be
re-joined if both inputs are 1 than also the outputs are complement of each other.
Logic Diagram
T Flip-Flop
Logic Diagram
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB
1.5 Procedure:-
1. Connections are made As per circuit diagram .
2. Verify truth-tables for various combinations of input.
1.6 RESULT: - Study and verified truth-tables of various flip-flops.
1.7 Precaution:-
1. All the IC’s should be checked before use the apparatus.
2. All LED’s should be checked.
3. All connections should be tight.
4. Always connect GROUND first and then Vcc
5. The circuit should be off before change the connections .
After completing the experiment switch off the supply to apparatus .
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA &
LAB MANUAL
Experiment No: 8
STUDY OF ALU
1.1 Objective 1.2 Apparatus required 1.3 Theory 1.4 Observation table 1.5 Procedure 1.6 Precautions 1.7
Result.
3 IC 7400, IC 7404 10
An arithmetic logic unit (ALU) is a digital circuit used to perform arithmetic and
1.3 Theory: -
logic operations. It represents the fundamental building block of the central processing unit
(CPU) of a computer. Modern CPUs contain very powerful and complex ALUs.
4-bit Arithmetic Logic Unit (ALU) performs all the possible 16 logic operations on two
variables and a variety of arithmetic operations. An arithmetic logic unit (ALU) is at the heart
of a modern microprocessor, and the adder cell is the elementary unit of an ALU.
8 Bit ALU design is a combinational circuit which adds two binary numbers of 8 bit lengths.
Block Diagram
Truth table:
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA
LAB MANUAL
1.5 Procedure:-
1. Connections are made as per circuit diagram.
2. Verify truth-tables for various combinations of input.
1.6 RESULT: - Study and verified truth-tables of 4 bit ALU.
1.7 Precaution:-
1. All the IC’s should be checked before use the apparatus.
2. All LED’s should be checked.
3. All connections should be tight.
4. Always connect GROUND first and then Vcc.
5. The circuit should be off before change the connections.
6. After completing the experiment switch off the supply to apparatus.
LDC GROUP OF INSTITUTIONS OFFERS: B.TECH., MBA, MCA, POLYTECHNIC DIPLA, ITI, BBA & BCA