Deld Report
Deld Report
SUBMITTED TO THE SAVITRIBAI PHULE PUNE UNIVERSITY, PUNE IN THE PARTIAL FULFILLMENT OF THE
REQUIREMENTS FOR THE AWARD OF THE
1 Acknowlegdement 01
2 Certificate 02
3 Abstract 03
4 System Specification 04
5 Introduction 05
6 Implementation 06-08
It takes immense pleasure in presenting the complete Mini-Project report on BCD to Decimal Converter
which involves a circuit that can converts Binary Coded decimal (BCD) inputs into a decimal output. I
extend my deepest gratitude to my guide, Prof. Manjusha Mishra for their unwavering support and
guidance. I also wish to thank my Head of Department, Prof. Sagar Rajebhosale, for his invaluable
insights. My heartfelt appreciation goes to Dr. Sandeep Kadam, Principal of our institution, and Prof. Y.R.
Soman,Director, for their encouragement and cooperation throughout the Mini-Project. This Mini-Project
would not have been possible without the support of our faculty members, dear parents, and friends .
SHALAKA FOUNDATION’S
BCD to Decimal Converter: Stimulate a circuit that converts Binary Coded Decimal (BCD) inputs into a decimal
output
have satisfactorily completed the curriculum-based Mini-Project under the guidance of Prof.Manjusha Mishra
towards the fulfillment of 2nd year Computer Engineering , Academic Year 2024-25 of Savitribai Phule Pune
University.
Place: Pune
Date :21/10/2024
Abstract:
-----------------------------------------------------------------------------------------------------
System Specifications:
The BCD to Decimal Converter is designed to convert numbers from Binary-
Coded Decimal (BCD) format to standard decimal format. This document
outlines the specifications for the system, including functionality, input/output
requirements, hardware and software components, and performance criteria.
System Overview :
The converter will take a BCD input, process it, and display the corresponding
decimal output. The system will be user-friendly and efficient, suitable for
educational purposes and practical applications in digital electronics.
1]Functional Requirements:
Input Handling :
- Accept BCD input as a binary string or through switches.
- Support for 4-bit nibbles representing decimal digits (0-9).
Conversion Logic :
- Process each nibble to extract decimal values.
- Accumulate the decimal values into a final output.
Output Display :
- Display the resulting decimal number on a 7-segment display or LCD.
- Provide error handling for invalid BCD inputs (e.g., nibbles greater than
1001).
2] User Interface:
Input Method:
- A keypad or set of switches for user input
Output Method:
- A visual display (LCD or 7-segment display) to show the converted decimal
number.
Control Buttons:
- Buttons for initiating the conversion and resetting the system.
3] Hardware Specifications:
Microcontroller:
- A microcontroller (e.g., Arduino, PIC) to perform the conversion logic
manage inputs/outputs.
Display:
- 7-segment display or LCD module for output.
Input Devices:
- Keypad or switch panel for BCD input.
Power Supply:
- Suitable power source (e.g., USB or battery) to power the microcontroller
and display.
4] Software Specifications:
Programming Language:
- The converter will be programmed in C/C++ or Python
Algorithm:
- Input parsing to read BCD values.
- Conversion algorithm to compute decimal output.
- Error checking for valid BCD input.
5] Performance Requirements:
Conversion Speed:
- The system should provide instantaneous feedback (conversion within
milliseconds).
Accuracy:
- The conversion must accurately reflect decimal values corresponding to the
BCD input.
Error Handling:
- Clearly indicate errors for invalid inputs through display or LED indicators.
Edge Cases:
- Test maximum (9999) and minimum (0000) BCD values.
- Test invalid inputs (e.g., BCD values like 1010 or higher).
Introduction:
Binary Coded Decimal (BCD) is a widely used numeric representation in digital
systems, where each decimal digit is encoded using 4 binary bits. However,
many applications require decimal numbers for display, computation, or human
interaction. The conversion of BCD numbers to decimal representations is
crucial in various fields, including digital instrumentation, embedded systems,
and computing.
Problem Statement:
The conversion of BCD numbers to decimal numbers is a complex process,
requiring efficient algorithms and precise implementation. Existing conversion
methods often involve manual calculations or software-based solutions, which
can be time-consuming, prone to errors, and limited in scalability.
Project Objective:
The objective of this mini project is to design, develop, and implement a
reliable and efficient BCD to Decimal Converter using
[Microcontroller/Programming Language]. The converter should accept 4-bit/8-
bit BCD inputs and produce equivalent decimal numbers, displaying the results
on a [LCD/LED display].
Project Scope:
This project aims to:s
1. Understand BCD and decimal number systems.
2. Design and implement an efficient BCD to decimal conversion algorithm.
3. Utilize [Microcontroller/Programming Language] for hardware/software
implementation.
4. Verify and validate the converter's accuracy and performance.
5. Develop a user-friendly interface for input/output operations.
Project Significance
Project Outline
1. Literature Review
2. Methodology
3. Circuit Diagram and Hardware Implementation
4. Software Implementation (Algorithm and Code)
5. Results and Discussion
-----------------------------------------------------------------------------------------------
Implementation:
Example Walkthrough
- bcd_to_decimal function:
1. Initialize decimal = 0, power = 1.
2. Iterate through nibbles:
- Nibble 1: "0100" -> decimal 4, decimal = 4.
- Nibble 2: "1010" -> decimal 8, decimal = 4 + 8*10 = 84.
3. Return decimal = 82 ( corrected).
- decimal_to_bcd function:
1. Initialize bcd = "".
2. Iterate 2 times (num_digits = 2):
- Digit 1: 2 -> binary "0010", bcd = "0010".
- Digit 2: 8 -> binary "1000", bcd = "1000" + "0010" = "10000010".
3. Return bcd = "10000010" (padded with leading zeros).
BCD TO DECIMAL CONVERTER:
A digital circuit that can convert a binary-coded decimal (BCD) number into an
equivalent decimal number is referred to as a BCD-to-decimal converter.
The input to a BCD to decimal converter is an 8421 BCD code and the output
generated by the converter is a decimal number.
The following is the truth table of the BCD to decimal converter describing its
operation.
BCD Code
Decimal
B3 B2 B1 B0
0 0 0 0 D0
0 0 0 1 D1
0 0 1 0 D2
0 0 1 1 D3
0 1 0 0 D4
0 1 0 1 D5
0 1 1 0 D6
0 1 1 1 D7
1 0 0 0 D8
1 0 0 1 D9
We can derive the Boolean expressions for each of the decimal outputs in terms of 8421 BCD
code. These Boolean expressions are given below −
D0=B3¯B2¯B1¯B0¯
D1=B3¯B2¯B1¯B0
D2=B3¯B2¯B1B0¯
D3=B3¯B2¯B1B0
D4=B3¯B2B1¯B0¯
D5=B3¯B2B1¯B0
D6=B3¯¯¯¯¯¯B2B1B0¯¯¯¯¯¯D6=B3¯B2B1B0¯
D7=B3¯¯¯¯¯¯B2B1B0D7=B3¯B2B1B0
D8=B3B2¯¯¯¯¯¯B1¯¯¯¯¯¯B0¯¯¯¯¯¯D8=B3B2¯B1¯B0¯
D9=B3B2¯¯¯¯¯¯B1¯¯¯¯¯¯B0D9=B3B2¯B1¯B0
Conclusion: