Sunteți pe pagina 1din 6

Outlines

Introduction
Digital Logic Design (DLD) Digital Systems (Concept of Discrete & Binary)
Lecture 2 Binary Logic (Logic Gates)
AND
Dr. Jamshed Iqbal OR
Associate Professor NOT
Department of Electrical Engineering NAND and NOR
XOR
Conversion: Other No.systems Decimal

National University of Computer &


Emerging Sciences

Digital Systems Digital Systems


A digital system is a system that How to obtain discrete data?
manipulates discrete elements information Either emerge from the nature of the data
represented internally in binary form being processed
Discrete: Example: Students deposit record (Finite
fields like Name, Roll no., fees, fine)
Any set that is restricted to a finite number of
elements contains discrete information Quantized (sampled) from a continuous
process
Examples:
- Set of 10 decimal digits Example
- 26 letters of the alphabet (ADCs)
- 52 playing cards
- 64 squares of chessboard
Digital Systems
Digital Systems
Analog Signal
Discrete values. But how many?
- Value of signal exists The whole basis of digital electronics is
at any instant of time
- Occurs in continuous based on the simplicity of the on/off or
form 0/1 model
All quantities and values must be coded
Digitized Signal
into this bi-level set of 0s and 1s
- Value of signal only All storage and transmission of values in a
exists at discrete
points in time
digital system occurs using these two
binary digits (bits)

Binary Logic (Gates)


Digital Systems Digital circuits process data by means of
Voltage range for logic levels binary logic elements (called as logic
gates)
Examples 1: Adder IC (7480)
2.0 V 2.7V (TTL), 3.5 V (CMOS)

0.5 V 0.8V (TTL), 1.5 V (CMOS)


Basic Binary Operations Binary Logic (AND)
x y z
Binary Arithmetic AND 0 0 0
Addition 0 1 0
x y
Subtraction 1 0 0
z
Multiplication 1 1 1
Binary Logic z=xy=xy
AND
x , y = 0 (for Open)
OR = 1 (for Close) x AND y is equal to z
NOT
z = 1 if and only if (iff) x=1 and y=1

Binary Logic (OR) Binary Logic (NOT)


x y z x z
OR - Also called as Inverter
x 0 0 0 0 1
- Compliment operation
0 1 1 1 0
y
z 1 0 1
z = x = x
1 1 1
z=x+y
x , y = 0 (for Open) NOT x is equal to z
= 1 (for Close) x OR y is equal to z
z = 1 if x=1 or if y=1 or if both =1
Three Levels Binary Logic (Caution)
Binary logic and binary arithmetic are
similar (but NOT same)
Dot . for multiplication and also for AND
x Plus + for addition and also for OR
z
Prime ' for complement and also for NOT
Arithmetic variables designates number
1 bit memory cell (RAM) that may consist of many digits, whereas,
Logical variable is always 1 or 0 x y z
Example: 0 0 0
1 OR 1 = 1 0 1 1
1 plus 1 = (10)2 1 0 1
1 1 1

Timing Diagram (AND) NAND, NOR & X-OR


NAND (N AND) = AND + NOT
NOR (N OR) = OR + NOT
Practice Q
Make Truth Table of NAND and NOR?
Also draw Timing Diagram of both gates?
XOR (Exclusive OR)

Draw Timing Diagram of OR, x, y Make Truth Table of X-OR and comment
anything special?
Table of Gates Table of Gates (Contd)

Any No. Sys. Decimal Any No. Sys. Decimal


Let us first revise who things go in Binary No. System: Base 2
Decimal number system Only two digits: 0 or 1
Base (or radix): 10 system Convert (11010)2 into Decimal
Only 10 numbers (09)
7392 means 7 thousands, plus 3
hundreds, plus 9 tens, plus 2 units. i.e. Practice Q
Convert (11010.11)2 into Decimal
Convert (4021.2)5

What about 7392.41?


Representation: (7392.41)10 or 7392.41
Any No. Sys. Decimal Any No. Sys. Decimal
Octal No. System: Base 8 A little short cut:
Only 8 digits (Taken from decimal set) : 07 Convert (110101)2 into Decimal
Convert (127.4)8 into Decimal ONLY consider powers of two with coeff. of 1

Practice Q
Convert (4021.2)8 in decimal

Binary Arithmetic
Easy
DIY
Prog. Fundamental
THANKS
JAMSHED.IQBAL@NU.EDU.PK
ROOM G-06 - EE DEPTT.