DIGITAL & ANALOGUE SYSTEMS

advertisement
DIGITAL & ANALOGUE SYSTEMS
Electronic signals, data and information are generally placed into two categories:digital and
analog.Digital information is represented in discrete increments, ON ( +5V) and OFF( 0V).
.
Analogue is continuous information ( Infinite states)
A sine wave is an example of an analogue signal
Digital signals normally consist of 2 simple states, they are : more accurate, less likely to degrade
over time, easier to process, reproduce and store.
Number systems
The Denary system has 10 states 0 to 9
Binary numbers are used to represent digital information because there are two possible states.
( 0 and 1, say 0V for OFF & 5V for ON).
The Octal system has 8 states 0 to 7. The Hexadecimal system has 16 states 0 to F (15)
DENARY
x105
x104
x103
x102
x101
x100
4
4
2
8
3
3
BINARY
x25
x24
x23
x22
x21
x20
1
1
0
0
1
1
OCTAL
HEXADECIMAL
x82
x81
x80
X162
X161
X160
3
5
7
2
A (10)
E (14)
Denary number is 44283310. The Binary number is 1100112 the denary equivalent is 51 (32
+16+ 0 + 0+ 2 + 1). The Octal number is 3578, The denary equivalent is 239. The Hex number is
2AEH or 2AE16. The denary equivalent is 686
Ex 1 Convert binary to denary: 101110, 10111, 1001.11101.
When converting denary numbers to binary, the denary number is repeatedly divided by 2.
Each remainder must be retained and eventually becomes the binary equivalent.
The first remainder is the least significant digit and the last remainder is the most significant digit.
Ex 2 Convert the decimal numbers 133, 252, 79.5, 1336, 97.875, 11.625 to binary
For the binary numbering system to represent larger numbers many bits are required. eg the
number 20010 is 110010002.To represent binary numbers in a more concise form a higher base is
needed, Eg base 4, 8,16, 32… currently, designers are working on the introductions of 64 bit
code
Ex 3 Convert the denary numbers 232, 168.5, 365.25 to numbers of base 2, 4,and 8. Start with
base 2 and group digits in pairs ( base 4) or 3’s (base 8).
Hexadecimal
Hexadecimal or base 16 can be used to represent 4 binary digits.
The hexadecimal range is 0 1 2 3 4 5 6 7 8 9 A B C D E F ie 0 – 15 in denary
Ex Convert the binary number 11011111 to denary then hexadecimal.
Denary . 1+2+4+8+16+0+64+128 = 223
Hexadecimal: Break the binary number into groups of four : 1101 1111
Convert each group of 4 bits to hexadecimal : D FH or D F16
OR divide 16 into the denary number.
Ex 4 Convert the denary numbers 2364, 1865,4, 411.625, to hexadecimal
Ex 5 Determine the decimal equivalent for Hex numbers ABE. 8, 21E.C
Rules of Binary Addition
Binary Addition




0+0=0
0+1=1
1+0=1
1 + 1 = 0, and carry 1 to the next more significant bit
00011010 + 00001100 = 00100110
1 1
carries
0 0 0 1 1 0 1 0 = 26(base 10)
+ 0 0 0 0 1 1 0 0 = 12(base 10)
0 0 1 0 0 1 1 0
= 38(base 10)
Binary Subtraction




0-0=0
0 - 1 = 1, and borrow 1 from the next more significant bit
1-0=1
1-1=0
00100101 - 00010001 = 00010100
0
borrows
1
0 0 1 0 0 1 0 1 = 37(base 10)
- 0 0 0 1 0 0 0 1 = 17(base 10)
0 0 0 1 0 1 0 0
= 20(base 10)
Binary Multiplication




0x0=0
0x1=0
1x0=0
1 x 1 = 1, and no carry or borrow bits
00101001 × 00000110 = 11110110
0 0 1 0 1 0 0 1 =
×0 0 0 0 0 1 1 0 =
41(base 10)
6(base 10)
0 0 0 0 0 0 0 0
0 0 1 0 1 0 0 1
0 0 1 0 1 0 0 1
0 0 1 1 1 1 0 1 1 0 = 246(base 10
Binary Division substitute 0100 ÷ 0010 by 0100 x 0.1000.
Download