7-Segment Displays - PowerPoint PPT Presentation

About This Presentation
Title:

7-Segment Displays

Description:

7-Segment Displays Lecture L6.7 Section ... Turning on an LED Turning on an LED 7-Segment Display 7-Segment Display 7 ... [aa,bb,cc,dd,ee,ff,gg] PIN 15,18,23,21,19,14 ... – PowerPoint PPT presentation

Number of Views:188
Avg rating:3.0/5.0
Slides: 13
Provided by: oak83
Category:

less

Transcript and Presenter's Notes

Title: 7-Segment Displays


1
7-Segment Displays
  • Lecture L6.7
  • Section 6.5

2
Turning on an LED
3
Turning on an LED
This is what we use in Lab
4
7-Segment Display
5
7-Segment Display
a b c d e f g 0 1 1 1 1 1 1 0 1 0 1 1 0 0 0
0 2 1 1 0 1 1 0 1 3 1 1 1 1 0 0 1 4 0 1 1 0 0
1 1 5 1 0 1 1 0 1 1 6 1 0 1 1 1 1 1 7 1 1 1 0
0 0 0
6
7-Segment Display
a b c d e f g 8 1 1 1 1 1 1 1 9 1 1 1 1 0 1
1 A 1 1 1 0 1 1 1 b 0 0 1 1 1 1 1 C 1 0 0 1 1
1 0 d 0 1 1 1 1 0 1 E 1 0 0 1 1 1 1 F 1 0 0 0
1 1 1
7
K-Map for Segment e
e D3 D2 !D2 !D0 D3 D1 D1 !D0
D1 D0
00
01
11
10
D3 D2
1
1
00
01
1
11
1
1
1
1
10
1
1
1
8
hex7seg.abl
MODULE hex7seg INTERFACE (D3..D0 -gt
a,b,c,d,e,f,g) TITLE 'hex to seven segment
display decoder' " a " ---
hex-to-seven-segment decoder " f g b " ---
" e d c " --- DECLARATIONS   " Input Pins
" D3..D0 PIN " display input value D
D3..D0 " 4-bit input vector   " Output
Pins " a,b,c,d,e,f,g PIN ISTYPE 'com' "
output values   " Definitions " ON,OFF 1,0
" for common cathode LEDs
9
EQUATIONS   _at_radix 16 truth_table (D -gt a , b
, c , d , e , f , g ) 0 -gt
ON, ON, ON, ON, ON, ON, OFF 1
-gt OFF, ON, ON, OFF, OFF, OFF, OFF
2 -gt ON, ON, OFF, ON, ON, OFF, ON
3 -gt ON, ON, ON, ON, OFF, OFF,
ON 4 -gt OFF, ON, ON, OFF, OFF,
ON, ON 5 -gt ON, OFF, ON, ON,
OFF, ON, ON 6 -gt ON, OFF, ON,
ON, ON, ON, ON 7 -gt ON, ON,
ON, OFF, OFF, OFF, OFF 8 -gt ON,
ON, ON, ON, ON, ON, ON 9 -gt
ON, ON, ON, ON, OFF, ON, ON
0A -gt ON, ON, ON, OFF, ON, ON, ON
0B -gt OFF, OFF, ON, ON, ON, ON, ON
0C -gt ON, OFF, OFF, ON, ON, ON,
OFF 0D -gt OFF, ON, ON, ON, ON,
OFF, ON 0E -gt ON, OFF, OFF, ON,
ON, ON, ON 0F -gt ON, OFF, OFF,
OFF, ON, ON, ON   END hex7seg
hex7seg.abl (cont.)
10
MODULE main7seg TITLE 'hex to seven segment
display decoder'   DECLARATIONS hex7seg
INTERFACE(D3..D0 -gt a,b,c,d,e,f,g) d7L
FUNCTIONAL_BLOCK hex7seg d7R FUNCTIONAL_BLOCK
hex7seg   " Input Pins " L3..L0 PIN 11,7,6,5 "
Left Switches S6 - 1..4 L L3..L0 " 4-bit
input vector   R3..R0 PIN 4,3,2,1 " Right
Switches S7 - 1..4 R R3..R0 " 4-bit input
vector   " Output Pins " a,b,c,d,e,f,g PIN
57,58,61,62,63,65,66 ISTYPE 'com'
"Leftmost (tens) 7-segment LED
display   aa,bb,cc,dd,ee,ff,gg PIN
15,18,23,21,19,14,17 ISTYPE 'com' "
Rightmost (units) 7-segment LED
display   EQUATIONS   a,b,c,d,e,f,g
d7L.a,b,c,d,e,f,g d7L.D3..D0
L aa,bb,cc,dd,ee,ff,gg d7R.a,b,c,d,e,f,g d
7R.D3..D0 R   END main7seg
main7seg.abl
11
MODULE main7seg TITLE 'hex to seven segment
display decoder' DECLARATIONS hex7seg
INTERFACE(D3..D0 -gt a,b,c,d,e,f,g) d7L
FUNCTIONAL_BLOCK hex7seg d7R FUNCTIONAL_BLOCK
hex7seg " Input Pins " L3..L0 PIN 11,7,6,5 "
Left Switches S6 - 1..4 L L3..L0 " 4-bit
input vector R3..R0 PIN 4,3,2,1 " Right
Switches S7 - 1..4 R R3..R0 " 4-bit input
vector
12
" Output Pins " a,b,c,d,e,f,g PIN
57,58,61,62,63,65,66 ISTYPE 'com'
"Leftmost (tens) 7-segment LED
display aa,bb,cc,dd,ee,ff,gg PIN
15,18,23,21,19,14,17 ISTYPE 'com' "
Rightmost (units) 7-segment LED
display EQUATIONS a,b,c,d,e,f,g
d7L.a,b,c,d,e,f,g d7L.D3..D0
L aa,bb,cc,dd,ee,ff,gg d7R.a,b,c,d,e,f,g d
7R.D3..D0 R END main7seg
Write a Comment
User Comments (0)
About PowerShow.com