Generic Array Logic
Generic Array Logic (GAL) is a family of electrically erasable and reprogrammable programmable logic devices (PLDs) developed by Lattice Semiconductor Corporation and introduced in 1985 as an advancement over the earlier Programmable Array Logic (PAL) technology.[1][2] These devices utilize E²CMOS (Electrically Erasable CMOS) technology, which allows for multiple reprogramming cycles—over 100—using electrical methods, making them ideal for prototyping, development, and small-scale logic designs that require flexibility without the need for replacement hardware.[1][3][4] The core architecture of GAL devices consists of a programmable AND array that generates product terms, feeding into a fixed OR array and configurable Output Logic Macrocells (OLMCs), which can be set to operate in modes such as registered, combinatorial, or simple output configurations to support diverse logic functions.[1][3] Key features include high-speed performance (propagation delays as low as 3.5 ns), low power consumption (typically 75 mA), 100% testability, and compatibility with both TTL and CMOS logic levels, with variants supporting 3.3V or 5V operations.[1] Compared to PALs, GALs offer significant advantages such as reprogrammability to reduce development costs, lower power usage (up to 50% savings), enhanced reliability through CMOS construction, and greater architectural flexibility via user-programmable OLMCs that eliminate the need for multiple device types.[1] The GAL family encompasses a range of devices, such as the popular GAL16V8 (20-pin package with 8 I/O pins) and GAL22V10 (24-pin with 10 I/O pins), available in commercial, industrial, and military temperature ranges, with extensions like in-system programmable (ispGAL) versions and zero-power options for specialized applications.[1] These innovations transformed the PLD market by enabling more efficient, eco-friendly circuit design and paving the way for modern field-programmable gate arrays (FPGAs), while remaining relevant for legacy systems and cost-sensitive embedded applications.[1][3]Overview
Definition and Purpose
Generic Array Logic (GAL) is a family of programmable logic devices (PLDs) that allow users to implement both combinational and sequential logic functions in a single integrated circuit.[5] Developed by Lattice Semiconductor Corporation, GAL devices employ electrically erasable CMOS (E²CMOS) technology, which provides non-volatile memory capable of retaining programmed logic configurations without power.[6] This architecture enables the realization of custom digital circuits through a programmable AND-OR array that implements sum-of-products logic expressions, offering a versatile foundation for defining complex Boolean functions.[5] The primary purpose of GAL is to serve as a flexible, reprogrammable alternative to multiple fixed-function logic integrated circuits, such as bipolar TTL gates or one-time programmable devices, thereby streamlining digital system design.[6] It supports prototyping, small-scale integration, and glue logic applications in control-intensive systems, including state machines, address decoders, bus interfaces, and signal routing, by consolidating disparate logic elements into one chip to reduce board space, power usage, and overall system complexity.[5] This user-configurable approach accelerates development cycles and lowers costs for low-to-medium volume production, where iterative modifications are common.[6] As an evolution from the earlier Programmable Array Logic (PAL) introduced in the late 1970s, GAL emphasizes reprogrammability to address the limitations of PAL's one-time fusible links or ultraviolet-erasable variants, facilitating repeated design iterations without hardware replacement.[5] Lattice Semiconductor launched the GAL family in 1985, pioneering electrical erasability in CMOS PLDs and replacing approximately 98% of bipolar PAL types with enhanced speed, density, and reliability.[1] This advancement supported the growing demand for adaptable logic in emerging digital applications, such as telecommunications and industrial controls.[6]Key Features
Generic Array Logic (GAL) devices are distinguished by their reprogrammability, enabled by EECMOS (Electrically Erasable CMOS) technology, which allows for electrical erasure and reprogramming without specialized equipment. This process supports a minimum of 100 erase/write cycles and provides up to 20 years of data retention, facilitating iterative design and testing in electronic systems.[7] A key aspect of GAL versatility is the ability of a single device, such as the GAL16V8, to emulate multiple Programmable Array Logic (PAL) types through configurable inputs, outputs, and logic macrocells, offering full functional, fuse map, and parametric compatibility with standard 20-pin PAL devices.[7] This flexibility stems from the underlying AND-OR array structure, which supports varied logic implementations.[7] GAL devices achieve power efficiency through their CMOS architecture, resulting in low static power consumption—typically 30 μA in zero-power variants during standby—while operating at standard 5V voltages (±5% or ±10% tolerance).[8] Additionally, built-in security features, including a programmable security cell, protect proprietary designs by locking the device and preventing unauthorized fuse map readout, akin to encryption during programming.[7] In terms of performance, high-speed variants like the GAL16V8D-15 deliver propagation delays as low as 15 ns, enabling rapid logic operations in time-sensitive applications.[9]History
Invention and Development
Generic Array Logic (GAL) was developed by Lattice Semiconductor Corporation in 1985 as an improvement over one-time programmable Programmable Array Logic (PAL) devices, which were limited by their bipolar technology and inability to be reprogrammed after initial programming.[1][10] A team of engineers at Lattice addressed the key limitations of bipolar PROM-based PALs, such as high power consumption and lack of erasability, by introducing electrically erasable reprogrammability based on E²CMOS technology.[1][10] This innovation was motivated by the need for cost-effective, reusable logic devices to support prototyping in the increasingly complex digital designs of the 1980s, where rapid iteration was essential amid shrinking product development cycles and rising integration demands.[10] The first GAL devices, including the GAL16V8, were launched in April 1985 and featured a generic architecture capable of emulating common PAL functions, such as those of the 16L8 and 20L8 variants, thereby reducing the need for multiple specialized parts.[1][10]Commercial Adoption and Evolution
Following its introduction in 1985, Generic Array Logic (GAL) devices saw rapid commercial adoption in the late 1980s, particularly within embedded systems, telecommunications equipment, and consumer electronics sectors, where their reprogrammability offered significant cost savings and design flexibility over fixed-function alternatives like custom ASICs.[11] Lattice Semiconductor, the primary developer, focused on low-density GAL variants to meet these demands, driving initial market penetration as electronics manufacturers sought efficient prototyping and iteration capabilities.[12] In the 1990s, GAL emerged as the dominant simple programmable logic device (SPLD), with Lattice achieving peak sales of $100 million in 1993 and $144 million by early 1995, fueled by widespread use in board-level designs.[11] Key variants like the GAL20V8 became staples, while compatible devices were also produced by other manufacturers, such as Atmel's ATF series, to expand market reach.[11][13] Evolution during this era included incremental enhancements in speed and density, exemplified by the GAL6000 series introduced in the early 1990s, building on the E2CMOS processes introduced with the original GAL devices for improved reliability, power efficiency, and reprogrammability over earlier bipolar technologies.[5] By the early 2000s, GAL devices were largely superseded by complex programmable logic devices (CPLDs) and field-programmable gate arrays (FPGAs), which provided greater logic capacity, interconnectivity, and performance for evolving design needs.[14] Lattice discontinued GAL production through product change notifications in June and September 2010, transferring select devices to distributors like Arrow Electronics for limited continued availability.[15] Despite this, surplus stock and clones persist in secondary markets, supporting ongoing demand. The legacy of GAL endures in modern programmable logic design, having pioneered electrically erasable architectures that informed subsequent SPLD, CPLD, and FPGA innovations; it remains relevant for legacy system repairs and in educational contexts for teaching foundational digital logic principles.[12][16]Architecture
Internal Structure
The GAL16V8, a representative device in the Generic Array Logic (GAL) family, is housed in a 20-pin Dual In-line Package (DIP), facilitating integration into standard electronic circuits.[7] Its pin configuration includes eight dedicated input pins (2 through 9) for receiving external signals, eight configurable input/output (I/O) pins (12 through 19) that can function as either inputs or tri-state outputs, a dedicated clock input on pin 1 for timing control, and an output enable pin on pin 11 to manage output states across the device.[17] This layout supports up to 16 inputs and 8 outputs, balancing flexibility with a compact form factor typical of GAL devices.[7] Input signals entering the GAL16V8 are processed through input buffers that generate both true and complementary (inverted) forms of each signal.[17] These buffers, designed with TTL-compatible active pull-ups, ensure reliable signal distribution to the internal logic array, enabling efficient access for subsequent combinatorial processing without additional external inversion circuitry.[7] At the core of the device are eight Output Logic Macrocells (OLMCs), each responsible for generating and controlling a single output from pins 12 through 19.[17] These macrocells incorporate feedback paths that allow output signals to loop back as inputs to the array, supporting sequential and combinatorial logic implementations within a unified structure.[7] The OLMCs include programmable elements for output polarity and mode selection, such as registered or combinatorial configurations (detailed in the Programmable Elements section).[17] The GAL16V8 features a dedicated clock input on pin 1, which provides a common timing signal for synchronous operations across all registered OLMCs, enabling flip-flop-based storage and state transitions.[7] Additionally, pin 11 serves as a global output enable, allowing tri-state control to place all outputs in a high-impedance state when asserted, which is essential for bus-oriented applications and power management.[17] The internal block diagram of the GAL16V8 follows a structured data flow: input signals pass through the buffers to produce true and complement lines, which feed into a programmable AND array; the AND array outputs connect to OR gates that sum product terms; these in turn drive the eight OLMCs, which process and route signals to the output pins with optional feedback.[7] This architecture, with its 64x32 AND array configuration, ensures efficient realization of sum-of-products logic while maintaining reconfigurability.[17]Programmable Elements
The programmable elements of Generic Array Logic (GAL) devices form the core of their logic implementation, centered on a sum-of-products architecture that enables flexible Boolean function realization. The AND array serves as the primary programmable component, consisting of a matrix of fusible links that generate product terms (minterms) from input signals and their complements. In the representative GAL16V8 device, the AND array supports 16 inputs feeding into 64 product terms, organized into eight groups of eight terms each to implement sum-of-products expressions.[5] This structure allows each product term to be a logical AND of selected inputs, with the array's fusible connections determining which inputs contribute to each term.[1] The OR array complements the AND array by summing selected product terms to form output signals, typically using fixed or semi-fixed OR gates per macrocell. In the GAL16V8, each of the eight output macrocells receives up to eight dedicated product terms from the AND array via a fixed 8-input OR gate, enabling straightforward sum-of-products logic without extensive rerouting.[5] In more advanced GAL variants, such as the GAL22V10, the OR array offers semi-flexible allocation, allowing product terms to be shared or reassigned across macrocells for greater efficiency in complex designs.[1] Central to the architecture are the Output Logic Macrocells (OLMCs), with one per output pin, each integrating logic for versatile function implementation. In the GAL16V8, each OLMC includes a D-type flip-flop for sequential logic, an XOR gate for programmable output polarity (active-high or active-low), and configurable feedback paths that route the output signal—either directly from the pin or from the flip-flop—back to the AND array as an input.[5] Up to eight product terms can be allocated per OLMC in most modes, with one optionally dedicated to output enable control in configurations requiring tri-state buffering.[18] GAL devices employ EEPROM-based fuse technology, using electrically erasable CMOS (E²CMOS) cells instead of one-time bipolar fuses found in earlier PAL devices, which allows for in-system reprogramming. This technology enables high-speed electrical erasure in under 100 milliseconds, supports at least 100 erase/write cycles, and provides 20-year data retention, enhancing design iteration and reliability.[5] The EEPROM cells store the fuse map as a non-volatile configuration, directly controlling connections in the AND array and OLMC options without requiring physical alteration.[1] OLMC configuration modes provide per-macrocell flexibility for combinational, registered, or bidirectional I/O operation, selected via dedicated fuse bits. In simple mode, the OLMC operates as a dedicated combinational output with eight product terms and pin feedback, suitable for pure logic functions.[5] Complex mode supports combinational outputs or bidirectional I/O with seven product terms for the function and one for programmable output enable, allowing up to six I/Os in the GAL16V8.[19] Registered mode configures the OLMC for sequential logic using the D flip-flop, with eight product terms feeding the data input, common clock and output enable signals, and feedback from the flip-flop Q or /Q outputs to support registered I/O.[5] These modes enable the GAL16V8 to emulate various PAL configurations, such as 16L8 for combinational or 16R8 for registered outputs.[1]Programming
Methods and Processes
The programming of Generic Array Logic (GAL) devices involves an electrically erasable and reprogrammable process leveraging E²CMOS technology, which allows for multiple iterations without physical alteration. To reprogram a GAL, the existing configuration is first erased through a bulk electrical erase operation that resets the on-chip EEPROM array to a virgin state, typically taking less than 100 milliseconds. This erase targets the AND array, control words, and security cell by applying specific voltage levels via the programmer, ensuring all connections are opened.[20][1] Following erasure, the new configuration is applied by programming the fuse map, a binary representation of the desired AND-OR array connections stored in the EEPROM cells, where a "0" indicates an active connection and a "1" denotes an open circuit. This fuse map, often derived from a JEDEC file generated by design software, is loaded into the device one product term at a time using a dedicated programmer that applies high-voltage pulses (>10V) through a tunnel effect to set the cells. The process requires qualified hardware, such as the Logical Devices ALLPRO or modern universal programmers like the TL866II Plus, connected to a host computer via USB (with legacy support for serial or parallel ports in older setups); programming typically completes in under one second per device. Some variants, such as the ispGAL22V10 from Lattice Semiconductor, support in-system programming (ISP), enabling reconfiguration directly on a circuit board without socket removal, using serial interface protocols for boundary-scan access.[20][21] Verification occurs immediately after programming through read-back cycles, where sense amplifiers detect the state of each EEPROM cell by measuring current flow, comparing the device's fuse map against the intended JEDEC file to confirm integrity with 100% accuracy. GAL devices support up to at least 100 erase-write cycles, with each full reprogram cycle (erase plus program) taking a few seconds, allowing iterative design refinement; data retention exceeds 20 years once programmed. A security bit, located in a dedicated EEPROM cell (e.g., row 61 in some architectures), can be set post-programming to lock the design, preventing unauthorized read-back of the fuse map while still permitting erasure for reprogramming.[20][1] Post-programming testing ensures functional integrity through built-in features like output register preload, which allows loading test patterns into macrocells for state machine verification, and support for test vectors provided by the programmer. These mechanisms enable 100% functional testability without external stimulus in many cases, confirming logic implementation and timing compliance before deployment. Software tools briefly referenced here generate the requisite fuse maps from high-level descriptions, but detailed design entry is handled separately.[20]Tools and Software
The primary software tool for designing and programming Generic Array Logic (GAL) devices is WinCUPL, a free integrated development environment (IDE) developed by Atmel (now Microchip Technology) specifically for simple programmable logic devices (SPLDs) and complex PLDs, including GAL architectures.[22] WinCUPL enables users to create, compile, simulate, and debug logic designs, generating output files compatible with standard device programmers.[23] The core language supported by WinCUPL is CUPL (Compiler for Universal Programmable Logic), a text-based descriptive language originally developed for programmable array logic (PAL) devices but widely adapted for GAL due to their architectural similarities.[23] CUPL allows designers to specify logic using Boolean equations, truth tables, state machines, and arithmetic operations, with operators such as "&" for AND, "#" for OR, and "!" for NOT; for instance, a product term might be expressed asA & B # C.[23] While CUPL is equation-oriented, WinCUPL includes extensions like Total Designer VHDL, which converts VHDL descriptions into CUPL source files for GAL targeting, providing limited integration with hardware description languages (HDLs).[23]
The typical workflow in WinCUPL begins with design entry in a plain-text CUPL file defining pins, nodes, and logic equations, followed by optional simulation using the built-in functional simulator to verify behavior against test vectors.[22] The design is then compiled, applying optimizations like product-term minimization, to produce a JEDEC (.jed) file containing the fuse pattern for the GAL device.[23] This file is downloaded to the target GAL via compatible programming hardware, ensuring the logic is electrically programmed into the device's array.[22]
For modern alternatives, open-source tools like Yosys provide a synthesis framework that can be adapted for GAL devices through custom scripts, though support remains legacy-oriented and requires additional processing to generate compatible outputs from Verilog inputs.[24] Vendor-specific IDEs, such as Lattice Semiconductor's ispLEVER Classic (versions predating 2010), offer comprehensive support for GAL programming using ABEL-HDL or HDL synthesis via Synplify for Verilog and VHDL, streamlining designs for Lattice GAL-compatible SPLDs.[25]
A key file format across these tools is the JEDEC standard, an ASCII-based representation of fuse patterns that encodes the programmed state of the GAL's array, promoting interoperability with various programmers regardless of the originating software.[23]
Applications
Typical Uses
Generic Array Logic (GAL) devices are frequently utilized as glue logic to connect microprocessors with peripherals in digital systems, particularly for address decoding tasks in embedded environments. For example, a GAL16V8 can monitor high-order address bus lines (such as A19 and A18) alongside control signals to generate chip select outputs for selecting specific memory or I/O devices like DRAM or ROM, thereby enabling efficient interfacing without discrete TTL components. This application replaces multiple bipolar logic chips, reducing board space and power consumption in systems like personal computers or industrial controllers.[26] GALs also implement finite state machines (FSMs) for sequential control logic in various applications, including controllers for vending machines and traffic lights, where they manage state transitions based on inputs like coin detection or sensor signals. A representative design uses a GAL16V8 to handle multi-state operations, such as a three-story elevator controller that sequences door open/close and floor movement using registered outputs for state storage and combinational logic for transitions. The device's output logic macrocell (OLMC) supports both registered and combinatorial modes, allowing full observability of states via preload features for verification.[26] In rapid prototyping, GALs enable quick development and iteration of custom digital interfaces, such as UART serializers or simple binary counters, prior to ASIC fabrication. Their electrically erasable nature permits instant reprogramming, facilitating design debugging and functional testing with minimal hardware changes; for instance, a GAL20V8 can prototype a 4-bit cascadable adder by configuring macrocells for carry propagation and sum generation. This flexibility supports small-scale logic verification in embedded prototypes, often using tools like CUPL for simulation and programming.[27][26] For legacy systems from the 1980s and 1990s, GALs are employed in repairs and replacements within equipment like telecom switches and early consumer electronics, where their pin-compatible designs substitute for one-time programmable PALs in aging circuits. Reprogrammability allows adaptation to minor specification changes during maintenance, preserving functionality in systems such as multiplexers or interface boards without full redesign.[28] In education, GALs serve as accessible tools for teaching digital logic due to their straightforward architecture and low cost, often integrated into programmable trainers for hands-on experiments in combinational and sequential design. Students use devices like the GAL16V8 to build and test basic circuits, such as decoders or counters, fostering understanding of programmable logic principles in introductory courses.[29]Advantages and Limitations
Generic Array Logic (GAL) devices offer significant advantages in reprogrammability, enabling multiple iterations during prototyping without the need for new hardware, which substantially reduces development costs compared to one-time programmable alternatives like traditional PALs.[17] Their compact form factors, typically in 20- to 28-pin packages such as DIP or PLCC, allow for efficient use of printed circuit board space in space-constrained designs.[17] GALs facilitate rapid implementation of simple logic functions, supporting designs with fewer than 100 gates through their generic architecture and output logic macrocells.[17] In terms of reliability, the non-volatile E²CMOS storage in GAL devices ensures configuration retention without external power, providing robust performance in intermittent power scenarios.[17] Additionally, their low power consumption, typically in the range of 45-115 mA at 5 V supply (equating to 225-575 mW), makes them suitable for battery-operated applications where energy efficiency is critical.[17] Despite these strengths, GAL devices have notable limitations, including restricted logic density with a maximum of 8 to 20 macrocells per chip, rendering them inadequate for complex systems requiring higher integration levels.[17] The fixed AND-OR array architecture provides less routing flexibility than more advanced programmable devices, constraining adaptability for evolving designs.[1] Production of GAL devices has been discontinued by Lattice Semiconductor since around 2010, with manufacturing transferred to partners like Arrow Electronics, posing risks of supply chain obsolescence for long-term projects. As of 2025, GAL devices continue to be available for purchase through electronic component distributors such as DigiKey and Mouser, mitigating some obsolescence concerns for maintenance and hobbyist use.[30][15] On the cost front, GALs maintain low unit prices under $1 in high-volume production due to their simple structure, but require investment in specialized programmers for reconfiguration, adding upfront expenses.[17] They are less economical for very high-volume manufacturing compared to application-specific integrated circuits (ASICs), which offer superior density and performance at scale.[1]Comparisons
With PAL Devices
Generic Array Logic (GAL) devices represent a significant advancement over their predecessor, Programmable Array Logic (PAL) devices, primarily through enhanced reprogrammability using electrically erasable CMOS (EECMOS) technology, which allows for multiple erase and reprogram cycles—typically over 100— or the one-time programmable (OTP) nature of bipolar fuse-based PALs.[1][7] In contrast, traditional PAL devices rely on OTP bipolar fuses, limiting them to a single programming instance and making design changes costly or impossible without replacing the chip.[31] Architecturally, GALs incorporate a more versatile Output Logic Macrocell (OLMC) that supports configurable feedback paths, registers, and output polarities, enabling emulation of various PAL types and implementation of both combinatorial and sequential logic within a single device.[1][7] PAL devices, however, feature a simpler fixed OR plane with dedicated AND-array programmability but lack the macrocell flexibility, restricting outputs to basic sum-of-products forms without integrated registers or bidirectional I/O versatility.[31] In terms of performance, GALs achieve propagation delays as low as 5–25 ns across speed grades in devices like the GAL16V8, and lower power consumption—typically 75 mA—due to their CMOS fabrication, offering 50–75% power savings over bipolar PAL equivalents.[1][7] PAL devices, built on TTL/bipolar technology, exhibit delays of 15–30 ns and higher power draw, often up to 180 mA, which limits their use in power-sensitive or high-speed applications.[31] GALs also provide economic benefits by consolidating multiple PAL variants into one reprogrammable chip, reducing inventory requirements and prototyping costs for iterative designs, whereas PALs remain more suitable for high-volume, fixed-production runs where their lower initial cost outweighs inflexibility.[1]| Feature | GAL16V8 | PAL16L8 |
|---|---|---|
| Reprogram Cycles | >100 (EECMOS) | 1 (OTP bipolar fuses) |
| Propagation Delay (ns) | 5–25 (across grades) | 15–30 |
| Power Consumption (mA) | 75 (typical) | 75–180 |
| I/O Pins | 8 (configurable) | 8 (combinatorial outputs) |
| Architecture | Flexible OLMC with feedback/registers | Fixed OR plane, no macrocell versatility |
With Modern PLDs
Generic Array Logic (GAL) devices, while innovative for their time, differ significantly from modern Complex Programmable Logic Devices (CPLDs) in architecture and capability. GALs feature a fixed AND-OR array with limited macrocells and no programmable interconnects between them, restricting designs to small-scale logic implementations. In contrast, CPLDs like the Xilinx CoolRunner-II incorporate multiple macrocell arrays connected via programmable interconnect matrices, enabling larger and more flexible designs that scale to thousands of gates while maintaining reprogrammability through non-volatile memory.[32][33] Compared to Field-Programmable Gate Arrays (FPGAs), such as the Xilinx Spartan series, GALs lack the distributed configurable logic blocks (CLBs) based on look-up tables (LUTs) and extensive programmable routing resources that define FPGAs. This fixed structure in GALs precludes the integration of embedded blocks for memory, DSP, or system-on-chip (SoC) functions, whereas FPGAs support millions of gates and complex processing tasks through their scalable, reconfigurable fabric.[34][35] Scalability highlights the limited scalability of GALs compared to modern PLDs. GALs are confined to ultra-small logic capacities of approximately 100-500 equivalent gates, suitable only for basic combinational and sequential functions with propagation delays in the 10-30 ns range. Modern CPLDs handle thousands of gates for mid-sized glue logic at speeds around 5 ns, while FPGAs manage complex digital signal processing (DSP) and high-performance computing with millions of gates and delays down to picoseconds. As of 2025, GALs remain relevant for legacy systems and ultra-low-complexity applications where the overhead of modern PLDs would be excessive.[5][34][35] Migration from GAL designs to modern PLDs is facilitated by hardware description language (HDL) tools that convert legacy fuse maps or schematics into synthesizable Verilog or VHDL code, allowing direct porting to CPLDs or FPGAs for enhanced performance without hardware redesign.[36]| Metric | GAL (e.g., 22V10) | CPLD (e.g., CoolRunner-II) | FPGA (e.g., Spartan-II) |
|---|---|---|---|
| Gate Count | 100-500 | 1,000-10,000 | 15,000-200,000 |
| Typical Power | ~75-150 mA | <50 mA (low-power modes) | 100 mA+ (variable) |
| Relative Cost | Low (~$1-5) | Moderate (~$5-20) | High (~$10-100+) |