Professional Documents
Culture Documents
CS M51A/EEM51A Spring'15 Section 1 Logic Design of Digital Systems
CS M51A/EEM51A Spring'15 Section 1 Logic Design of Digital Systems
Yutao He
yutao@cs.ucla.edu
4532B Boelter Hall
https://ccle.ucla.edu/course/view/15S-COMSCIM51A-1
http://piazza.com/ucla/spring2015/csm51a/home
Outline
• Administrative Matter
• Ch 1 Recap
• Ch 2.1,2.2 - High-Level Spec. of Comb. Systems
• Ch 2.3 - Data Representation and encoding
• Summary
Specification
Fabrication
Analog
Digital
System
Comb. Sync.
Logical
Seq. Async. Circuit
Logic Design
Function
Inputs Number Systems
Outputs
Specification Boolean Algebra Implementation
K-Map
Truth Table
CAD Tools
Chapter 2 - Overview
Specification:
What It Does?
Switching Truth
K-Map VHDL
Expression Table
• Goal:
– Given a high-level specification of some forms, design a
digital system.
• Basic approach:
– Ask three questions:
• What are inputs?
• What are outputs?
• What are the relationships between inputs and outputs
• Description:
– Design a digital system that computes the distance between
two 1 s in a four-binary-digit number.
– Assume that a number contains exactly two 1 s.
A combinational system
0000 -
0001 -
0010 -
0011 0
0100 -
0101 1
0110 0
0111 -
1000 -
1001 2
1010 1
1011 -
1100 0
1101 -
1110 -
1111 -
• Description:
– A single light can be controlled by any one of three switches.
Design a digital system that controls the light as follows:
• One switch is the master on/off switch. If it is down, the light is
off.
• When the master switch is up, a change in the position of one of
other switches causes the light to change.
A sequential system
Switches Lights
DDD Off
DDU Off
DUD Off
DUU Off
UDD Off On
UDU On Off
UUD On Off
UUU Off On
Data Representation
Alphabet
Character 0, …, 9 Decimal Digit
Real World
Digital World
0, 1 Binary Bit
Number
• UniCode
– 16 Bits
– 65,536 characters
– aimed to support the interchange, processing, display texts
written in different languages
CSM51A-Sec1 S 15 L2.13 Y. He @ 4/1/14
• Question:
– Given a string of 0 s and 1 s, find the meaning it represents
• Solution:
– find its encoding scheme
– chop the string at the boundary
– look up the corresponding table
• Example:
– What does 00110110 stand for?
Number Systems
• Definition
– A writing system or a mathematical notation for representing
numbers of a given set, using a set of symbols in a
consistent manner
• Properties
– Represent a useful set of numbers (e.g. all integers, or
rational numbers)
– Give every number represented a unique representation (or
at least a standard representation)
– Reflect the algebraic and arithmetic structure of the numbers
• Place-value
– aka positional number systems
– is a method of representing or encoding numbers by using
the same symbol for the different orders of magnitude
Positional
Number Number
Systems
Radix
Positive Integer
.
Negative Fraction
Mixed. Negative
Fixed Positive
Row 1
Row 2
Row 3
Row 4
Col 1
Col 2
Col 3
Common
1 2 3
4 5 6
C
7 8 9
* 0 #
! d l o h e b sp d n a sp o l
lo and behold!
Decimal
Formula Formula
(Radix 10)
Long Long
Division Division
bit grouping
bit grouping
Binary
digit expansion (Radix 2) digit expansion
Formula
Mixed-radix Fixed-radix
Division
Next Lecture