SlideShare a Scribd company logo
1 of 13
Download to read offline
63
IMPLEMENTATION OF ALPHANUMERIC ON A SEVEN
SEGMENT DISPLAY
OBJECTIVE
The main idea behind this is to implement the BINARY INPUT TO DISPLAY LETTERS AND
NUMBERS ON A SEVEN SEGMENT DISPLAY available on the NEXYS 4 DDR. In this the
binary input is applied through switches available on the board and the output will be a
combinational display of number’s (0-9) and letters from (a to z).
Tools:
Software Tools– Xilinx VIVADO design suite 14.2
Hardware Tools – Nexys 4 DDR
Basic idea:
Generally the seven segment displays are used in digital circuits to represent numbers. One of the
most common applications is in digital watches. We can implement the seven segment display
using BCD/HEXA input in which all the numbers from 0 to 9 are displayed and a letters from a
to f can be implemented, but using the single input values/ ASCII values (in binary format) as
inputs we wanted to generate all the letters from a to z and numbers from 0 to 9 on a single
platform.
The general idea representation is as shown below:
Letter ASCII Code Binary Letter ASCII Code Binary
a 097 01100001 A 065 01000001
b 098 01100010 B 066 01000010
c 099 01100011 C 067 01000011
Here we use the switches available on the Nexys board to provide the binary bits as input. The
binary input corresponding to the ASCII value has a letter associate with it which is displayed on
the seven segments corresponding to the VHDL program.
An example representation of the visual idea of the project described:
64
Block diagram
Fig.1 Block Diagram for Alpha Numeric on Seven Segment.
Seven Segment Display
A seven segment display is a form of electronic display device which is used to display
numerals. We can commonly find the seven segment display in digital devices which is used to
represent the numeric information to user, like watches, calculators, electronic instruments etc.
The name seven segment display itself states that it is a combination of seven segments of
display which are arranged in a fashion to represent numerals, when programmed in different
fashion. These seven different segments are marked from A-G as in, fig (2).
Fig 2: A Generalized Seven Segment Display.
FPGA Hardware Kit
6 5 4 3 2 1 0
Switches
s
Input
ASCII
Code
Simulation
& Synthesis
in Vivado
14.2
Simulated
Waveform
Seven segment array
Output Seven
Segment
Display
65
Types of seven segment display:
There are two types of seven segment display namely
1) Common Anode 7-segment display
2) Common Cathode 7-segment display
Display of Numerals &Letters
All the numerals can be displayed on the seven segment display. Along with the displaying of
numerals we can also display all the alphabets on the seven segments. A series of seven
segments display can also be used to represent words and scrolling sentences. The different
display of letters can be seen in the fig (2).
Fig 2: Seven segment display of letters and numerals
The project gives a basic idea of how the seven segment display is used to implement the display
of numerals and letters using 8 bits of binary input, using the NEXYS 4 DDR FPGA kit.
We have used VHDL coding to program the FPGA [XC100tcsg1] so that the binary input given
through switches is decoded according to the program which consists of defined modules to
convert the binary input to corresponding seven segment output. According to the program
output the seven segments glow to represent the corresponding output.
66
In the project we have used a common anode type Seven segment display, hence to make a
segment ‘ON’ we have to provide logic ‘0’ and to make a segment ‘OFF’ we have to provide
logic ‘1’.
Binary Switch Logic
INPUTS
Fig.3 Segment and switch number representation
1 1 1 1 1 1 1
0 0 0 0 0 0 0
SWITCH
ON
SWITCH
OFF
sw1 sw2 sw3 sw4 sw5 sw6 sw7
67
Aim:
To program the FPGA [XC100tcsg1] in VHDL for display numerals and letters on the seven
segments by providing 8 bit binary as input and to verify the output using the hardware kit.
Apparatus:
Hardware: Nexys 4 DDR FPGA kit.
Software: Xilinx Vivado design suite 14.2.
Verilog code:
module binary_to_seven_segment_display_project(
input [6:0] ip,
output a,b,c,d,e,f,g,
output [7:0] an
);
reg a,b,c,d,e,f,g;
reg [7:0] an = 8'b11111110;
always @ (ip) // checks for every change in input
// Code for Alphabets
if(ip[5] && ip[6])
begin
if(ip[0] && ~ip[1] && ~ip[2] && ~ip[3] && ~ip[4])
begin: a1
a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b0;
end
else if(~ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4])
begin : b1
a=1'b1; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4])
begin: c1
a=1'b1; b=1'b1; c=1'b1; d=1'b0; e=1'b0; f=1'b1; g=1'b0;
end
else if(~ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: d1
a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b0;
end
68
else if(ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: e1
a=1'b0; b=1'b0; c=1'b1; d=1'b0; e=1'b0; f=1'b0; g=1'b0;
end
else if(~ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: f1
a=1'b0; b=1'b1; c=1'b1; d=1'b1; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: g1
a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0;
end
else if(~ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4])
begin: h
a=1'b1; b=1'b1; c=1'b0; d=1'b1; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4])
begin: i
a=1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b0; f=1'b0; g=1'b1;
end
else if(~ip[0] &&ip[1] && ~ip[2] &&ip[3] && ~ip[4])
begin: j
a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b1;
end
else if(ip[0] &&ip[1] && ~ip[2] &&ip[3] && ~ip[4])
begin: k
a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b0; f=1'b0; g=1'b0;
end
else if(~ip[0] && ~ip[1] &&ip[2] &&ip[3] && ~ip[4])
begin: l
a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b1; g=1'b1;
end
else if(ip[0] && ~ip[1] &&ip[2] &&ip[3] && ~ip[4])
begin: m
a=1'b0; b=1'b1; c=1'b0; d=1'b1; e=1'b0; f=1'b1; g=1'b1;
end
else if(~ip[0] &&ip[1] &&ip[2] &&ip[3] && ~ip[4])
begin: n
a=1'b1; b=1'b1; c=1'b0; d=1'b1; e=1'b0; f=1'b1; g=1'b0;
end
else if(ip[0] &&ip[1] &&ip[2] &&ip[3] && ~ip[4])
begin: o
a=1'b1; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b0;
end
else if(~ip[0] && ~ip[1] && ~ip[2] && ~ip[3] &&ip[4])
begin: p
69
a=1'b0; b=1'b0; c=1'b1; d=1'b1; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] && ~ip[1] && ~ip[2] && ~ip[3] &&ip[4])
begin: q
a=1'b0; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b0; g=1'b0;
end
else if(~ip[0] &&ip[1] && ~ip[2] && ~ip[3] &&ip[4])
begin: r
a=1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b0; f=1'b1; g=1'b0;
end
else if(ip[0] &&ip[1] && ~ip[2] && ~ip[3] &&ip[4])
begin: s
a=1'b0; b=1'b1; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0;
end
else if(~ip[0] && ~ip[1] &&ip[2] && ~ip[3] &&ip[4])
begin: t
a=1'b1; b=1'b1; c=1'b1; d=1'b0; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] && ~ip[1] &&ip[2] && ~ip[3] &&ip[4])
begin: u
a=1'b1; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b1;
end
else if(~ip[0] &&ip[1] &&ip[2] && ~ip[3] &&ip[4])
begin: v
a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b1;
end
else if(ip[0] &&ip[1] &&ip[2] && ~ip[3] &&ip[4])
begin: w
a=1'b1; b=1'b0; c=1'b1; d=1'b0; e=1'b1; f=1'b0; g=1'b1;
end
else if(~ip[0] && ~ip[1] && ~ip[2] &&ip[3] &&ip[4])
begin: x
a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] && ~ip[1] && ~ip[2] &&ip[3] &&ip[4])
begin: y
a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0;
end
else if(~ip[0] &&ip[1] && ~ip[2] &&ip[3] &&ip[4])
begin: z
a=1'b0; b=1'b0; c=1'b1; d=1'b0; e=1'b0; f=1'b1; g=1'b0;
end
end
else
70
begin: numbers
if(~ip[5] && ~ip[6])
// Code for Numbers
begin
if(~ip[0] && ~ip[1] && ~ip[2] && ~ip[3] && ~ip[4])
begin: zero
a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b1;
end
else if(ip[0] && ~ip[1] && ~ip[2] && ~ip[3] && ~ip[4])
begin: one
a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b1; g=1'b1;
end
else if(~ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4])
begin: two
a=1'b0; b=1'b0; c=1'b1; d=1'b0; e=1'b0; f=1'b1; g=1'b0;
end
else if(ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4])
begin: three
a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b1; f=1'b1; g=1'b0;
end
else if(~ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: four
a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b0; g=1'b0;
end
else if(ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: five
a=1'b0; b=1'b1; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0;
end
else if(~ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: six
a=1'b0; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4])
begin: seven
a=1'b0; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b1; g=1'b1;
end
else if(~ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4])
begin: eight
a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b0;
end
else if(ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4])
71
begin: nine
a=1'b0; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b0; g=1'b0;
end
else
begin: null
a=1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b1; f=1'b1; g=1'b1;
end
end
else
begin
=1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b1; f=1'b1; g=1'b1;
end
end
endmodule
72
Verification:
Simulation:
The process of verification of functional correctness of the written code is called simulation
The above code is simulated and verified in the Xilinx Vivado design suite 14.2 for the exact
output. It needs an additional test bench to be written for the purpose of verification in which we
predefine the values.
Synthesis:
The process of mapping the implemented code onto a real world device is known as synthesis.
This is again done by the software
After the functional verification we have dumped the code into the hardware kit, Nexys 4 DDR
to verify the results on the seven segment display available on the kit
Output
The result of the above written code is as shown below:
Simulated output:
73
Synthesized output
When i/p is 1001010 output represented as J When i/p is 01100001 output represented as a
When i/p is 0000000 output represented as 0 When i/p is 0000111output represented as 7
74
Drawbacks:
In the above seven segmented display we cannot display few letters accurately for user
understanding, the user has to compromise between some letters such as W,X,K etc.
Conclusion:
The implementation of ASCII code to alphanumeric seven segment display has been performed
in the Vivado design suite and the simulated output is verified.
The Synthesized output has been performed and observed on the Xilinx Nexys 4 DDR FPGA kit
and the sample kit picture has been added to the project report.
75

More Related Content

What's hot

DESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTORDESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTORpgayatrinaidu
 
Wireless Electronic Notice Board
Wireless Electronic Notice BoardWireless Electronic Notice Board
Wireless Electronic Notice BoardSajan CK
 
lesson2 - Nodemcu course - NodeMCU dev Board
 lesson2 - Nodemcu course - NodeMCU dev Board lesson2 - Nodemcu course - NodeMCU dev Board
lesson2 - Nodemcu course - NodeMCU dev BoardElaf A.Saeed
 
MOSFET and Short channel effects
MOSFET and Short channel effectsMOSFET and Short channel effects
MOSFET and Short channel effectsLee Rather
 
Tunnel Diode presentation
Tunnel Diode presentationTunnel Diode presentation
Tunnel Diode presentationBilawal Fiaz
 
Vhdl code and project report of arithmetic and logic unit
Vhdl code and project report of arithmetic and logic unitVhdl code and project report of arithmetic and logic unit
Vhdl code and project report of arithmetic and logic unitNikhil Sahu
 
E- Notice Board Presentation
E- Notice Board PresentationE- Notice Board Presentation
E- Notice Board Presentationayushi jain
 
Project smart notice board ppt
Project smart notice board pptProject smart notice board ppt
Project smart notice board pptRahul Shaw
 
Smart traffic light controller using verilog
Smart traffic light controller using verilogSmart traffic light controller using verilog
Smart traffic light controller using verilogVaishaliVaishali14
 
E notice board project report
E notice board project reportE notice board project report
E notice board project reportamit chaudhary
 
Verilog VHDL code Parallel adder
Verilog VHDL code Parallel adder Verilog VHDL code Parallel adder
Verilog VHDL code Parallel adder Bharti Airtel Ltd.
 
Experiment write-vhdl-code-for-realize-all-logic-gates
Experiment write-vhdl-code-for-realize-all-logic-gatesExperiment write-vhdl-code-for-realize-all-logic-gates
Experiment write-vhdl-code-for-realize-all-logic-gatesRicardo Castro
 
Vlsi design mosfet
Vlsi design mosfetVlsi design mosfet
Vlsi design mosfetvennila12
 

What's hot (20)

DESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTORDESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTOR
 
1st Semester M Tech CMOS VLSI Design (Dec-2013) Question Papers
1st Semester M Tech CMOS VLSI Design (Dec-2013) Question Papers1st Semester M Tech CMOS VLSI Design (Dec-2013) Question Papers
1st Semester M Tech CMOS VLSI Design (Dec-2013) Question Papers
 
Wireless Electronic Notice Board
Wireless Electronic Notice BoardWireless Electronic Notice Board
Wireless Electronic Notice Board
 
8 bit full adder
8 bit full adder8 bit full adder
8 bit full adder
 
lesson2 - Nodemcu course - NodeMCU dev Board
 lesson2 - Nodemcu course - NodeMCU dev Board lesson2 - Nodemcu course - NodeMCU dev Board
lesson2 - Nodemcu course - NodeMCU dev Board
 
7 Segment Decoder
7 Segment Decoder7 Segment Decoder
7 Segment Decoder
 
MOSFET and Short channel effects
MOSFET and Short channel effectsMOSFET and Short channel effects
MOSFET and Short channel effects
 
Vhdl programming
Vhdl programmingVhdl programming
Vhdl programming
 
Verilog tutorial
Verilog tutorialVerilog tutorial
Verilog tutorial
 
Tunnel Diode presentation
Tunnel Diode presentationTunnel Diode presentation
Tunnel Diode presentation
 
Vhdl code and project report of arithmetic and logic unit
Vhdl code and project report of arithmetic and logic unitVhdl code and project report of arithmetic and logic unit
Vhdl code and project report of arithmetic and logic unit
 
E- Notice Board Presentation
E- Notice Board PresentationE- Notice Board Presentation
E- Notice Board Presentation
 
Project smart notice board ppt
Project smart notice board pptProject smart notice board ppt
Project smart notice board ppt
 
Smart traffic light controller using verilog
Smart traffic light controller using verilogSmart traffic light controller using verilog
Smart traffic light controller using verilog
 
PIC Microcontroller | ADC Interfacing
PIC Microcontroller | ADC InterfacingPIC Microcontroller | ADC Interfacing
PIC Microcontroller | ADC Interfacing
 
E notice board project report
E notice board project reportE notice board project report
E notice board project report
 
Verilog VHDL code Parallel adder
Verilog VHDL code Parallel adder Verilog VHDL code Parallel adder
Verilog VHDL code Parallel adder
 
Experiment write-vhdl-code-for-realize-all-logic-gates
Experiment write-vhdl-code-for-realize-all-logic-gatesExperiment write-vhdl-code-for-realize-all-logic-gates
Experiment write-vhdl-code-for-realize-all-logic-gates
 
Vlsi design mosfet
Vlsi design mosfetVlsi design mosfet
Vlsi design mosfet
 
4 bit add sub
4 bit add sub4 bit add sub
4 bit add sub
 

Viewers also liked

الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...
الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...
الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...QNB Group
 
Реформування середньої освіти у контексті децентралізації
Реформування середньої освіти у контексті децентралізаціїРеформування середньої освіти у контексті децентралізації
Реформування середньої освіти у контексті децентралізаціїCSIUKRAINE
 
tourism of Germany
tourism of Germany tourism of Germany
tourism of Germany fiyaan
 
Layout & typography in detail
Layout & typography in detailLayout & typography in detail
Layout & typography in detailsami ullah
 
An Analysis of Indian Banking Industry with Special Reference to ICICI Bank
An Analysis of Indian Banking Industry with Special Reference to ICICI BankAn Analysis of Indian Banking Industry with Special Reference to ICICI Bank
An Analysis of Indian Banking Industry with Special Reference to ICICI Bankpaperpublications3
 
Professional Profile CRA
Professional Profile CRAProfessional Profile CRA
Professional Profile CRAkelvin bodley
 
Mahlobo Foundation Pty Ltd
Mahlobo Foundation Pty LtdMahlobo Foundation Pty Ltd
Mahlobo Foundation Pty LtdThabo Mahlobo
 
Tema sociales SANTILLANA 4 PRIMARIA
Tema sociales SANTILLANA 4 PRIMARIATema sociales SANTILLANA 4 PRIMARIA
Tema sociales SANTILLANA 4 PRIMARIAluisillo007
 
The Crown of Life, 11/13/16
The Crown of Life, 11/13/16The Crown of Life, 11/13/16
The Crown of Life, 11/13/16CLADSM
 
Uganda Wildlife SAFARIS &Tours
Uganda Wildlife SAFARIS &ToursUganda Wildlife SAFARIS &Tours
Uganda Wildlife SAFARIS &Toursaugandasafari
 

Viewers also liked (15)

Seven segment display
Seven segment displaySeven segment display
Seven segment display
 
VINAYA_B_ADIGA
VINAYA_B_ADIGAVINAYA_B_ADIGA
VINAYA_B_ADIGA
 
الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...
الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...
الشركات الأميركية والخليجية تتقدم في قائمة فاينانشيال تايمز لأكبر 500 شركة عا...
 
Реформування середньої освіти у контексті децентралізації
Реформування середньої освіти у контексті децентралізаціїРеформування середньої освіти у контексті децентралізації
Реформування середньої освіти у контексті децентралізації
 
tourism of Germany
tourism of Germany tourism of Germany
tourism of Germany
 
Layout & typography in detail
Layout & typography in detailLayout & typography in detail
Layout & typography in detail
 
An Analysis of Indian Banking Industry with Special Reference to ICICI Bank
An Analysis of Indian Banking Industry with Special Reference to ICICI BankAn Analysis of Indian Banking Industry with Special Reference to ICICI Bank
An Analysis of Indian Banking Industry with Special Reference to ICICI Bank
 
Professional Profile CRA
Professional Profile CRAProfessional Profile CRA
Professional Profile CRA
 
Grupo Normex
Grupo NormexGrupo Normex
Grupo Normex
 
Collaborate to Share
Collaborate to ShareCollaborate to Share
Collaborate to Share
 
Mahlobo Foundation Pty Ltd
Mahlobo Foundation Pty LtdMahlobo Foundation Pty Ltd
Mahlobo Foundation Pty Ltd
 
Tema sociales SANTILLANA 4 PRIMARIA
Tema sociales SANTILLANA 4 PRIMARIATema sociales SANTILLANA 4 PRIMARIA
Tema sociales SANTILLANA 4 PRIMARIA
 
¿Cómo pensamos?
¿Cómo pensamos?¿Cómo pensamos?
¿Cómo pensamos?
 
The Crown of Life, 11/13/16
The Crown of Life, 11/13/16The Crown of Life, 11/13/16
The Crown of Life, 11/13/16
 
Uganda Wildlife SAFARIS &Tours
Uganda Wildlife SAFARIS &ToursUganda Wildlife SAFARIS &Tours
Uganda Wildlife SAFARIS &Tours
 

Similar to Seven segment display

2 Level Guitar Hero Final Report
2 Level Guitar Hero Final Report2 Level Guitar Hero Final Report
2 Level Guitar Hero Final ReportCem Recai Çırak
 
Getting Started with Raspberry Pi - DCC 2013.1
Getting Started with Raspberry Pi - DCC 2013.1Getting Started with Raspberry Pi - DCC 2013.1
Getting Started with Raspberry Pi - DCC 2013.1Tom Paulus
 
Digital Alarm Clock 446 project report
Digital Alarm Clock 446 project reportDigital Alarm Clock 446 project report
Digital Alarm Clock 446 project reportAkash Mhankale
 
Getting Started With Raspberry Pi - UCSD 2013
Getting Started With Raspberry Pi - UCSD 2013Getting Started With Raspberry Pi - UCSD 2013
Getting Started With Raspberry Pi - UCSD 2013Tom Paulus
 
CODING QUESTIONS.pptx
CODING QUESTIONS.pptxCODING QUESTIONS.pptx
CODING QUESTIONS.pptxrani marri
 
Seven segment display
Seven segment display Seven segment display
Seven segment display SalmaAkter37
 
Arduino coding class
Arduino coding classArduino coding class
Arduino coding classJonah Marrs
 
Computer Networks Lab File
Computer Networks Lab FileComputer Networks Lab File
Computer Networks Lab FileKandarp Tiwari
 
LDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdf
LDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdfLDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdf
LDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdfVedant Gavhane
 
VLSI experiments II
VLSI experiments IIVLSI experiments II
VLSI experiments IIGouthaman V
 
Computer archi&mp
Computer archi&mpComputer archi&mp
Computer archi&mpMSc CST
 
Sample Program file class 11.pdf
Sample Program file class 11.pdfSample Program file class 11.pdf
Sample Program file class 11.pdfYashMirge2
 
Computer Organization And Architecture lab manual
Computer Organization And Architecture lab manualComputer Organization And Architecture lab manual
Computer Organization And Architecture lab manualNitesh Dubey
 

Similar to Seven segment display (20)

2 Level Guitar Hero Final Report
2 Level Guitar Hero Final Report2 Level Guitar Hero Final Report
2 Level Guitar Hero Final Report
 
Est 6
Est 6Est 6
Est 6
 
Getting Started with Raspberry Pi - DCC 2013.1
Getting Started with Raspberry Pi - DCC 2013.1Getting Started with Raspberry Pi - DCC 2013.1
Getting Started with Raspberry Pi - DCC 2013.1
 
Digital Alarm Clock 446 project report
Digital Alarm Clock 446 project reportDigital Alarm Clock 446 project report
Digital Alarm Clock 446 project report
 
Getting Started With Raspberry Pi - UCSD 2013
Getting Started With Raspberry Pi - UCSD 2013Getting Started With Raspberry Pi - UCSD 2013
Getting Started With Raspberry Pi - UCSD 2013
 
Interpreter, Compiler, JIT from scratch
Interpreter, Compiler, JIT from scratchInterpreter, Compiler, JIT from scratch
Interpreter, Compiler, JIT from scratch
 
CODING QUESTIONS.pptx
CODING QUESTIONS.pptxCODING QUESTIONS.pptx
CODING QUESTIONS.pptx
 
Seven segment display
Seven segment display Seven segment display
Seven segment display
 
Arduino coding class
Arduino coding classArduino coding class
Arduino coding class
 
Computer Networks Lab File
Computer Networks Lab FileComputer Networks Lab File
Computer Networks Lab File
 
Anup2
Anup2Anup2
Anup2
 
LDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdf
LDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdfLDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdf
LDCQ paper Dec21 with answer key_62cb2996afc60f6aedeb248c1d9283e5.pdf
 
VLSI experiments II
VLSI experiments IIVLSI experiments II
VLSI experiments II
 
Computer archi&mp
Computer archi&mpComputer archi&mp
Computer archi&mp
 
08 decoder
08 decoder08 decoder
08 decoder
 
mod-4.pptx
mod-4.pptxmod-4.pptx
mod-4.pptx
 
Unit 4 dica
Unit 4 dicaUnit 4 dica
Unit 4 dica
 
Sample Program file class 11.pdf
Sample Program file class 11.pdfSample Program file class 11.pdf
Sample Program file class 11.pdf
 
Computer Organization And Architecture lab manual
Computer Organization And Architecture lab manualComputer Organization And Architecture lab manual
Computer Organization And Architecture lab manual
 
VerilogHDL_Utkarsh_kulshrestha
VerilogHDL_Utkarsh_kulshresthaVerilogHDL_Utkarsh_kulshrestha
VerilogHDL_Utkarsh_kulshrestha
 

Recently uploaded

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 

Recently uploaded (20)

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 

Seven segment display

  • 1. 63 IMPLEMENTATION OF ALPHANUMERIC ON A SEVEN SEGMENT DISPLAY OBJECTIVE The main idea behind this is to implement the BINARY INPUT TO DISPLAY LETTERS AND NUMBERS ON A SEVEN SEGMENT DISPLAY available on the NEXYS 4 DDR. In this the binary input is applied through switches available on the board and the output will be a combinational display of number’s (0-9) and letters from (a to z). Tools: Software Tools– Xilinx VIVADO design suite 14.2 Hardware Tools – Nexys 4 DDR Basic idea: Generally the seven segment displays are used in digital circuits to represent numbers. One of the most common applications is in digital watches. We can implement the seven segment display using BCD/HEXA input in which all the numbers from 0 to 9 are displayed and a letters from a to f can be implemented, but using the single input values/ ASCII values (in binary format) as inputs we wanted to generate all the letters from a to z and numbers from 0 to 9 on a single platform. The general idea representation is as shown below: Letter ASCII Code Binary Letter ASCII Code Binary a 097 01100001 A 065 01000001 b 098 01100010 B 066 01000010 c 099 01100011 C 067 01000011 Here we use the switches available on the Nexys board to provide the binary bits as input. The binary input corresponding to the ASCII value has a letter associate with it which is displayed on the seven segments corresponding to the VHDL program. An example representation of the visual idea of the project described:
  • 2. 64 Block diagram Fig.1 Block Diagram for Alpha Numeric on Seven Segment. Seven Segment Display A seven segment display is a form of electronic display device which is used to display numerals. We can commonly find the seven segment display in digital devices which is used to represent the numeric information to user, like watches, calculators, electronic instruments etc. The name seven segment display itself states that it is a combination of seven segments of display which are arranged in a fashion to represent numerals, when programmed in different fashion. These seven different segments are marked from A-G as in, fig (2). Fig 2: A Generalized Seven Segment Display. FPGA Hardware Kit 6 5 4 3 2 1 0 Switches s Input ASCII Code Simulation & Synthesis in Vivado 14.2 Simulated Waveform Seven segment array Output Seven Segment Display
  • 3. 65 Types of seven segment display: There are two types of seven segment display namely 1) Common Anode 7-segment display 2) Common Cathode 7-segment display Display of Numerals &Letters All the numerals can be displayed on the seven segment display. Along with the displaying of numerals we can also display all the alphabets on the seven segments. A series of seven segments display can also be used to represent words and scrolling sentences. The different display of letters can be seen in the fig (2). Fig 2: Seven segment display of letters and numerals The project gives a basic idea of how the seven segment display is used to implement the display of numerals and letters using 8 bits of binary input, using the NEXYS 4 DDR FPGA kit. We have used VHDL coding to program the FPGA [XC100tcsg1] so that the binary input given through switches is decoded according to the program which consists of defined modules to convert the binary input to corresponding seven segment output. According to the program output the seven segments glow to represent the corresponding output.
  • 4. 66 In the project we have used a common anode type Seven segment display, hence to make a segment ‘ON’ we have to provide logic ‘0’ and to make a segment ‘OFF’ we have to provide logic ‘1’. Binary Switch Logic INPUTS Fig.3 Segment and switch number representation 1 1 1 1 1 1 1 0 0 0 0 0 0 0 SWITCH ON SWITCH OFF sw1 sw2 sw3 sw4 sw5 sw6 sw7
  • 5. 67 Aim: To program the FPGA [XC100tcsg1] in VHDL for display numerals and letters on the seven segments by providing 8 bit binary as input and to verify the output using the hardware kit. Apparatus: Hardware: Nexys 4 DDR FPGA kit. Software: Xilinx Vivado design suite 14.2. Verilog code: module binary_to_seven_segment_display_project( input [6:0] ip, output a,b,c,d,e,f,g, output [7:0] an ); reg a,b,c,d,e,f,g; reg [7:0] an = 8'b11111110; always @ (ip) // checks for every change in input // Code for Alphabets if(ip[5] && ip[6]) begin if(ip[0] && ~ip[1] && ~ip[2] && ~ip[3] && ~ip[4]) begin: a1 a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b0; end else if(~ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4]) begin : b1 a=1'b1; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4]) begin: c1 a=1'b1; b=1'b1; c=1'b1; d=1'b0; e=1'b0; f=1'b1; g=1'b0; end else if(~ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: d1 a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b0; end
  • 6. 68 else if(ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: e1 a=1'b0; b=1'b0; c=1'b1; d=1'b0; e=1'b0; f=1'b0; g=1'b0; end else if(~ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: f1 a=1'b0; b=1'b1; c=1'b1; d=1'b1; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: g1 a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0; end else if(~ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4]) begin: h a=1'b1; b=1'b1; c=1'b0; d=1'b1; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4]) begin: i a=1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b0; f=1'b0; g=1'b1; end else if(~ip[0] &&ip[1] && ~ip[2] &&ip[3] && ~ip[4]) begin: j a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b1; end else if(ip[0] &&ip[1] && ~ip[2] &&ip[3] && ~ip[4]) begin: k a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b0; f=1'b0; g=1'b0; end else if(~ip[0] && ~ip[1] &&ip[2] &&ip[3] && ~ip[4]) begin: l a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b1; g=1'b1; end else if(ip[0] && ~ip[1] &&ip[2] &&ip[3] && ~ip[4]) begin: m a=1'b0; b=1'b1; c=1'b0; d=1'b1; e=1'b0; f=1'b1; g=1'b1; end else if(~ip[0] &&ip[1] &&ip[2] &&ip[3] && ~ip[4]) begin: n a=1'b1; b=1'b1; c=1'b0; d=1'b1; e=1'b0; f=1'b1; g=1'b0; end else if(ip[0] &&ip[1] &&ip[2] &&ip[3] && ~ip[4]) begin: o a=1'b1; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b0; end else if(~ip[0] && ~ip[1] && ~ip[2] && ~ip[3] &&ip[4]) begin: p
  • 7. 69 a=1'b0; b=1'b0; c=1'b1; d=1'b1; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] && ~ip[1] && ~ip[2] && ~ip[3] &&ip[4]) begin: q a=1'b0; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b0; g=1'b0; end else if(~ip[0] &&ip[1] && ~ip[2] && ~ip[3] &&ip[4]) begin: r a=1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b0; f=1'b1; g=1'b0; end else if(ip[0] &&ip[1] && ~ip[2] && ~ip[3] &&ip[4]) begin: s a=1'b0; b=1'b1; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0; end else if(~ip[0] && ~ip[1] &&ip[2] && ~ip[3] &&ip[4]) begin: t a=1'b1; b=1'b1; c=1'b1; d=1'b0; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] && ~ip[1] &&ip[2] && ~ip[3] &&ip[4]) begin: u a=1'b1; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b1; g=1'b1; end else if(~ip[0] &&ip[1] &&ip[2] && ~ip[3] &&ip[4]) begin: v a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b1; end else if(ip[0] &&ip[1] &&ip[2] && ~ip[3] &&ip[4]) begin: w a=1'b1; b=1'b0; c=1'b1; d=1'b0; e=1'b1; f=1'b0; g=1'b1; end else if(~ip[0] && ~ip[1] && ~ip[2] &&ip[3] &&ip[4]) begin: x a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] && ~ip[1] && ~ip[2] &&ip[3] &&ip[4]) begin: y a=1'b1; b=1'b0; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0; end else if(~ip[0] &&ip[1] && ~ip[2] &&ip[3] &&ip[4]) begin: z a=1'b0; b=1'b0; c=1'b1; d=1'b0; e=1'b0; f=1'b1; g=1'b0; end end else
  • 8. 70 begin: numbers if(~ip[5] && ~ip[6]) // Code for Numbers begin if(~ip[0] && ~ip[1] && ~ip[2] && ~ip[3] && ~ip[4]) begin: zero a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b1; end else if(ip[0] && ~ip[1] && ~ip[2] && ~ip[3] && ~ip[4]) begin: one a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b1; g=1'b1; end else if(~ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4]) begin: two a=1'b0; b=1'b0; c=1'b1; d=1'b0; e=1'b0; f=1'b1; g=1'b0; end else if(ip[0] &&ip[1] && ~ip[2] && ~ip[3] && ~ip[4]) begin: three a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b1; f=1'b1; g=1'b0; end else if(~ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: four a=1'b1; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b0; g=1'b0; end else if(ip[0] && ~ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: five a=1'b0; b=1'b1; c=1'b0; d=1'b0; e=1'b1; f=1'b0; g=1'b0; end else if(~ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: six a=1'b0; b=1'b1; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] &&ip[1] &&ip[2] && ~ip[3] && ~ip[4]) begin: seven a=1'b0; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b1; g=1'b1; end else if(~ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4]) begin: eight a=1'b0; b=1'b0; c=1'b0; d=1'b0; e=1'b0; f=1'b0; g=1'b0; end else if(ip[0] && ~ip[1] && ~ip[2] &&ip[3] && ~ip[4])
  • 9. 71 begin: nine a=1'b0; b=1'b0; c=1'b0; d=1'b1; e=1'b1; f=1'b0; g=1'b0; end else begin: null a=1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b1; f=1'b1; g=1'b1; end end else begin =1'b1; b=1'b1; c=1'b1; d=1'b1; e=1'b1; f=1'b1; g=1'b1; end end endmodule
  • 10. 72 Verification: Simulation: The process of verification of functional correctness of the written code is called simulation The above code is simulated and verified in the Xilinx Vivado design suite 14.2 for the exact output. It needs an additional test bench to be written for the purpose of verification in which we predefine the values. Synthesis: The process of mapping the implemented code onto a real world device is known as synthesis. This is again done by the software After the functional verification we have dumped the code into the hardware kit, Nexys 4 DDR to verify the results on the seven segment display available on the kit Output The result of the above written code is as shown below: Simulated output:
  • 11. 73 Synthesized output When i/p is 1001010 output represented as J When i/p is 01100001 output represented as a When i/p is 0000000 output represented as 0 When i/p is 0000111output represented as 7
  • 12. 74 Drawbacks: In the above seven segmented display we cannot display few letters accurately for user understanding, the user has to compromise between some letters such as W,X,K etc. Conclusion: The implementation of ASCII code to alphanumeric seven segment display has been performed in the Vivado design suite and the simulated output is verified. The Synthesized output has been performed and observed on the Xilinx Nexys 4 DDR FPGA kit and the sample kit picture has been added to the project report.
  • 13. 75