This preview shows page 1. Sign up to view the full content.
Unformatted text preview: simplest, but suffers from a variable conversion time proportional to the input signal magnitude. The tracking ADC is the fastest converter, as long as no rapid changes in the input signal level occur. The overall best choice is the successive approximation ADC, with a constant and known conversion time. Lab 9 Library VIs (Listed in the Order Presented) SAR.vi (successive approximation register ADC) SAR0.vi (SAR ADC slow version for observing the conversion process) SAR_Hex.vi (SAR ADC with a hexadecimal input) Fundamentals of Digital Electronics 9-4 National Instruments Corporation Lab 10 Seven-Segment Digital Displays
Digital displays link the digital world of ones and zeros with numerics of the human world. You have seen how parallel combinations of ones and zeros can represent binary, hexadecimal, or digital numbers. For most simple instruments, digital displays use the numbers 0-9 and are represented by seven segmented displays. Each segment is controlled by a single bit, and combinations of segments turned ON or OFF can display all the numbers 0-9 and a few characters, such as A, b, c, d, E, and F. Seven-Segment Display
The LED seven-segment display uses seven individual light emitting diodes, configured as the number 8 in the pattern shown below: a f b g e d c Figure 10-1. Seven-Segment Display Uses Seven LED Bars The individual segments are coded a, b, c, d, e, f, and g and are ordered clockwise, with the last segment (g) as the central bar. When an LED is forward biased, light is emitted. By shaping the LED as a horizontal or vertical bar, a segment can be formed. Many output devices such as computer parallel ports are 8 bits wide. An eighth diode in the shape of a dot is available on some seven-segment displays to indicate a decimal point. National Instruments Corporation 10-1 Fundamentals of Digital Electronics Lab 10 Seven-Segment Digital Displays Run the VI 7 Segment.vi, which is a LabVIEW simulation for a seven-segment display. Try different combinations of the switches. How many characters in the alphabet can you display? Figure 10-2. LabVIEW Simulation of a Seven-Segment Display The input bits 0-7 are represented by eight Boolean switches. The corresponding segments in the seven-segment display are traditionally labeled a to g and dp (decimal place). The least significant bit 0 is wired to segment a, the next bit 1 is wired to segment b, etc. The most significant port bit, bit 7, is often wired to an eighth LED and used as a decimal point. By operating the switches, you can display all the numbers and a few characters. After experimenting with the display, try outputting the message "help call 911" one character at a time. Most seven-segment displays are driven with an encoder that converts a binary encoded nibble into a numeric number, which in turn selects the appropriate seven-segment code. The first step in a LabVIEW simulation is to convert the 4-bit binary nibble into a number from 0 to 15. The VI named Bin->Digit.vi simulates this task. Figure 10-3. Front Panel of the 4-Bit Binary-to-Digit Conversion Program Fundamentals of Digital Electronics 10-2 National Instruments Corporation Lab 10 Seven-Segment Digital Displays On the block diagram, a 4-bit digital-to-analog converter completes the operation. Figure 10-4. LabVIEW VI for a 4-Bit Digital-to Analog Converter The next step is to convert the digit(s) 0 to 15 into the appropriate seven-segment display. For the numbers 10 to 15, a single hexadecimal character [A to F] is used. In Encoder Hex.vi, multiple case statements are used to provide the encoder function. The Case terminal ? is wired to a numeric control formatted to select a single integer character. The number 0 outputs the seven-segment code for zero, number 1 outputs the code for 1, etc., all the way to F. The Boolean constants inside each Case statement are initialized to generate the correct seven-segment code. Figure 10-5. LabVIEW VI for Numeric-to-Seven-Segment Display The hexadecimal number inside the square box is the hexadecimal representation for the 8-bit pattern necessary to represent the number, #n. Each port has a unique address that must be selected before data can be written to or read from the real world. The correct address must be entered National Instruments Corporation 10-3 Fundamentals of Digital Electronics Lab 10 Seven-Segment Digital Displays on the front panel to access the port. In this simulation, the address operates the run command. Figure 10-6. Hexadecimal-to-Seven-Segment Display Encoder and Indicator Select the port address 1 and run Encoder.vi. With the Operating tool, click on the slider and drag it along the range of numbers, 0 to 15. You can see all numbers encoded as a seven-segment hexadecimal character. These two VIs, Bin->Digit.vi and Encoder.vi, can be combined to form a binary-to-seven-segment encoder and display. 4 binary 16 line encoder 16 7 segment encoder driver Figure 10-7. Symbolic Diagram of a Binary-to-Seven-Segment Display Circuit In general, the input would be a 4-bit binary num...
View Full Document
- Spring '09