# BCD to 7 Segment Decoder

DescriptionThis app simulates a Binary Coded Decimal (BCD) to 7 segment display driver circuit.

## Download

.xls file (26 KB)## How to use

Click on the checkboxes next to turn the inputs to the circuit ON or OFF. Bit 1 is the most significant bit while Bit 4 is the least significant. The circuit accepts inputs from 0000 (all bits OFF) to 1111 (all bits ON). Hex characters (A - F) are discplayed for inputs greater than 9 (1001).## How it works

The interesting feature of this app is that there are no macros or even formulae entered directly in the cells, all functionality is achieved using a Named Formula and Conditional Formatting . The Named Formula works out the input to the ciruit while the "LEDs" of the 7 segment display are run using conditional formatting. The check boxes are linked to the cells A1, B1, C1 and D1, and the input formula "Input" works out the entry in Binary.The formula is:

Input=VALUE((Sheet1!$A$1+0)&(Sheet1!$B$1+0)&(Sheet1!$C$1+0)&(Sheet1!$D$1+0))

Adding a 0 converts the boolean values in cells A1 through D1 into a number.

The logic driving the LEDs can be constructed from AND and OR statements, and are easily handled using conditional formatting. The formatting is used to turn the LEDs off at the appropriate inputs. Conditional formatting is also used to show the switches opening and closing at the input of the circuit.

## Contribution from Visitors: BCD with Scrollbar

Alexander Weiner from Germany has kindly contributed his version of this app, he uses a scrollbar to scroll through the numbers 0 to 9. His version can be downloaded here. Use the scrollbar in column Y to scroll through the decimal numbers. Standard Excel functions are used to converting the decimal numbers to binary in this version.## Also See:

Animation without ChartsOscilloscope / Function Generator Simulator

Simulation of a logic circuit for alarming

Simulation of On Off Control