Electronics Area
Tutorials Community Calendar Diagrams Articles Downloads Links
Register
Username:
Password:
Save Password Forgot your password?
Menu
- Active topics (0)
- New Articles (0)
- New Downloads (0)
- Private messages
- My Bookmarks
- Site Statistics
- PM Pager
- Useful links

Members: 39
Active Users:
0 Members and 12 Guests

Top 5 Downloads
Circuit Magic
(Hits: 219)
Symbolic circuits analysis software to simulate AC...
TinyCAD
(Hits: 174)
TinyCAD is a program to help you draw circuit diag...
Free PCB
(Hits: 157)
FreePCB is a free, open-source printed circuit boa...
Electronics Assistant
(Hits: 141)
Electronics Assistant is a program that performs e...
VisualSpice Schematic Editor and Mixed Mode Simulation
(Hits: 94)
VisualSpice is a completely integrated 32-bit anal...

The BCD Code

BCD Code: Binary Coded Decimal



The BCD Code

In order to share information, that is in digital format, it is common to use a binary or hex representations.

There are other methods to represent this information and one of them is the BCD code.

Using the BCD coding is easy to see the relationship between a decimal number (base 10) and the corresponding binary one (base 2)

The BCD code uses 4 binary digits (see the two examples below) to represent a decimal number (0 to 9).

When you make a normal convertion from a binary number to a decimal one there is no direct relationship between the decimal digit and the binary digit.

Example #1:

Decimal to BCD code convertion example # 1 . Electronics AreaThis is a direct normal convertion from a decimal number to a binary one.
8510 = 10101012

The representation of the same decimal number on BCD code is shown on the right side

Example # 2:

Decimal to BCD code convertion example # 2 . Electronics AreaThis is a direct normal convertion from a decimal number to a binary one.
56810 = 10001110002

The representation of the same decimal number on BCD code is shown on the right side

As you can see from the above two examples, the decimal equivalent number does not seem to be a good BCD representation.

To obtain the equivalent BCD code of each previous decimal number, we have to assign a "weight" or "value" to each digit according to its position.

This "weight" or "value" follows the following order: 8 - 4 - 2 - 1. (It is a weighted code)

The last example shows that the number 5 is represented as: 0 1 0 1.
the first "0" corresponds to 8,
the first "1" corresponds to 4,
the second "0" corresponds to 2, and ...
the second "1" corresponds to 1.

Decimal to BCD code convertion table . Electronics AreaFrom the above: 0x8 + 1x4 + 0x2 + 1x1 = 5

The BCD code that has the "weights" or "values" described before is called: Natural BCD Code.

The BCD code counts like a normal binary number from 0 to 9, but numbers from ten (1010) to fifteen (1111) are not used because these numbers do not have an equivalent decimal number.

This code is used, among other applications, to represent decimal numbers on 7 segment displays.

Notes: The subscript 2 and 10, are used to represent, in the first case a binary number and in the second case a decimal number.


Related Links
- Logic Circuit
- The truth table
- Logic Levels
- Analog and Digital. What´s the difference?




Tutorials main page

Poll Results:
 Poll has expired
Question: Do you like this site?
Yes:  35 (92%)
No:  3 (8%)
Total: 38 votes

View Results

The Hunger Site

The Rainforest Site

Set as your default homepage Add favorite Privacy   2008-9 ElectronicsArea.com All Rights Reserved MaxWebPortal Snitz Forums Go To Top Of Page