Docsity

Introduction to Digital Logic and Digital Systems, Study notes of Electrical and Electronics Engineering

Toggle sidebar
bg1
1
ECE 274 - Digital Logic
Lecture 1
Lecture 1
What is digital logic?
Digital Hardware
Implementing a Digital System
Moore’s Law
Design Process of Digital Hardware
2
What is Digital Logic?
Digital vs. Analog
Digital signal
Discrete
Signal that can have one of a finite set
of possible values
Analog signal
Continuous
Signal that can have one of an infinite
number of possible values
Counting fingers
Fingers = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}
Temperature
Infinite possibilities
3
What is Digital Logic?
What is a “Digital System”?
Digital system
System that takes in digital inputs and generates
digital outputs
Example: Computer
Digital inputs (letters and numbers from keyboard)
Digital output (new numbers or letters stored to a
file or display on screen)
Many other digital systems exist
Cell phones, automobile control engines, TV set top
boxes, musical instruments, DVD players, digital
cameras, finger print recognition, …
pf3
pf4
pf5
pf8
pf9
pfa

Partial preview of the text

Download Introduction to Digital Logic and Digital Systems and more Study notes Electrical and Electronics Engineering in PDF only on Docsity!

ECE 274 - Digital Logic

Lecture 1

„ Lecture 1

„ What is digital logic?

„ Digital Hardware

„ Implementing a Digital System

„ Moore’s Law

„ Design Process of Digital Hardware

What is Digital Logic?

Digital vs. Analog

„ Digital signal

„ Discrete

„ Signal that can have one of a finite set of possible values

„ Analog signal

„ Continuous

„ Signal that can have one of an infinite number of possible values

Counting fingers Fingers = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}

Temperature Infinite possibilities

What is Digital Logic?

What is a “Digital System”?

„ Digital system

„ System that takes in digital inputs and generates digital outputs

„ Example: Computer

„ Digital inputs (letters and numbers from keyboard)

„ Digital output (new numbers or letters stored to a

file or display on screen)

„ Many other digital systems exist

„ Cell phones, automobile control engines, TV set top

boxes, musical instruments, DVD players, digital

cameras, finger print recognition, …

What is Digital Logic?

Digital Circuits and Binary

„ Digital circuits

„ Connection of digital components that together compose the digital systems

„ Digital signal with only two possible values --

Binary

„ Typically represented as 0 and 1

„ One binary digit is a - bit

„ We’ll only consider binary digital signals

Digital components

Digital circuit

Digital system

What is Digital Logic?

Digitization

„ World is mostly analog

„ Many digital systems convert analog signals to digital signals

„ Many applications changing over to digital implementations (cassette tapes -> MP3s, VHS -> DVD, …)

More and more analog products are becoming digital.

Portable

Satellites

Cell phones

DVD Video

Cameras TVs

music players

players recorders

Musical

instruments

What is Digital Logic?

How Do We Encode Data as Binary for Our Digital System

„ Some inputs inherently binary

„ Button: not pressed (0), pressed (1)

button

What is Digital Logic?

Encoding Text: ASCII, Unicode

„ ASCII: 7- (or 8-) bit encoding of each letter, number, or symbol

„ Unicode: Increasingly popular 16-bit bit encoding

„ Encodes characters from various world languages

R

S

T

L

N

E

Symbol Encoding 1110010 1110011 1110100 1101100 1101110 1100101 0111001 0100001 0100000

r s t l n e 9

Symbol Encoding

Question: What does this ASCII bit sequence represent? 1010010 1000101 1010011 1010100

R E S T

What is Digital Logic?

How to Encode Numbers: Binary Numbers

„ Each position represents a quantity; symbol in position

means how many of that quantity

„ Base ten ( decimal )

„ Ten symbols: 0, 1, 2, ..., 8, and 9

„ More than 9 -- next position

„ So each position power of 10

„ Base two ( binary )

„ Two symbols: 0 and 1

„ More than 1 -- next position

„ So each position power of 2

„ Other number representations also exists

„ Octal, Hexadecimal

„ We’ll cover this in Chapter 5

What is Digital Logic?

Digitization Benefits

„ Analog signal (e.g., audio) may lose quality

„ Voltage levels not

saved/copied/transmitted

perfectly

„ Digitized version enables near-

perfect save/cpy/trn.

„ “Sample” voltage at particular

rate, save sample using bit

encoding

„ Voltage levels still not kept

perfectly

„ But we can distinguish 0s from

1s

time

Volts 0

original signal

lengthy transmission (e.g, cell phone)

(^0) time

received signal

How fix -- higher, lower,?

time

Volts

digitized signal 0

01 10 11 10 11

a2d

Let bit encoding be: 1 V: “01” 2 V: “10” 3 V: “11”

time

Can fix -- easily distinguish 0s and 1s, restore

time

Digitized signal not perfect re-creation, but higher sampling rate and more bits per encoding brings closer.

Volts 0

d2a

01 10 11 10 11

What is Digital Logic?

Digitization Benefits

„ Digitized audio can be

compressed

„ e.g., MP3s

„ CD can hold about 20 songs

uncompressed, but about 200

compressed

„ Compression also done on

digitized pictures (jpeg),

movies (mpeg), and more

„ Digitization has many other

benefits too

Example compression scheme: 00 --> 0000000000 01 --> 1111111111 1X --> X

