Hexadecimal is used to simplify notation of binary code in much the same way that we sometimes count in 5s or 10s when it is more convenient than working our way through a problem by 1s. You might ask how anyone would find it simpler to count in hex. Well, in dealing with a system that uses 8 bits, addressing counting locations in hex (a system based on eight positions) makes perfect sense.
All address buses and wires within a computer come in some multiple of 4 (8, 16, 20, 24, 32). Because there are 16 different combinations, the 16 unique characters of the base-16 numbering system are a natural choice for computer shorthand when referring to memory locations or a bus address. The following table contrasts binary notation with hex shorthand.
|Binary Number||Hex Shorthand||Binary Number||Hex Shorthand|
There is no need to say:
To use hex shorthand:
- Break the 20 digits into 5 sets:
1011 0110 0110 0010 1101
- Give each 4-character set its hex shorthand:
1011 0110 0110 0010 1101 B 6 6 2 D
Hex shorthand = B662D
To represent all the possible addresses for the 20-bit address bus, we use 5 hex values (0 to F) that map to their binary equivalents, from all 0s:
0000 0000 0000 0000 0000 0 0 0 0 0
to all 1s.
1111 1111 1111 1111 1111 F F F F F
Each of the possible memory locations for the Intel 8088 can be represented by 5-digit hexadecimal values, starting at 00000 and ending at FFFFF.