Assignment 2
Assignment 2
10. Which of the following is the most widely used code for computer input and
output?
A) parity B) Gray C) EBCDIC D) ASCII
13. Which of the following is based on the division of two binary numbers?
A) The cyclic redundancy check (CRC) B) Gray code to decimal
conversion C) Hamming code conversion D) ASCII decoding
b) Compute the sum x + y by hand in binary. Both inputs and the result
should be interpreted in 8-bit, two’s complement signed number
representation. Check your result in decimal. Is there an overflow?
Explain how you know
3. [6] Convert decimal 6,514 to both BCD and ASCII codes. For ASCII, an
even parity bit is to be appended at the left.
4. [4] Represent the unsigned decimal numbers 791 and 658 in BCD, and
then show the steps necessary to form their sum.
5. [6] Represent the decimal number 6,248 in (a) BCD, (b) excess‐3 code,
(c) 2421 code
8. [6] The following is a string of ASCII characters whose bit patterns have
been converted into hexadecimal for compactness: 73 F4 E5 76 E5 4A
EF 62 73. Of the eight bits in each pair of digits, the leftmost is a parity
bit. The remaining bits are the ASCII code.
(a) [4] Convert the string to bit form and decode the ASCII.
(b) [2] Determine the parity used: odd or even?
9. [2] What bit must be complemented to change an ASCII letter from capital
to lowercase and vice versa?
10. [12] The state of a 12-bit register is 100010010111. What is its content if
it represents
(a) Three decimal digits in BCD?
(b) Three decimal digits in the excess-3 code?
(c) Three decimal digits in the 8421 code?
(d) A binary number?
11. [8] Apply CRC to the data bits 10110010 using the generator code 1010
to produce the transmitted CRC code.
12. [6] By means of a timing diagram, show the signals of the outputs f and g
in following Figure as functions of the three inputs a, b, and c. Use all
eight possible combinations of a, b, and c.
13. [6] By means of a timing diagram, show the signals of the outputs f and g
in following Figure as functions of the two inputs a and b. Use all four
possible combinations of a and b.
Good Luck