Assortment of 7400-

series ICs

Digital Hardware

Standard Chips

„ How do we implement these systems? (Digital Hardware)

„ Standard Chips

„ Commonly used circuits

„ Small amount of circuitry

„ Performs simple function

„ ICs interconnected to realize larger functionality

74273 D-Type Flip-Flop with Reset

7493 4-Bit Binary Ripple Counter

7485 4-Bit Magnitude Comparator

7447 BCD to 7-Segment Decoder/Driver

7432 Quad 2-Input OR Gate

7402 Quad 2-Input NOR Gate

7400 Quad 2-Input NAND Gate

Part Number Description

Digital Hardware

Programmable Logic Devices (PLDs)

„ Programmable Logic Devices

„ Very general underlying structure that

can be configured to perform a variety

of tasks

„ Most can be programmed multiple

times

„ Programmed by the end user rather

than when manufactured

„ Common type of PLD -- FPGAs

„ Field-Programmable Gate Array

„ Work with these in the lab

Spartan 3 Die

Photo

Spartan 3 FPGA

Board

Desired motion-at-night detector

Programmed

microprocessor

Custom designed

digital circuit

„ Build a system to detect motion at night

„ Build system using microprocessor

„ Build system using a custom digital circuit

Implementing a Digital System

Programming Microprocessors vs. Designing Digital Circuits

a f

b

motion sensor

lamp

microprocessor

light sensor

Implementing a Digital System

Microprocessor: Software Implementation

void main()

while(1)

f = a && !b;

Circuit Description: using a microprocessor

Inputs: 2 sensors (one light, one motion)

Outputs: 1 signal to lamp

Functional Description:

Lamp illuminated when it is dark

and motion is detected.

f

a

b

motion sensor

lamp

custom circuit

light sensor

Implementing a Digital System

Custom Circuit: Hardware Implementation

Circuit Description: digital design

Inputs: 2 sensors (one light, one motion)

Outputs: 1 signal to lamp

Functional Description:

Lamp illuminated when it is dark

and motion is detected.

Implementing a Digital System

Microprocessors: Trouble in Paradise

„ With microprocessors so readily available, why would anyone ever need

to design new digital circuits?

When analyzing needs for a particular system:

„ Software may be too slow

„ May be too much circuitry than needed

„ Can be costly for simple circuits

„ Power hungry

Implementing a Digital System

Process Analysis: Microprocessor vs. Digital Circuit

Sample digital camera task execution times (in seconds) on a microprocessor versus a digital circuit.

Store 1 0.

Compress 8 0.

Read 5 0.

Digital Camera Task Microprocessor Custom digital circuit

Implementing a Digital System

Partitioning: Possible Digital Camera Implementations

Digital camera implemented with: (a) a microprocessor

(b) custom circuits

(c) a combination of custom circuits and a microprocessor

„ Design Partitioning

„ Deciding which tasks to

implement on the

microprocessor and which

to implement as a custom

digital circuit

To perform function X, we require this much area 18 months later, this much area 18 months later, this much area

Moore’s Law

Example

18 months later, this much area

18 months later, this much area

18 months later, this much area

18 months later, this much area

18 months later, this much area

18 months later, this much area

18 months later, this much area

18 months later, this much area

18 months later, this much area

18 months later, this much area

This trend observed in 1970’s

continues today. Expected to

continue for several more decades

Digital Design

Shrinking area requirement

~20 years

One view point -- same

functionality requires less area

„ Cray 1A Supercomputer

„ Fastest computer in the world in 1976

„ Cost - $10 million dollars (1976 $s)

„ Used for atmospheric research, physical

simulations, etc.

„ ~1 million transistors

„ Today - approaching 1 billion transistors

per square centimeter (65 nm)

„ 1 million transistors (Cray 1): 0.1 mm^2

„ Cost - $1’s

Cray 1A

1 million transistors (Cray 1) Modern chip – 1 billion transistors

1 cm

1 cm

Moore’s Law

Supercomputer in a pencil tip

Moore’s Law

Enabling advances in technology

„ Smart Dust

„ Millimeter scale „ Includes sensors, microprocessors, wireless communication, power supply „ Costs dollars, even just cents, each

„ Smart Pills

„ Electronically tracked and instructed to deliver medicine to specific location „ “Swallowing the pill and the instrument”

„ iPills – micropump, sensors, and medicine

„ Pump controls amount of medicine based on body temperature and pH

„ Other uses of tiny computers in 10 years?

http://www.templehealth.org/capsule/a pril_22_05/april2205_news03.htm

Courtesy of Joe Kahn

Image: "Smart dust" particles self-assembled on drops of oil in water. The microscopic particles are nanostructured flakes of porous silicon that spontaneously assemble, orient, sense, and report on their local environment. UCSD, 2003.

Moore’s Law

Same size, more functionality

~20 years

Another view point -- same

area more functionality

~ 4000x more

„ Available today „ Pentium 4 Extreme Edition ( million) „ Xilinx FPGA (1 billion) „ Geforce 6800 Ultra (222 million)

Moore’s Law

Lots of transistors – need help

„ Available today

„ Pentium 4 Extreme Edition (178 million) „ Xilinx FPGA (1 billion) „ Geforce 6800 Ultra (222 million)

„ Need CAD (Computer-Aided Design) Tools to

help developers