Digital Electronics and Computer Interfacing - PowerPoint PPT Presentation

1 / 15
About This Presentation
Title:

Digital Electronics and Computer Interfacing

Description:

Digital Electronics and Computer Interfacing Tim Mewes 3. Digital Electronics Digital Electronics and Computer Interfacing * 3.1 Digital Information Information is ... – PowerPoint PPT presentation

Number of Views:77
Avg rating:3.0/5.0
Slides: 16
Provided by: TimM58
Category:

less

Transcript and Presenter's Notes

Title: Digital Electronics and Computer Interfacing


1
Digital Electronics and Computer Interfacing
  • Tim Mewes
  • 3. Digital Electronics

2
3.1 Digital Information
  • Information is stored in two distinct physical
    states
  • Charge state of a capacitor (DRAM)
  • Magnetization direction (Hard disk, MRAM)
  • The two states are referred to as
  • TRUE/FALSE (Boolean)
  • 1/0
  • On/Off
  • High/Low

3
3.1 Digital Information
  • Information can be transmitted using
  • discrete Voltage levels
  • TTL 1 2.0 V or greater 0 0.8 V or less
  • CMOS 1 3.7 V or greater 0 1.3 V or less
  • Light
  • typical wavelengths 850, 1310, or 1550 nm
  • Radio frequencies
  • Bluetooth 2.4GHz

4
3.2 Digital number representation
  • 3.2.1 Unsigned integers
  • use base 2 (binary) representation
  • 167101?270?261?250?240?231?221?211?20
    1010 01112
  • Each digit in the binary representation is called
    a bit
  • Eight bits are called a byte
  • The largest possible number that can be
    represented by n-bits is 2n-1 (255 in case of a
    byte)
  • The leftmost bit is also called most significant
    bit
  • The rightmost bit is also called least
    significant bit

5
3.2.1 Unsigned integers
  • How to convert from base 2 to base 10?
  • Example 11001001, n8 bits
  • Most significant bit 1?2n-11?27128 ? 128
  • 1?2n-21?2664 ? 64
  • 0?2n-30?250 ? 0
  • 0?2n-40?240 ? 0
  • 1?2n-51?238 ? 8
  • 0?2n-60?220 ? 0
  • 0?2n-70?210 ? 0
  • 1?2n-81?201 ? 1

Sum 201
6
3.2.1 Unsigned integers
  • How to convert from base 10 to base 2?
  • Example 100 with n8 bits
  • Most significant bit 2n-127128 gt 100 ? 0
  • 2n-22664 lt 100 ? 1
  • 100-64 36 2n-32532 lt 36 ? 1
  • 36-32 4 2n-42416 gt 4 ? 0
  • 2n-5238 gt 4 ? 0
  • 2n-6224 4 ? 1
  • 4-4 0 2n-7212 gt 0 ? 0
  • 2n-8201 gt 0 ? 0

10010011001002
7
3.2.2 Signed integers
  • Sign-and-magnitude
  • Use the most significant bit to represent the
    sign
  • 0 represents , 1 represents -
  • For n-bits numbers from -2n-11 to 2n-1-1 can be
    represented
  • Advantage similar to the way we usually indicate
    the sign of a number
  • Disadvantage arithmetic calculations tricky
  • Zero has two representations -0101000 00002
  • 0100000 00002

8
3.2.2 Signed integers
  • Ones complement
  • Negative numbers are represented by complementing
    all the bits (1 ? 0) of the binary representation
    of the magnitude of the number
  • 4210 0010 10102-4210 1101 01012
  • Zero still has two representations

9
3.2.2 Signed integers
  • Twos complement
  • For negative numbers calculate the ones
    complement and add 1 to the result
  • 4210 0010 10102Ones complement
    -4210 1101 01012
  • Twos complement -4210 1101 01102
  • Zero has only one representation
  • Range for n bits -2n-1 to 2n-1-1 (-128 to 127
    for a byte)
  • Advantage convenient for computer arithmetic

10
3.2.3 Comparison (4-Bit)
Base 10 Unsigned Integer Sign-and-magnitude Ones complement Twos comlement
8 1000 - - -
7 0111 0111 0111 0111
6 0110 0110 0110 0110
5 0101 0101 0101 0101
4 0100 0100 0100 0100
3 0011 0011 0011 0011
2 0010 0010 0010 0010
1 0001 0001 0001 0001
0 0000 0000 0000 0000
-0 - 1000 1111 -
-1 - 1001 1110 1111
-2 - 1010 1101 1110
-3 - 1011 1100 1101
-4 - 1100 1011 1100
-5 - 1101 1010 1011
-6 - 1110 1001 1010
-7 - 1111 1000 1001
-8 - - - 1000
11
3.3 Gates
  • A logic gate is an arrangement of switches to
    calculate operations using Boolean logic in
    digital circuits
  • The output of a gate only depends on its inputs
    and not its history

12
3.3 Gates
A
Q
A
Q
B
A
Q
B
13
3.3 Gates
A
Q
B
A
Q
B
A
Q
B
14
3.4 Boolean algebra
  • associativity
  • commutativity
  • absorption
  • complements
  • distributivity
  • De Morgans theorem

15
3.4 Boolean algebra
  • How many gates do we really need?

Just one either NAND or NOR (universal gates)!
One can build all other gates using for example
only NAND
NOT
AND
OR
XOR
Write a Comment
User Comments (0)
About PowerShow.com