1.2STAR LASERPRINTER 4111SOFTWARE

1.2.1Binary and hexadecimal arithmetic

If you already know what hexadecimal numbers are, you can skip this section and go ahead to read about ASCII.

The decimal number system with which we’re all familiar is a positional counting system. There’s the “ones” position, the “tens” position, the “hundreds” position and so on. Each higher position is worth ten times more than the position to the right of it, since the decimal system uses the base of ten. Moreover, we need ten symbols to show the actual values that may be in each position.

The binary system is positional too. There’s the “ones” position, the “twos” position, the “fours” position, the “eights” position and so on. In binary each position is worth only twice that of the position to its right. And we only need two symbols—O (zero) and 1(one) —to show the values that maybe in any position. So in binary we get numbers that look like 1010 or 10001100.

The hexadecimal system is made of base-sixteen numbers. Hexadecimal is positional like the other counting systems. And each higher position is worth sixteen times as much as the position to its right.

We need sixteen different symbols to show all the possible values one hexadecimal digit could have. We can use our decimal system’s ten symbols, but we’ve had to borrow a few more from our alphabet to get all the symbols we need. In hexadecimal, therefore, you can have a number that looks like 2C7C, or even FACE.

Here’show the decimal, binary and hexadecimal number systems compare:

Decimal

Binary

Hexadecimal

Decimal

Binary

Hexadecimal

o

0000

o

8

1000

x

I

0001

 

9

100I

9

2

0010

2

10

1010

A

3

0011

3

11

lo]I

B

4

O1oo

4

12

I100”

c

5

0101

5

13

IIol

D

6

0110

6

14

I110

E

7

01I1

7

15

1111

F

5

Page 13
Image 13
Star Micronics 4111 manual Binary and hexadecimal arithmetic