10
BCD While it is necessary for PLCs to use binary values, humans
often need to see values represented in decimal. As a result,
some input and output devices provide a decimal display where
each decimal digit corresponds to four PLC binary inputs or
outputs. The most common system used by input and output
devices of this type is referred to as
binary-coded decimal
(BCD).
One example of a BCD device is a type of four-digit
thumbwheel switch. Each thumbwheel digit controls four
PLC inputs. This means that for a four-digit thumbwheel, 16
inputs are required. Because each thumbwheel digit only
needs to represent decimal values from 0 through 9, only ten
corresponding binary values are required for each digit.
Hexadecimal Hexadecimal is another system used in PLCs. The ten digits
of the decimal system are used for the first ten characters of
the hexadecimal system. The first six letters of the alphabet are
used for the remaining six characters.
The hexadecimal system is used in PLCs because it allows the
status of a large number of binary bits to be represented in a
small space such as on a computer screen or programming
device display. Each hexadecimal character represents the exact
status of four binary bits.
Hexadecimal Number System
16 digits 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F
Base 16
Weights Powers of base 16 (1, 16, 256, 4096, ...)
Binary Equivalent
0 0 1 1 1 0 1 0 0 0 1 0 1 1 1 1