|How To Build A Simple Decimal To BCD Decimal Converter
When a keypad switch is pressed - this circuit will reproduce its value in Binary Coded Decimal from. I've used a 12-key pad. But it may be expanded to 16 keys - to provide Hexadecimal to BCD conversion.
The circuit is constructed in two parts. There's a keypad module - and a memory module. On its own - the keypad module only produces a transient output - that disappears the moment you release the switch. But add the memory module - and the output will remain latched - until it's replaced by the next keystroke.
The circuit will work at anything from 5 to 15 vdc. The LEDs are a visual indication of the BCD value. They are not necessary to the operation of the circuit. If you wish - you may leave them out - together with their associated resistors (R5, R6, R7 & R8).
The memory module uses a Cmos 4081. At the start of every keystroke - Q1 takes one input pin from each gate low. This resets all four output pins to zero - momentarily. Then any inputs taken high by the keypad - will latch themselves on through R1, R2, R3 & R4. And the new BCD number will be displayed. Note that A, B, C & D are connected directly to the output pins of the Cmos IC. You will need to regulate the load your application places on these outputs.