2. Objectives
• Analog vs. digital representation: definition an
d comparison
• Analog-to-Digital and Digital-to-Analog conver
ters
• Decimal and binary numbers
• Timing diagram
• Parallel vs serial transmissions
3. Numerical Representations
• Analog representation: a quantity that can var
y over a continuous range of values.
• Digital representation: a quantity that changes
in discrete steps.
• Analog == Continuous
• Digital == discrete (step by step)
4. Example
• Which of the following involves analog quant
ities and which involve digital quantities?
(a) Ten-position switch
(b) Current flowing out of an electrical outlet
(c) Temperature of a room
(d) Sand grains on the beach
(e) Automobile speedometer
5. Digital Revolution
• Digital systems started back in 1940s.
• Digital systems cover all areas of life:
– still pictures
– digital video
– digital audio
– telephone
– traffic lights
– Animation
6. Digital Systems
• A digital system is a combination of devices de
signed to manipulate logical information or ph
ysical quantities that are represented in digital
form.
• Examples: digital computers, calculators, digit
al audio/video equipment, telephone syste
m…
7. Analog versus Digital
• Analog systems process time-varying signals th
at can take on any value across a continuous r
ange of voltages (in electrical/electronics syste
ms).
• Digital systems process time-varying signals th
at can take on only one of two discrete values
of voltages (in electrical/electronics systems).
– Discrete values are called 1 and 0 (ON and OFF, HI
GH and LOW, TRUE and FALSE, etc.)
8. Advantages of Digital Techniques
• Digital systems are generally easier to design.
• Information storage is easy.
• Accuracy and precision are greater.
• Operation can be programmed.
• Digital circuits are less effected by noise.
• More digital circuitry can be fabricated on IC c
hips.
9. Cont’
• Reproducibility
• Not effected by noise means quality
• Ease of designs
• Data protection
• Programmable
• Speed
10. Digital Electronics
• Digital Electronics represents information (0, 1) w
ith only two discrete values.
• Ideally
“no voltage” (e.g., 0v) represents a 0 and
“full source voltage” (e.g., 5v) represents a 1
• Realistically
“low voltage” (e.g., <1v) represents a 0 and
“high voltage” (e.g., >4v) represents a 1
11. • We achieve these discrete values by using swit
ches.
• We use transistor switches, which operates at
high speed, electronically, a small in size
12. Limitations of Digital Techniques
• The real world in mainly analog.
• To deal with analog inputs, three steps must b
e followed:
– Convert the real-world analog inputs to digital for
m
(analog-to-digital converter, ADC)
– Process (operate on) the digital information
– Convert the digital output back to real-world anal
og form (digital-to-analog converter,DAC)
13. Compact Disks
• Sounds from instrument and human voices produce an analog
voltage signal in a microphone
• This analog signal is converted to digital form
• The digital information is stored on the CD’s surface
• During playback, the CD player takes the digital information fr
om the CD surface and converts it into an analog signal which
is then amplified and fed to a speaker.
14. Digital vs. Analog
• Added complexity and expense due to ADC, DAC
• Extra time required to perform conversions
• In most applications, digital techniques are favored because of
the advantages discussed before.
• One notable exception: signal amplification is most easily achi
eved using analog circuitry.
• Hybrid systems: combination of digital and analog parts.
• The future is digital.
16. Decimal System
• Decimal system is composed of 10 numerals o
r symbols.
• Also called the base-10 system because it has
10 digits.
• The decimal system is a positional-value syste
m in which the value of a digit depends on its
position.
• Most significant digit (MSD)
• Least significant digit (LSD)
17. Binary System
• Also known as base-2 system
• Use two digit values, 0 and 1.
• Decimal system decimal point,
Binary system binary point
• Example: 1011.1012
• Most Significant Bit, Least Significant Bit
18. Representing Binary Quantities
• In digital systems the information that is being proce
ssed is usually presented in binary form. Binary quan
tities can be represented by any device that has only
two operating states or possible conditions.
• For example, a switch has only open or closed. We ar
bitrarily (as we define them) let an open switch repre
sent binary 0 and a closed switch represent binary 1.
• Thus we can represent any binary number by using s
eries of switches.
19. Example of Typical Voltage
• Binary 1: Any voltage between 2V to 5V
• Binary 0: Any voltage between 0V to 0.8V
• Not used: Voltage between 0.8V to 2V, this may cause error in
a digital circuit.
20. Timing Diagram
• Indicates how a signal varies over time.
• Use to show the relationship between two or
more digital signals in the same circuit or syste
m.
21. Digital Circuits
• Digital circuits are designed to produce output voltag
es that fall within the prescribed 0 and 1 voltage rang
es.
• A digital circuit responds to an input’s binary level (0
or 1) and not to its actual voltage.
• The manner in which a digital circuit responds to an i
nput is referred to as the circuit’s logic.
• Each type of digital circuit obeys a certain set of logic
rules.
• For this reason, digital circuits are also called logic ci
rcuits.
22. Parallel and Serial Transmission
• Parallel Transmission
• Serial Transmission:
Circuit
A
Circuit
B
A B
24. Objectives
24
Understand why computers use binary (Base-2) numb
ering.
Understand how to convert Base-2 numbers to Base-1
0 or Base-8.
Understand how to convert Base-8 numbers to Base-1
0 or Base 2.
Understand how to convert Base-16 numbers to Base-
10, Base 2 or Base-8.
25. 25
Converting Base-2 to Base-10
(1 0 1 1)
2
0
ON
OFF
ON
OFF
ON
Exponent:
Calculation: 0 0 2 1
16+ + + + =
(19)10
26. • Number systems include decimal, binary, octa
l and hexadecimal
• Each system have four number base
26
Number System Base Symbol
Binary Base 2 B
Octal Base 8 O
Decimal Base 10 D
Hexadecimal Base 16 H
27. 1.1 Decimal Number System
• The Decimal Number System uses base 10. It i
ncludes the digits {0, 1,2,…, 9}. The weighted
values for each position are:
10^4 10^3 10^2 10^1 10^0 10^-1 10^-2 10^-3
10000 1000 100 10 1 0.1 0.01 0.001
27
Base
Right of decimal point
left of the decimal point
28. • Each digit appearing to the left of the decimal poin
t represents a value between zero and nine times po
wer of ten represented by its position in the numbe
r.
• Digits appearing to the right of the decimal point repr
esent a value between zero and nine times an incre
asing negative power of ten.
• Example: the value 725.194 is represented in expan
sion form as follows:
• 7 * 10^2 + 2 * 10^1 + 5 * 10^0 + 1 * 10^-1 + 9 * 10
^-2 + 4 * 10^-3
• =7 * 100 + 2 * 10 + 5 * 1 + 1 * 0.1 + 9 * 0.01 + 4 * 0
.001
• =700 + 20 + 5 + 0.1 + 0.09 + 0.004
• =725.194
28
29. 1.2 The Binary Number Base Systems
• Most modern computer system using binary logic. The co
mputer represents values(0,1) using two voltage levels (us
ually 0V for logic 0 and either +3.3 V or +5V for logic 1).
• The Binary Number System uses base 2 includes only the
digits 0 and 1
• The weighted values for each position are :
2^5 2^4 2^3 2^2 2^1 2^0 2^-1 2^-2
32 16 8 4 2 1 0.5 0.25
29
Base
30. 1.3 Number Base Conversion
• Binary to Decimal: multiply each digit by its weighte
d position, and add each of the weighted values toget
her or use expansion formdirectly.
• Example the binary value 1100 1010 represents :
• 1*2^7 + 1*2^6 + 0*2^5 + 0*2^4 + 1*2^3 + 0*2^2 + 1
*2^1 + 0*2^0 =
• 1 * 128 + 1 * 64 + 0 * 32 + 0 * 16 + 1 * 8 + 0 * 4 + 1 *
2 + 0 * 1 =
• 128 + 64 + 0 + 0 + 8 + 0 + 2 + 0 =202
30
31. • Decimal to Binary
There are two methods, that may be used to convert fro
m integer number in decimal form to binaryform:
1-Repeated Division By 2
• For this method, divide the decimal number by 2,
• If the remainder is 0, on the right side write down a 0.
• If the remainder is 1, write down a 1.
• When performing the division, the remainders which
will represent the binary equivalent of the decimal nu
mber are written beginning at the least significant digi
t (right) and each new digit is written to more signific
ant digit (the left) of the previous digit.
31
33. Octal System
33
Computer scientists are often looking for shor
tcuts to do things
One of the ways in which we can represent bi
nary numbers is to use their octal equivalents
instead
This is especially helpful when we have to do f
airly complicated tasks using numbers
34. • The octal numbering system includes eig
ht base digits (0-7)
• After 7, the next placeholder to the right
begins with a “1”
• 0, 1, 2, 3, 4, 5, 6, 7, 10, 11, 12, 13 ...
34
37. Signed Numbers
• Digital system must able both positive and negative n
umber
• Signed number consist both sign and magnitude info
rmation
• Sign indicates whether a number s positive or negativ
e
• Magnitude is value of the number
38. • There are forms in which signed integer numb
er represented in binary
Sign magnitude
1’s complement
2’ s complement