Lantronix UDS-10 UDS-10 / UDS100 - User Guide - Page 59

Binary to Hexadecimal Conversions, Converting Binary to Hexadecimal, Conversion Table

Page 59 highlights

B: Binary to Hexadecimal Conversions Many of the unit's configuration procedures require you to assemble a series of options (represented as bits) into a complete command (represented as a byte). The resulting binary value must be converted to a hexadecimal representation. Use this chapter to learn how to convert binary values to hexadecimals or to look up values in the tables of configuration options in hexadecimal notation. The tables include: ‹ Connect Mode Options ‹ Disconnect Mode Options ‹ Flush Mode (Buffer Flushing) Options ‹ Interface Mode Options ‹ Pack Control Options Converting Binary to Hexadecimal Following are two simple ways to convert binary numbers to hexadecimals. Conversion Table Hexadecimal digits have values ranging from 0 to F, which are represented as 0-9, A (for 10), B (for 11), etc. To convert a binary value (for example, 0100 1100) to a hexadecimal representation, the upper and lower four bits are treated separately, resulting in a two-digit hexadecimal number (in this case, 4C). Use the following table to convert values from binary to hexadecimal. Decimal 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Binary 0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010 1011 1100 1101 1110 1111 Hex 0 1 2 3 4 5 6 7 8 9 A B C D E F 59

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78

59
B: Binary to Hexadecimal Conversions
Many of the unit’s configuration procedures require you to assemble a series of
options (represented as bits) into a complete command (represented as a byte). The
resulting binary value must be converted to a hexadecimal representation.
Use this chapter to learn how to convert binary values to hexadecimals or to look up
values in the tables of configuration options in hexadecimal notation. The tables
include:
Connect Mode Options
Disconnect Mode Options
Flush Mode (Buffer Flushing) Options
Interface Mode Options
Pack Control Options
Converting Binary to Hexadecimal
Following are two simple ways to convert binary numbers to hexadecimals.
Conversion Table
Hexadecimal digits have values ranging from 0 to F, which are represented as 0-9, A
(for 10), B (for 11), etc. To convert a binary value (for example, 0100 1100) to a
hexadecimal representation, the upper and lower four bits are treated separately,
resulting in a two-digit hexadecimal number (in this case, 4C). Use the following table
to convert values from binary to hexadecimal.
Decimal
Binary
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