BCD

Binary-Coded Decimal is a means of coding decimal values into binary.

A 4-bit nibble is used to represent a single decimal digit.


 * 0000 = 0
 * 0001 = 1
 * 0010 = 2
 * 0011 = 3
 * 0100 = 4
 * 0101 = 5
 * 0110 = 6
 * 0111 = 7
 * 1000 = 8
 * 1001 = 9

Decimal value 1999 would be encoded in 16 BCD bits as: 0001 1001 1001 1001