Monday, February 26 - ASCII and UNICODE (page 141) - quick conversion: binary <==> octal <==> hexadecimal dec. bin. hex. ----------------- 0 0000 0 1 0001 1 2 0010 2 3 0011 3 4 0100 4 5 0101 5 6 0110 6 7 0111 7 8 1000 8 9 1001 9 10 1010 A 11 1011 B 12 1100 C 13 1101 D 14 1110 E 15 1111 F convert 742 decimal to binary, hex, and octal 742 = 1011100110 binary (repeated division algorithm) = 10 1110 0110 (group into 4's) = 2E6 hex (using table above) = 1 011 100 110 (regroup into 3's) = 1346 octal (using table) convert 2BAD hex to binary and octal 2BAD = 10101110101101 binary (using table) = 10 101 110 101 101 (group into 3's) = 35656 octal (using table) convert A70F hex to binary and octal A70F = 1010 0111 0000 1111 binary (using table) = 1 010 011 100 001 111 (regroup into 3's) = 123417 octal (using table) convert 765 octal to binary and hex 765 = 111 110 101 binary (using table) = 1 1111 0101 (regroup into 4's) = 1F5 hex (using table) ------------------------------------------------------------ draw circuits for the following expressions: NOT ((NOT a) OR (NOT b)) (a OR b) AND ((NOT c) OR (NOT d)) ------------------------------------------------------------ circuit construction algorithm: - XOR truth table - Output-2 column of truth table on page 166 - 1-bit addition circuit: sum and carryOut ------------------------------------------------------------ constructing a 4-bit addition circuit from 4 full-adders truth table for full-adder (FA) circuit: Cin In1 In2 Sum Cout 0 0 0 0 0 0 0 1 1 0 0 1 0 1 0 0 1 1 0 1 1 0 0 1 0 1 0 1 0 1 1 1 0 0 1 1 1 1 1 1 a3 a2 a3 a0 + b3 b2 b1 b0 ------------- C s3 s2 s1 s0 (C is final carry-out) +----------+ 0 --|Cin Sum|------- s0 (least significant bit) | FA | a0 -------|In1 | b0 -------|In2 Cout|---+ +----------+ | | +------------------+ | | +----------+ +---|Cin Sum|------- s1 | FA | a1 -------|In1 | b1 -------|In2 Cout|---+ +----------+ | | +------------------+ | | +----------+ +---|Cin Sum|------- s2 | FA | a2 -------|In1 | b2 -------|In2 Cout|---+ +----------+ | | +------------------+ | | +----------+ +---|Cin Sum|------- s3 | FA | a3 -------|In1 | b3 -------|In2 Cout|------- carry-out +----------+