0% found this document useful (0 votes)
386 views

Tutorial 1 - Digital Number Systems - QUESTION

This document discusses digital number systems including binary, decimal, and hexadecimal. It provides examples of converting between these number systems. Additionally, it covers topics such as binary complement, ASCII encoding, binary coded decimal, parity bits, memory addresses in hexadecimal, and representing levels of gray in digital images.

Uploaded by

Hamdi Ramlee
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
386 views

Tutorial 1 - Digital Number Systems - QUESTION

This document discusses digital number systems including binary, decimal, and hexadecimal. It provides examples of converting between these number systems. Additionally, it covers topics such as binary complement, ASCII encoding, binary coded decimal, parity bits, memory addresses in hexadecimal, and representing levels of gray in digital images.

Uploaded by

Hamdi Ramlee
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

BEEC 2404 Digital Electronics

TUTORIAL 1: Digital Numbers System


Binary, Decimals, Hexadecimal

1. Convert the following binary numbers into decimal and hexadecimal:


(a) 1100000 (b) 11111101 (c) 11110010

2. Convert each decimal number to binary by using the sum-of-weights method:


(a) 12 (b) 15 (c) 25

3. Convert each decimal number to binary using repeated division by 2:


(a) 97 (b) 127 (c) 198

4. Convert each hexadecimal number to decimal number:


(a) 1A6 (b) 55 (c) 2C0

5. What is the maximum decimal number that can be represented by an 8-bit binary
number?

6. Express the decimal number 568.23 as a sum of the values of each digit.

Compliments of Binary Numbers


1. Express each decimal number in binary as an 8-bit sign-magnitude number:
(a) +29 (b) -85 (c) +100 (d) -123

2. Express each decimal number as an 8-bit number in the 2’s complement form:
(a) +12 (b) -68 (c) +101 (d) -125
Digital Codes
1. Decode the following ASCII coded message:
1001000 1100101 1101100 1101100 1101111 0101110
1001000 1000101 1001100 1010000

2. Convert 0110100000111001 (BCD) to decimal number.

Error Codes
1. Attach the proper even parity bit to each of the following bytes of data:
(a) 10100100 (b) 00001001 (c) 11111110
2. Determine which of the following even parity codes are in error:
(a) 100110010 (b) 011101010 (c) 10111111010001010
3. Determine which of the following odd parity codes are in error:
(a) 11110110 (b) 00110001 (c) 01010101010101010

Applications
1. In a computer, the addresses of memory locations are binary numbers that identify each
memory circuit where a byte is stored. The number of bits that make up an address
depends on how many memory locations there are. Since the number of bits can be very
large, the addresses are often specified in hex instead of binary.
(a) If a computer uses a 20-bit of address, how many different memory locations are
there?
(b) How many HEX digits are needed to represent the address of a memory location?
(c) What is the HEX address of the 256th memory location? (Note: The first address is
always 0.)
2. A black-and-white digital camera lays a fine grid over an image and then measures and
records a binary number representing the level of gray it sees in each cell of the grid. For
example, if four-bit numbers are used, the value of black is set to 0000 and the value of
white to 1111, and any level of gray is somewhere between 0000 and 1111. If six-bit
numbers are used, black is 000000, white is 111111, and all grays are between the two.
Suppose we wanted to distinguish among 254 different levels of gray within each cell of
the grid. How many bits would we need to use to represent these levels?

You might also like