π Lecture 19 β Demultiplexer
π Overview: This lecture introduces the Demultiplexer, a circuit that routes a single input to one of several outputs, and explores its applications such as ALU data routing and serial-to-parallel conversion. It then transitions into Programmable Logic Devices (PLDs), explaining their architecture based on programmable AND and OR arrays, and detailing the four main types: PROM, PLA, PAL, and GAL, including their programming and output configurations.
ποΈ Topics Covered
The lecture begins with the definition, circuit, and operation of a 1-to-4 Demultiplexer, comparing it to a decoder. It then covers two key applications: connecting an ALU output to registers and converting serial data to parallel. The second half introduces Programmable Logic Devices, their grid-based array structure with fusible links, and classifies them into PROM, PLA, PAL, and GAL. Finally, it details PAL circuit simplification, output types (combinational, I/O, programmable polarity), identification numbering, and provides a complete example of programming a 4 x 3 PLA device.
π Lecture Summary
Demultiplexer
A Demultiplexer (also called a Data Distributor) performs the opposite function of a Multiplexer. It has a single input and several outputs. The Demultiplexer selects one of the several outputs and routes the data at the single input to the selected output.
The circuit of a 1-to-4 Demultiplexer is very similar to a 2-to-4 Binary Decoder. The only difference is that the Decoder's enable input is used as the Demultiplexer's Data Input. With select inputs Iβ and Iβ set to 1 and 0, the Oβ output equals the Data input (1 if Data=1, 0 if Data=0). A Demultiplexer is not available as a standalone chip commercially; it is available as a Decoder/Demultiplexer chip that can be configured for either function.
Applications of Demultiplexer
First Application: ALU Output Routing The Demultiplexer is used to connect a single source to multiple destinations. At the output of an ALU circuit, the result must be stored in one of several registers. The Data input of the Demultiplexer is connected to the ALU output, and each Demultiplexer output is connected to a different register. By selecting the appropriate output, data from the ALU is routed to the correct register for storage.
Second Application: Serial to Parallel Converter The Demultiplexer reconstructs parallel data from an incoming serial data stream. Serial data arrives at the Data input at fixed time intervals. A counter attached to the Select inputs routes each incoming serial bit to successive outputs, where each bit is stored. When all bits have been stored, the data can be read out in parallel.
Programmable Logic Devices
Programmable Logic Devices (PLDs) are used to replace Logic gates and MSI chips, saving circuit space and reducing component cost. PLDs consist of arrays of AND gates and OR gates that can be programmed to perform specific functions.
Programmable Arrays of AND Gates and OR Gates
The array is a grid of conductors forming rows and columns, with a fuse connecting each column conductor to each row conductor. Fuses can be blown to disconnect a column from a row. Each column conductor represents a single variable or its complement. Each OR and AND gate is connected to each variable through horizontal conductors. When all fuses are intact, all variables are present at all gate inputs. Gates are configured by blowing away fuses.
An alternate implementation uses no fuses; instead, a specific column conductor is connected to a row conductor by shorting them. Both methods (blowing fuses or shorting) can only be done once, so the array cannot be reprogrammed.
PLDs are classified by their architecture, which determines whether one or both arrays are programmable:
- Programmable Read-Only Memory (PROM): Has a fixed (non-programmable) AND array configured as a decoder and a programmable OR array. Used as a storage device, not as a logic device.
- Programmable Logic Array (PLA): Has a programmable AND array and a programmable OR array. Also known as a Field-Programmable Logic Array (programmed by the user).
- Programmable Array Logic (PAL): Has a programmable AND array and a fixed OR array. Designed to overcome longer delays and complex circuitry of the PLA.
- Generic Array Logic (GAL): Has a reprogrammable AND array and a fixed OR array with programmable output logic. Uses EΒ²CMOS technology (Electrically Erasable CMOS) instead of bipolar technology and fusible links.
All four PLD types use AND arrays followed by OR arrays, allowing implementation of Sum-of-Product (SOP) Boolean expressions.
PAL Circuit and Programming
A simplified PAL structure shows the AND array programmed to generate three product terms, which are added by the OR array. Because PALs have many inputs and outputs, circuit diagrams are simplified: input buffers produce the variable and its complement, multiple input lines to an AND gate are represented by a single line with a slash indicating the number of inputs, and crosses indicate fuses that are intact (connections).
PAL Outputs
PALs typically have 8 or more inputs and 8 or fewer outputs. Some have combined inputs and outputs programmable as either. The three output types are:
- Combinational Output: Used for an SOP function, available as active-high or active-low. Implemented by activating a tri-state buffer which inverts the OR gate output and passes it to the PAL output.
- Combinational Input/Output: Used when the output connects back to the PAL input or when the pin is used as an input. The tri-state buffer output connects to inverting and non-inverting buffers to feed the AND array. Deactivating the tri-state buffer configures the pin as an input.
- Programmable Polarity Output: Uses an XOR gate at the output. When the XOR's second input is grounded (fuse intact), output equals OR gate output. When the fuse is blown to set the input to logic high, the XOR inverts the OR gate output.
PAL Identification
PALs are identified by a unique number: prefix PAL, followed by two digits for the number of inputs, a letter (L for active-low, H for active-high, P for programmable polarity), and one or two digits for the number of outputs. Suffixes specify speed, package type, and temperature range. π Definition β PAL 10L8: A PAL with 10 inputs, 8 outputs, and active-low outputs.
PLA Circuit and Programming
A PLA has programmable AND and OR arrays and can implement any SOP expression, limited by:
- Number of inputs (n)
- Number of outputs (m)
- Number of product terms (p) Such a device is described as an n x m PLA device with p product terms.
π Formula: For a 4 x 3 PLA with 6 AND gates (product terms P1-P6) and 3 OR gates:
- Each AND gate has 8 inputs (4 variables and their complements).
- Each OR gate has 6 inputs (summing up to 6 product terms).
π Example: A programmed 4 x 3 PLA generates the following product terms: Pβ = IβΒ·IβΒ·Iβ Pβ = IβΒ·IβΒ·Iβ Pβ = IβΒ·IβΒ·IβΒ·Iβ Pβ = IβΒ·IβΒ·Iβ Pβ = IβΒ·Iβ Pβ = IβΒ·IβΒ·IβΒ·Iβ
The three output sum-of-product expressions are: Oβ = Pβ + Pβ + Pβ + Pβ = IβΒ·IβΒ·Iβ + IβΒ·IβΒ·Iβ + IβΒ·IβΒ·IβΒ·Iβ + IβΒ·Iβ Oβ = Pβ + Pβ + Pβ = IβΒ·IβΒ·Iβ + IβΒ·IβΒ·Iβ + IβΒ·IβΒ·IβΒ·Iβ Oβ = Pβ + Pβ + Pβ + Pβ = IβΒ·IβΒ·Iβ + IβΒ·IβΒ·IβΒ·Iβ + IβΒ·IβΒ·Iβ + IβΒ·IβΒ·IβΒ·Iβ
β Key Takeaways
The Demultiplexer is a data distributor that routes one input to one of several outputs, functioning like a decoder with the enable line replaced by a data input. Its key applications include routing ALU outputs to registers and converting serial data to parallel data. Programmable Logic Devices (PLDs) use programmable arrays of AND and OR gates to implement Sum-of-Product logic, with four main types: PROM (fixed AND, programmable OR), PLA (both programmable), PAL (programmable AND, fixed OR), and GAL (reprogrammable AND, fixed OR with programmable output). PAL outputs can be configured as combinational, input/output, or programmable polarity. The size of a PLD is described by its number of inputs, outputs, and product terms, and PALs are identified by a standard numbering system (e.g., PAL10L8).
π§ Quick Revision Questions
- How does a 1-to-4 Demultiplexer circuit differ from a 2-to-4 Decoder circuit?
- Describe how a Demultiplexer can be used as a serial-to-parallel converter. What component controls the select inputs?
- What are the four main types of Programmable Logic Devices, and how do their AND/OR array configurations differ?
- In a PAL, what are the three types of output configurations, and how does a programmable polarity output using an XOR gate work?
- For a programmed 4 x 3 PLA, if the product terms are Pβ=IβΒ·Iβ, Pβ=IβΒ·Iβ, and Pβ=IβΒ·Iβ, and Oβ sums Pβ+Pβ, Oβ sums Pβ+Pβ, and Oβ sums Pβ+Pβ, what are the three Boolean output expressions?
π Lecture 20 β Implementing Constant 0s and 1s
π Overview: This lecture explores how Programmable Logic Arrays (PLAs) can be programmed to produce constant 0 or 1 outputs, and how they implement functions like Odd-Prime Number detection. It then introduces GAL (Generic Array Logic) architecture, its reprogrammable AND array, Output Logic Macro Cells (OLMCs), and programming methods including the GAL22V10 and the ABEL hardware description language.
ποΈ Topics Covered
The lecture covers implementing constant 0s and 1s using PLAs, implementing the Odd-Prime Number function in a 4Γ3 PLA, GAL operation including EΒ²CMOS reprogrammable cells and OLMCs, the GAL22V10 architecture with its ten OLMCs and various configurations, tri-state buffers and their use, programming GAL22V10 for Boolean functions, and an introduction to ABEL (Advanced Boolean Expression Language) for PLD programming.
π Lecture Summary
IMPLEMENTING CONSTANT 0S AND 1S
The PLA can output constant 0 or 1. When all four inputs and their complements are connected to the first AND gate, the product term generated is 0 (P1 = 0). This is connected to the first OR gate, giving an output of 0. When inputs to the second AND gate are disconnected, the product term is 1 (P2 = 1), connected to the second OR gate, giving output 1. When no product term is connected to the third OR gate, its output is 0.
π Definition β Constant 0/1 in PLA: Connecting all literals to an AND gate produces product term 0; disconnecting all inputs produces product term 1. π Formula: P = 0 (all inputs connected) β P = 1 (all inputs disconnected) π Example: In a 4Γ3 PLA, first AND gate with all four inputs connected gives P1 = 0 β OR1 output = 0; second AND gate with no inputs gives P2 = 1 β OR2 output = 1; third OR gate with no product terms gives output = 0.
Implementing Odd-Prime Number Function
The Odd-Prime Number generator is implemented in a 4Γ3 PLA with six product terms (six AND gates). Due to limitations, only the first six Odd-Prime numbers 1, 3, 5, 7, 11, and 13 can be detected. The six product terms P1βP6 represent minterms 1, 3, 5, 7, 11, and 13. The first OR gate sums all six minterms to output 1 when any of these Odd-Prime numbers appears at inputs I1βI4. The second OR gate sums minterms 1, 3, and 5. The third OR gate sums minterms 1, 3, and 13.
GAL Operation
GAL has a reprogrammable AND gate array and a fixed OR array. Instead of fuses, EΒ²CMOS logic is used, which can be programmed to connect a column with a row. The EΒ²CMOS cell at each columnβrow intersection is known as a cell. A cell in the βonβ state connects the column with the row; a cell in the βoffβ state disconnects them.
A typical GAL has eight or more inputs to the reprogrammable AND array and eight or more input/outputs from its Output Logic Macro Cells (OLMCs). OLMCs can be programmed for Combinational Logic (for combinational circuits) or Registered Logic (for sequential circuits).
GALs are identified by a prefix GAL followed by a 2-digit number indicating inputs, then V for variable output configuration, followed by a number indicating the number of outputs. Example: GAL16V8 means 16 inputs, 8 outputs, variable configuration.
Programming of PLDs
PLDs are programmed with a computer running programming software, connected to a programmer socket. PLDs can also be programmed when installed on a circuit board (In-System Programming or ISP). The process involves entering the logic function as a Boolean equation, truth table, or state diagram. The software compiler processes and minimizes the logic, then tests it using test vectors (hypothetical inputs). After testing, a fuse map file is produced and downloaded to the programmer. ISP uses a standard 4-wire interface, allowing systems to be upgraded by reprogramming.
The GAL22V10
The GAL22V10 has twelve inputs and ten inputs/outputs, available as a low-voltage 3.3V version and an ISP version. It has ten OLMCs that receive different numbers of inputs from the programmable AND array: two OLMCs have 8 inputs, two have 10 inputs, two have 12 inputs, two have 14 inputs, and two have 16 inputs. Each OLMC can be programmed for active-high or active-low output, or as an input.
An OLMC contains a flip-flop (a sequential logic device storing the OR gate output). The output and complemented output of the flip-flop connect to two inputs of a 4-to-1 MUX. The remaining two MUX inputs come from the OR gate output and its complement. The MUX output drives a tri-state buffer. The output also connects to a 2-to-1 MUX, with the other input from the flip-flopβs complemented output. Select inputs Sβ and Sβ select appropriate routing.
The four OLMC configurations are:
- Combinational Mode with active-low output
- Combinational Mode with active-high output
- Registered Mode with active-low output
- Registered Mode with active-high output
OLMC Combinational Mode
When Sβ = 0 and Sβ = 1, the 4-to-1 MUX selects the OR gate output; the output is active-low due to inversion by the tri-state buffer. When Sβ = 1 and Sβ = 1, the MUX selects the complement of the OR gate output; the output is active-high due to double inversion.
Tri-State Buffers
A Tri-State Buffer is a NOT gate with a control line that disconnects the output from the input. When the control line is high, the buffer operates like a NOT gate. When the control line is low, the output is disconnected and high impedance is seen at the output. Tri-state buffers disconnect outputs of devices sharing a common output line.
Referring to the OLMC logic circuit: when the control input to the tri-state buffer is low, the output is set to high impedance, disconnecting the OLMC from the output pin, allowing the output pin to be used as an input pin.
The GAL22V10 Array
The GAL22V10 has 22 inputs organized as 44 lines (one for each input and its complement). Each AND gate has 44 inputs connected to these 44 input lines. The first OLMC has ten input product terms: eight connected to the OR gate, one to control the tri-state buffer, and one for reset in Registered mode for all OLMCs. Each OLMC ORs the product terms to give a single sum of product term. With ten OLMCs, a total of ten Sum-of-Product terms can be implemented.
Programming the GAL22V10
The GAL22V10 can be programmed for Boolean functions. For a six-variable function X = ABCDEF + ABCDEF + ABCDEF + ABCDEF + ABCDEF + ABCDEF + ABCDEF, the six variables connect to six inputs. The first group of four vertical lines represents variable A and its complement; the remaining two lines receive un-complemented and complemented output from the OLMC. The Boolean expression has seven product terms. The first OLMC has eight input product terms, so it can program the expression. The output of the first AND gate generates the first product term, and the 2ndβ7th AND gates generate the remaining six. The eight-input OR gate generates the sum of product terms. The last group of vertical lines controls the tri-state buffer; it is set high to connect the OLMC output to the GAL output pin.
π‘ Why this matters: Understanding how to program GALs with specific Boolean functions enables efficient implementation of complex logic in a single chip.
Introduction to ABEL
ABEL (Advanced Boolean Expression Language) is a hardware description language used for implementing logic designs using PLDs. ABEL is a device-independent language that can program any type of PLD. ABEL runs on a computer connected to a PLD programmer. ABEL provides three text-based methods for describing and entering a logic design:
- Boolean Equations
- Truth Tables
- State Diagrams
Boolean Equations and Truth Tables are used for Combinational Logic Circuits. State Diagrams are used specifically for Sequential Logic Circuits. Boolean Equations and Truth Tables can also be used for describing Sequential Logic Circuits.
β Key Takeaways
The most critical points from this lecture are: PLAs can generate constant 0 or 1 outputs by connecting all inputs (P=0) or disconnecting all inputs (P=1). The GAL architecture uses reprogrammable EΒ²CMOS cells in an AND array with fixed OR array, where OLMCs can be configured for combinational or registered logic with active-high or active-low outputs. The GAL22V10 has 22 inputs (44 lines), ten OLMCs, and can implement ten Sum-of-Product terms, with tri-state buffers controlled by dedicated product terms. ABEL provides Boolean equations, truth tables, and state diagrams for PLD programming, with device-independent capability.
π§ Quick Revision Questions
- How can a PLA be programmed to output a constant 1?
- What are the six Odd-Prime numbers that can be detected by a 4Γ3 PLA with six product terms?
- What is the difference between combinational mode and registered mode in an OLMC?
- How does a tri-state buffer function, and what is its purpose in an OLMC?
- What are the three text-based methods provided by ABEL for describing logic designs?
π Lecture 21 β The GAL16V8
π Overview: This lecture covers the architecture and programming modes of the GAL16V8, a programmable logic device that can emulate most PALs. It introduces the ABEL hardware description language for implementing logic designs using Boolean equations, truth tables, and test vectors. This is foundational for understanding how to program PLDs in both combinational and sequential logic applications.
ποΈ Topics Covered
The lecture first examines the GAL16V8 architecture including its eight inputs, eight input/output pins, and OLMC structure with tri-state buffer control and feedback possibilities. It then explains the three programming modes: Simple Mode (combinational output, feedback, dedicated input), Complex Mode (combinational output and input/output with programmable tri-state control), and Registered Mode (sequential logic). The second half introduces ABEL as a hardware description language, covering Boolean equation notation, truth table representation, test vectors, and the structure of ABEL input files including declarations, logic descriptions, and documentation outputs.
π Lecture Summary
The GAL16V8
The GAL16V8 is a programmable device with eight inputs, two special function input pins, and eight pins configurable as inputs or outputs. Its architecture is similar to a PAL and it can be programmed in three modes: Simple, Complex, and Registered. The Simple and Complex modes are for Combinational Logic, while the Registered mode is for Sequential Logic.
The GAL16V8 has eight OLMCs (Output Logic Macro Cells), each connected to eight product terms. Each product term uses a 32-bit input AND gate, where the 32 inputs come from 16 complemented/un-complemented inputs of the 8 input pins and 16 complemented/un-complemented inputs of the 8 input/output pins.
OLMC for GAL16V8
The OLMC of the GAL16V8 is similar to the GAL22V10 with enhancements. Key aspects include:
Tri-state Buffer and OLMC output pin: The tri-state buffer connecting the OLMC output to the output pin is controlled through four different sources:
- Connected to Vcc β output is always enabled
- Connected to GND β output disabled, pin configured as input
- Connected to external pin (11) β controlled externally by Vcc or GND
- Connected to output of one of the eight AND gates β controlled by a logical expression
The feedback from the OLMC to the AND Gate array input: The OLMC can provide feedback in three ways:
- Feedback signal line to the output of the OLMC β allows Sequential Logic circuits
- Feedback signal line to the output of the adjacent OLMC β also allows Sequential Logic
- Feedback signal line to a flip-flop β allows synchronized Sequential circuits
The output of the Sum of Product term: The OR gate output connects to the output pin through the tri-state buffer, which also connects to the flip-flop output. Either input can be selected. The OR gate output can be programmed for output polarity by configuring the XOR gate connected at the OR gate output.
Simple Mode
In the Simple Mode, the OLMC is configured as dedicated active combinational output or as dedicated input (limited to six). Three combinations exist:
Combinational Output (Figure 21.1): The OLMC gives an output that is either active-low or active-high, determined by the XOR input. The tri-state buffer control pin is set to logic high by connecting it to Vcc. The Sum-of-Product term has eight product terms.
Combinational Output with feedback to AND array (Figure 21.2): Similar to above, but the output signal connects back to the AND array input through a buffer providing inverting and non-inverting outputs. This feedback capability is limited to six OLMCs. OLMCs connected to input/output pins 15 and 16 do not have the feedback path, so they cannot be programmed with this configuration.
Dedicated Input (Figure 21.3): The tri-state buffer is configured in high impedance state by setting the control pin to low (GND). The output pin connects to an input signal passed to the AND Array input in complemented and un-complemented form by the buffer.
Complex Mode
In the Complex Mode, the tri-state control is formed by a logical expression, leaving seven product terms for the sum-of-product expression. Two combinations exist:
Combinational Output (Figure 21.4): The tri-state buffer is enabled by connecting the control input to the output of one of the AND gates, so the buffer is controlled by programming a product term.
Combinational Input/Output (Figure 21.5): Also implemented by connecting the tri-state buffer control input to the AND gate output. Only OLMCs with the feedback path connecting the output to the AND gate array input can be used in this mode.
Introduction to ABEL
ABEL (Advanced Boolean Expression Language) is a hardware description language for implementing logic designs using PLDs. It is device-independent and can program any type of PLD. ABEL runs on a computer connected to a PLD programmer.
ABEL provides three text-based methods for describing logic designs:
- Boolean Equations β for Combinational Logic circuits
- Truth Tables β for Combinational Logic circuits
- State Diagrams β specifically for Sequential Logic circuits
Boolean Equations and Truth Tables can also be used for Sequential Logic circuits.
Boolean Operations and Boolean Notations
ABEL uses special symbols for logic operations:
| Logic Operation | ABEL Symbol |
|---|---|
| NOT | ! |
| AND | & |
| OR | # |
| XOR | $ |
Table 21.1 ABEL Symbols for logic operations
The operators have precedence in the order: !, &, #, $
| Boolean Notation | ABEL Notation |
|---|---|
| A | A |
| !A | !A |
| AΒ·B | A&B |
| A + B | A#B |
| A β B | A$B |
Table 21.2 Boolean and equivalent ABEL Notations
Boolean Equations: Any letter or combination of letters and numbers can identify variables. ABEL is case-sensitive (variable 'A' β variable 'a'). All ABEL equations must end with ';'.
π Formula: Boolean expression F = AB + AC + BD β ABEL expression F = A & !B # A & C # !B & !D;
π Definition β Case-sensitive: ABEL treats uppercase and lowercase letters as different variables.
Multiple Inputs and Outputs
Multiple input and output variables can be grouped as a set to simplify equations. For example, D0, D1, and D2 can be defined as: D = [D0, D1, D2];
For a 4-input 4-bit Multiplexer:
| Select Inputs | Outputs |
|---|---|
| S1 S0 | Y3 Y2 Y1 Y0 |
| 0 0 | A3 A2 A1 A0 |
| 0 1 | B3 B2 B1 B0 |
| 1 0 | C3 C2 C1 C0 |
| 1 1 | D3 D2 D1 D0 |
Table 21.3 Truth Table of 4-input 4-bit MUX
π‘ Why this matters: Using sets dramatically reduces the amount of code needed to describe complex circuits.
The ABEL notation can be simplified by defining sets:
A = [A3, A2, A1, A0];
B = [B3, B2, B1, B0];
C = [C3, C2, C1, C0];
D = [D3, D2, D1, D0];
Y = [Y3, Y2, Y1, Y0];
S = [S1, S0];
Y = (S = = 0) & A # (S = = 1) & B # (S = = 2) & C # (S = = 3) & D;
The '= =' is a relational operator.
Truth Table
ABEL accepts logic designs described as Truth Tables. The format includes a header and entries:
TRUTH_TABLE ( [A, B, C, D] β [X1, X2])
XOR Gate example:
TRUTH_TABLE ( [A, B] β [X])
[0, 0] β [0];
[0, 1] β [1];
[1, 0] β [1];
[1, 1] β [0];
Figure 21.10 ABEL representation of the Truth table of an XOR gate
2-bit Comparator example:
TRUTH_TABLE ( [A1, A0, B1, B0] β [G, E, L] )
[0, 0, 0, 0] β [0, 1, 0];
[0, 0, 0, 1] β [0, 0, 1];
...
Figure 21.11 ABEL representation of the Truth table of a 2-bit Comparator
The notation can be simplified by defining a set:
INPUT = [A1, A0, B1, B0];
TRUTH_TABLE ( INPUT β [G, E, L] )
0 β [0, 1, 0];
1 β [0, 0, 1];
...
Figure 21.12 ABEL representation using a set
Test Vectors
Test Vectors are used to verify the logic circuit design's operation. They specify inputs and corresponding outputs. The software simulates the circuit by applying the test vector and checking outputs. Test vectors are essentially the same as Truth Tables.
TEST_VECTORS ( [A1, A0, B1, B0] β [G, E, L] )
[0, 0, 0, 0] β [0, 1, 0];
[0, 0, 0, 1] β [0, 0, 1];
...
Figure 21.13 Test Vector of a 2-bit Comparator
The ABEL Input File
An ABEL input (source) file creates a module with three sections:
1. Declarations: Includes device declaration, pin declarations, and set declarations.
Decoder device 'P22V10';
A0, A1, A2, A3, PIN 1, 2, 3, 4;
INPUT = [A1, A0, B1, B0];
Figure 21.15 ABEL Input declarations
- 'Decoder' is a user-defined description
- 'device' is a reserved keyword (case-insensitive)
- 'P22V10' is the device name
- 'PIN' is a keyword (case-insensitive) defining variable-to-pin relationships
- 'INPUT' defines a set of elements
2. Logic Descriptions: Includes the three methods (Boolean equations, Truth Tables, State Diagrams).
3. Test Vectors: Used to simulate and verify the logic circuit.
The Documentation file
After processing an input file, ABEL generates a documentation file containing:
- Final reduced equations
- A JEDEC file
- A device pin diagram
The JEDEC file
The JEDEC file is downloaded to the PLD programmer to program the appropriate PLD device.
β Key Takeaways
The GAL16V8 is a versatile PLD that can operate in Simple, Complex, or Registered modes, with its OLMC providing flexible tri-state buffer control through four sources and three feedback options. Understanding the three programming modes is essentialβSimple mode for dedicated combinational or input functions, Complex mode for product-term-controlled tri-state buffers, and Registered mode for sequential circuits. ABEL is a powerful device-independent HDL that uses Boolean equations, truth tables, and state diagrams, with special symbols (!, &, #, $) for logic operations and sets for simplifying multiple variables. Test vectors function identically to truth tables for verifying circuit operation, and the ABEL input file structure (declarations, logic descriptions, test vectors) leads to a JEDEC file for programming the PLD.
π§ Quick Revision Questions
- What are the three programming modes of the GAL16V8, and which ones are associated with combinational versus sequential logic?
- What are the four possible sources for controlling the tri-state buffer in the GAL16V8 OLMC?
- In ABEL, what are the symbols for NOT, AND, OR, and XOR operations, and what is their order of precedence?
- How would you write an ABEL expression for the Boolean function F = A'BC + AB'C + ABC'?
- What are the three sections of an ABEL input file, and what is the purpose of the JEDEC file?
π Lecture 22 β ABEL INPUT FILE OF A QUAD 1-OF-4 MUX
π Overview: This lecture covers the design and implementation of a Quad 1-of-4 Multiplexer using ABEL input files and GAL20V8 devices. It then introduces sequential circuits by explaining why memory elements are essential, and provides a detailed analysis of S-R latches built with NAND and NOR gates, including their truth tables, timing diagrams, and active-low versus active-high behavior.
ποΈ Topics Covered
The lecture begins with the ABEL input file structure for a Quad 1-of-4 MUX, defining its pins, equations, and test vectors. It then explains why sequential circuits are needed due to the limitations of combinational logic lacking storage. Next, it focuses on latches as basic memory elements, specifically the NAND gate based S-R latch and the NOR gate based S-R latch, analyzing all four input combinations for each. Finally, it covers truth tables and timing diagrams for both active-low and active-high latches.
π Lecture Summary
ABEL INPUT FILE OF A QUAD 1-OF-4 MUX
A Quad 1-of-4 MUX contains four separate multiplexers, each with four inputs and a single output. All four multiplexers share two common select inputs, S1 and S0. The function table shows that for each combination of select inputs, a specific group of data inputs (e.g., A0, B0, C0, D0 for S1=0, S0=0) is routed to the corresponding outputs (Aout, Bout, Cout, Dout).
π Definition β Quad 1-of-4 MUX: A single integrated circuit containing four independent 1-of-4 multiplexers, all sharing the same two select lines.
π Example β Function Table: When S1=0 and S0=0, outputs are: Aout = A0, Bout = B0, Cout = C0, Dout = D0. When S1=0 and S0=1, outputs become: Aout = A1, Bout = B1, Cout = C1, Dout = D1.
Implementation of Quad MUX
The Quad MUX uses a GAL20V8 PLD because it has enough pins: 12 inputs, 2 special function inputs, and 8 input/output pins. Four of the input/output pins are configured as inputs to handle the fourth multiplexer's data lines (D1, D2, D3) and the select input S0. Each multiplexer output is represented by a Sum-of-Product Boolean expression with four product terms, implemented using OLMCs (Output Logic Macrocells).
π Definition β GAL20V8: A programmable logic device with 20 pins, 12 dedicated inputs, and 8 bidirectional input/output pins, used here because the GAL16V8 lacks sufficient pins.
π Formula for Aout: Aout = !S1 & !S0 & A0 # !S1 & S0 & A1 # S1 & !S0 & A2 # S1 & S0 & A3 β Selects one of four A-inputs based on S1 and S0.
Sequential Circuits
Sequential circuits differ from combinational circuits because they include memory elements that can store data. Combinational circuits handle only instantaneous inputs and cannot store outputs, which limits their use. An ALU adding numbers 2, 3, 4, and 5 requires temporary storage for numbers and partial results. Similarly, parallel-to-serial and serial-to-parallel conversions need memory elements. A counter cannot count to the next value without storing the previous count.
π Definition β Sequential Circuit: A digital circuit that uses memory elements to store previous inputs or outputs, allowing it to have states and perform operations over time.
Latches and Flip-Flops
A latch is a temporary storage device with two stable states, having two inputs and two outputs: Q and its complement QΜ . The latch retains its state unless inputs change to set it to a new state.
The NAND gate based S-R (Set-Reset) Latch
This latch uses two cross-coupled NAND gates. The unconnected inputs are Set (S) and Reset (R). Analysis of all four input combinations:
- S=0, R=0: Both outputs become 1, making Q=1 and QΜ =1. This is invalid because Q and QΜ should be complements.
- S=0, R=1: Q is set to 1, QΜ is set to 0 (regardless of initial state).
- S=1, R=0: Q is set to 0, QΜ is set to 1 (regardless of initial state).
- S=1, R=1: The previous output state is maintained.
π Definition β NAND S-R Latch: A latch using two NAND gates where active-low inputs SΜ and RΜ set or reset the output, with S=0, R=0 being invalid.
π Example β S=0, R=1: If initial Q=1, QΜ =0, then S=0 forces Q to 1, and with Q=1 and R=1, gate 2 outputs QΜ =0. If initial Q=0, QΜ =1, S=0 forces Q to 1, and with Q=1 and R=1, gate 2 outputs QΜ =0. Result is always Q=1, QΜ =0.
| Input S | Input R | Output Q_(t+1) |
|---|---|---|
| 0 | 0 | invalid |
| 0 | 1 | 1 |
| 1 | 0 | 0 |
| 1 | 1 | Q_t |
π‘ Why this matters: The NAND latch has active-low inputs, meaning the set or reset action occurs when the input is logic 0.
The NOR gate based S-R (Set-Reset) Latch
This latch uses two cross-coupled NOR gates with S and R inputs switched compared to the NAND version. Analysis:
- S=0, R=0: The previous output state is maintained.
- S=0, R=1: Q is set to 0, QΜ is set to 1 (Reset action).
- S=1, R=0: Q is set to 1, QΜ is set to 0 (Set action).
- S=1, R=1: Both outputs become 0, making Q=0 and QΜ =0. This is invalid.
π Definition β NOR S-R Latch: A latch using two NOR gates where active-high inputs S and R set or reset the output, with S=1, R=1 being invalid.
| Input S | Input R | Output Q_(t+1) |
|---|---|---|
| 0 | 0 | Q_t |
| 0 | 1 | 0 |
| 1 | 0 | 1 |
| 1 | 1 | invalid |
π Example β S=1, R=0: If initial Q=1, QΜ =0, S=1 makes Q=0, then with Q=0 and R=0, gate 1 outputs QΜ =1. If initial Q=0, QΜ =1, S=1 makes Q=0, then with Q=0 and R=0, gate 1 outputs QΜ =1. Result is always Q=0, QΜ =1? No, wait: For case a, final Q=0, QΜ =1. For case b, final Q=0, QΜ =1. So Q=0, QΜ =1. When S=1 and R=0, the set action occurs, so Q should be 1, QΜ =0. Let's re-read: "setting S to 1 and R to 0 sets the Q and QΜ outputs to 1 and 0 respectively." So the example should show Q=1, QΜ =0 after S=1, R=0. The text confirms this.
π‘ Why this matters: The NOR latch has active-high inputs, meaning the set or reset action occurs when the input is logic 1.
S-R Latch Timing Diagrams
The timing diagram for the NAND based (active-low) latch shows that S=0 and R=0 are never applied. The timing diagram for the NOR based (active-high) latch shows that S=1 and R=1 are never applied. Both diagrams illustrate how changes in S and R inputs cause corresponding changes in the Q output over time.
β Key Takeaways
A Quad 1-of-4 MUX requires the GAL20V8 PLD due to its 22-pin requirement, with each multiplexer output implemented as a sum-of-products expression with four product terms. Sequential circuits are essential for all practical digital systems because they include memory elements that can store data, enabling operations like multi-number addition, parallel-to-serial conversion, and counting. The NAND gate based S-R latch has active-low inputs, where S=0 sets Q to 1 and R=0 resets Q to 0, and the input combination S=0, R=0 is invalid. The NOR gate based S-R latch has active-high inputs, where S=1 sets Q to 1 and R=1 resets Q to 0, and the input combination S=1, R=1 is invalid. Both latches maintain their output state when neither set nor reset is active, and never allow both set and reset to be active simultaneously.
π§ Quick Revision Questions
- Why is the GAL20V8 used instead of the GAL16V8 for implementing the Quad 1-of-4 MUX?
- What are the three input combinations for a NAND-based S-R latch and the corresponding output states?
- How does an active-high S-R latch differ from an active-low S-R latch in terms of input levels?
- Why is the input combination S=0, R=0 considered invalid for a NAND-based S-R latch?
- In a NOR-based S-R latch, what happens to the Q and QΜ outputs when S=1 and R=1 are applied?