XTHS
Harshit Sharma

Microprocessor & Interfacing

Subject Code: 20CST-252 — University Institute of Engineering, Department of CSE. Complete interactive study resource covering every topic from your syllabus.

0
Units
0
Topics
0
MCQs
0
Est. Hours
Unit 1

Introduction to Microprocessor

Foundation Unit

1.1 Definition and Fundamentals

Definition

A microprocessor (MP or μP) is a multipurpose, programmable, clock-driven, register-based electronic device fabricated on a single integrated circuit (IC). It reads binary instructions from a storage device called memory, accepts binary data as input, processes data according to those instructions, and provides output. It is also known as the CPU (Central Processing Unit) and is the heart of any computer system.

The microprocessor is a complete computation engine built with thousands (now billions) of transistors on a single chip. As technology has progressed, microprocessors have become faster, smaller, and capable of doing more work per clock cycle. Modern processors contain billions of transistors on chips smaller than a fingernail.

Exam Tip
Always mention these four key attributes in definitions: programmable, clock-driven, register-based, single IC. Examiners look for these keywords when awarding full marks.

General Architecture of a Microprocessor

Internally, every microprocessor is made up of three main functional units:

MICROPROCESSOR INTERNAL ARCHITECTURE Arithmetic Logic Unit (+, -, AND, OR, XOR, etc.) Control Unit Timing & Signals Register Array A, B, C, D, E, H, L INTERNAL DATA BUS Address Bus | Data Bus | Control Bus External connections to Memory, I/O Devices Fig: General Microprocessor Architecture
  1. Arithmetic Logic Unit (ALU): Performs all arithmetic operations (addition, subtraction, increment, decrement) and logical operations (AND, OR, XOR, NOT, shift, compare). It takes data from registers, processes it, and stores results back in registers (typically the accumulator).
  2. Control Unit (CU): The brain of the microprocessor that coordinates all activities. It fetches instructions from memory, decodes them, and generates appropriate timing and control signals to execute them. It does not process data itself but directs the flow of data between the ALU, registers, memory, and I/O devices.
  3. Register Array: A set of high-speed storage locations inside the processor that hold data being currently processed. Registers are the fastest memory in the system — much faster than RAM. They include general-purpose registers, the accumulator, and special-purpose registers like the Program Counter and Stack Pointer.

1.2 Characteristics of a Microprocessor

The capabilities and limitations of a microprocessor are defined by its key characteristics. Understanding these is essential for comparing different processors.

CharacteristicDescription8085 Example
Data Bus SizeNumber of bits that can be transferred simultaneously. Determines how much data the processor can handle in one operation.8-bit (D0–D7)
Address Bus SizeNumber of bits used to address memory locations. Determines maximum addressable memory: Memory = 2n where n = address lines.16-bit (A0–A15) → 64 KB
Word LengthThe maximum number of bits a processor can process in a single operation. Often equals data bus width but can differ.8-bit
Clock SpeedNumber of clock cycles per second (MHz/GHz). Higher clock speed generally means faster execution. Measured in frequency.3 MHz
Instruction SetThe complete set of instructions a processor can execute. Includes data transfer, arithmetic, logical, branch, and control instructions.74 instructions
I/O AddressingMethod used to address I/O devices: memory-mapped I/O or isolated I/O. Determines how peripherals communicate.Isolated I/O (256 ports)
Data TypesTypes of data the processor can handle: binary, BCD, ASCII, signed/unsigned integers.Binary, BCD
Pro Tip
A common exam question: "If a processor has 4 GB memory, how many address lines are required?" Solution: 4 GB = 4 × 230 bytes = 232 bytes, so 32 address lines are needed.

Memory Calculation Explorer

Adjust the number of address lines to see the addressable memory.

64 KB

1.3 Microprocessor vs Microcomputer vs Microcontroller

These three terms are frequently confused but represent fundamentally different things. A microprocessor is just the CPU chip, a microcomputer is a complete computer built around a microprocessor, and a microcontroller is a self-contained system-on-a-chip designed for control applications.

FeatureMicroprocessorMicrocomputerMicrocontroller
DefinitionSingle IC that functions as CPUComplete computer with MP, memory, I/O on PCBIC with MP, memory, I/O, timers all on one chip
ComponentsALU, CU, Registers onlyMP + RAM + ROM + I/O ports + motherboardMP + RAM + ROM + I/O + Timers + ADC/DAC
MemoryExternal (separate chips)External (separate chips on board)Internal (on-chip)
I/O PortsExternal interface neededOn motherboardBuilt-in on chip
ApplicationGeneral-purpose computingPersonal computers, workstationsEmbedded systems, appliances, automotive
PowerHigher power consumptionModerate to highVery low power
CostModerate (need external parts)Higher (full system)Low (single chip solution)
SpeedVery high (GHz range)HighLower (MHz range)
FlexibilityHighly flexible, customizableModerately flexibleLess flexible, application-specific
ExampleIntel 8085, Pentium, Core i7Desktop PC, Laptop8051, AVR, PIC, ARM Cortex-M
Exam Tip
A 2-mark question often asks: "Is 8085 a microprocessor or microcontroller?" Answer: 8085 is a microprocessor because it requires external memory and I/O devices. It does not have RAM, ROM, or I/O ports on the chip.

1.4 System Bus and Its Types

System Bus

A system bus is a group of wires (parallel electrical lines) that carry signals between the microprocessor, memory, and I/O devices. It is the communication backbone of the computer system — all data, addresses, and control signals travel through these buses.

Data Bus

  • Collection of wires that transmit actual data (not addresses).
  • Size is called width — common widths: 8, 16, 32, 64 bits.
  • A 16-bit data bus processor is roughly double the speed of an 8-bit processor for the same clock, because it transfers twice the data per cycle.
  • Bidirectional — data flows both ways: MP → Memory/I/O (write) and Memory/I/O → MP (read).
  • Number of I/O ports = 2data bus width. For 8-bit bus: 28 = 256 ports.

Address Bus

  • Carries the address of the memory location or I/O port the MP wants to access.
  • Unidirectional — addresses always flow FROM the microprocessor TO memory/I/O devices (only the MP generates addresses).
  • Width directly determines memory capacity: Memory = 2n bytes, where n = number of address lines.
  • 8085 has 16 address lines → 216 = 65,536 = 64 KB addressable memory.

Control Bus

  • Carries control signals that coordinate and synchronize all operations.
  • Individual lines can be unidirectional or bidirectional depending on the signal.
  • Key signals:
SignalTypePurpose
RDOutput, Active LowIndicates MP wants to read data from memory/I/O
WROutput, Active LowIndicates MP wants to write data to memory/I/O
IO/MOutputDifferentiates I/O operation (1) from Memory operation (0)
ALEOutputAddress Latch Enable — indicates valid address on AD0-AD7

Bus Organization Applications

Memory Access

Address bus sends the target location, data bus transfers the data to be stored/retrieved. Essential for instruction fetching and data manipulation.

I/O Operations

Address bus sends the device/port address, data bus transfers input/output data. Enables communication with keyboards, displays, sensors, etc.

Interrupt Handling

Control bus carries interrupt signals. Address bus fetches the interrupt vector, data bus fetches the interrupt service routine from memory.

DMA Operations

Direct Memory Access allows data transfer between memory and I/O without MP intervention. Bus is relinquished via HOLD/HLDA signals.

Bus Signal Visualizer

Click a scenario to see which bus signals activate.

Click a button above to visualize bus signals

Unit 1 — Practice Questions

Unit 2

Architecture of 8085 Microprocessor

Core Unit

2.1 Introduction to Intel 8085

The Intel 8085 is an 8-bit microprocessor introduced by Intel in 1976. It was one of the most widely used microprocessors in academic and industrial applications and remains a foundational subject in computer engineering education.

FeatureSpecification
Data Bus8-bit (D0–D7)
Address Bus16-bit (A0–A15)
Multiplexed BusAD0–AD7 (lower 8 address lines multiplexed with data)
Addressable Memory216 = 64 KB
I/O Addressing8-bit → 28 = 256 I/O ports
Transistors6,200
Power Supply+5V at VCC, Ground at VSS
Clock Frequency3 MHz (internal clock generator)
Instructions74 instructions
Addressing Modes5 modes
Interrupts5 hardware + 8 software
Control Signals12 control signals
Serial I/OSID (Serial Input Data) and SOD (Serial Output Data)
Package40-pin DIP (Dual In-line Package)

Arithmetic and Logical Operations Supported

  • 8-bit binary addition (with/without carry)
  • 16-bit binary addition
  • 2-digit BCD addition
  • 8-bit subtraction (with/without borrow)
  • Increment / Decrement of 8-bit data
  • Logical AND, OR, EX-OR
  • Complement (1's and 2's)
  • Rotate operations (left/right with/without carry)

2.2 Processing Unit: ALU, Accumulator, Flags

Accumulator (Register A)

An 8-bit register that is part of the ALU. After every arithmetic or logical operation, the result is stored in the accumulator. Most instructions implicitly use the accumulator as one operand. It is the most frequently used register in 8085.

Arithmetic and Logic Unit (ALU)

Performs arithmetic operations (ADD, SUB, INC, DEC) and logical operations (AND, OR, XOR, NOT, compare) on data from the accumulator and temporary register. Results are stored back in the accumulator. The ALU also updates the flag register based on the result.

Temporary Register

An 8-bit register that holds the second operand during ALU operations. It is invisible to the programmer — you cannot directly read or write to it. When you execute ADD B, the contents of register B are first copied to the temporary register, then the ALU adds accumulator and temporary register contents.

Flag Register

Flag Register

The flag register is a special-purpose 8-bit register where only 5 bits are used. These flags are set (1) or reset (0) after ALU operations based on the result. The flag register + accumulator together form the Program Status Word (PSW).

Bit Position: Flag Byte: Access: S Z AC P CY D7 D6 D5 D4 D3 D2 D1 D0 Yes Yes No No* No Yes No Yes *AC not accessible by user, used internally for BCD ops
FlagBitSet (1) WhenReset (0) WhenAccessible?
Sign (S)D7Result is negative (MSB = 1)Result is positive (MSB = 0)Yes
Zero (Z)D6Result is zero (all bits = 0)Result is non-zeroYes
Auxiliary Carry (AC)D4Carry from bit D3 to D4No carry from D3 to D4No (internal)
Parity (P)D2Even number of 1s in result (even parity)Odd number of 1s in result (odd parity)Yes
Carry (CY)D0Carry out of MSB (result > 8 bits)No carry outYes
Flag Register Simulator

Enter two 8-bit hex values and an operation to see which flags get set.

Click Compute to see flag results

2.3 Instruction Unit and Control Unit

Instruction Register (IR)

An 8-bit register that holds the current instruction (opcode) fetched from memory. The microprocessor decodes and executes whatever is stored in the IR. The programmer cannot directly access this register.

Instruction Decoder

Interprets the instruction stored in the IR. It identifies what operation is to be performed and on what data. Based on the decoded instruction, it generates specific machine cycles that are sent to the Timing and Control Unit.

Timing and Control Unit

This is the master controller of the 8085. It:

  • Receives machine cycle information from the instruction decoder.
  • Generates 12 control signals that coordinate all processor operations.
  • Provides timing signals synchronized with the clock (3 MHz).
  • Controls data flow between the processor, memory, and I/O devices through the system bus.
  • Manages the sequence of T-states within each machine cycle.
Key Insight
The Timing and Control Unit is what makes the microprocessor "programmable." Without it, the ALU and registers would just be static circuits. The TCU brings them to life by sequencing operations in the correct order at the correct time.

2.4 Storage and Interface Unit: Registers

General Purpose Registers (B, C, D, E, H, L)

Six 8-bit registers used to store temporary data during program execution. They can be used individually as 8-bit registers or combined as register pairs for 16-bit operations:

B–C
Register Pair
D–E
Register Pair
H–L
Register Pair (Pointer)

The H–L pair is special — it is commonly used as a memory pointer. When an instruction uses "M" as an operand, it refers to the memory location whose address is stored in the H–L register pair.

Special Purpose Registers

RegisterSizePurpose
Program Counter (PC)16-bitStores the address of the next instruction to be fetched. Automatically incremented after each byte fetch. Used for sequential execution and branch operations.
Stack Pointer (SP)16-bitPoints to the top of the stack in R/W memory. Stack grows downward. Used during subroutine calls (CALL/RET) and interrupt handling to save/restore the PC.

Other Components

  • Increment/Decrement Register: Holds the 16-bit address that needs to be incremented or decremented by 1 (used by INX, DCX instructions).
  • Address Latch: Stores the upper-order byte (A8–A15) of the 16-bit address during bus operations.
  • Address/Data Latch: Stores either the lower-order address byte (A0–A7) or the 8-bit data (D0–D7) from the multiplexed AD0–AD7 bus.
  • Serial I/O Control: Converts serial data to parallel for the microprocessor and parallel data to serial for peripheral devices. Controls SID and SOD lines.
  • Interrupt Controller: Handles all 5 hardware interrupts (TRAP, RST7.5, RST6.5, RST5.5, INTR) according to their priority levels.

Unit 2 — Practice Questions

Unit 3

Pin Diagram, Interrupts & Addressing Modes

Important Unit

3.1 Interrupts and Their Types

Interrupt

An interrupt is a signal that causes the microprocessor to temporarily stop its current execution and jump to a special subroutine (Interrupt Service Routine). After executing the ISR, the processor returns to the previous program exactly where it left off.

Interrupt Handling Sequence

Executing INTERRUPT Complete Current Inst. Save PC to Stack Load ISR Address in PC Execute ISR Return (RET) Restore PC from Stack
Steps in Order
  1. Complete execution of the current instruction
  2. Save PC contents onto the stack (PUSH PC)
  3. Load PC with the address of the ISR (interrupt vector)
  4. Execute the Interrupt Service Routine
  5. Return to previous program by reading top of stack (RET instruction pops PC)

Hardware Interrupts of 8085

InterruptMaskable?Vectored?TriggerPriorityVector Address
TRAPNon-maskableVectoredLevel & Edge1 (Highest)0024H
RST 7.5MaskableVectoredEdge triggered2003CH
RST 6.5MaskableVectoredLevel triggered30034H
RST 5.5MaskableVectoredLevel triggered4002CH
INTRMaskableNon-vectoredLevel triggered5 (Lowest)External (INTA)

Classification of Interrupts

Maskable interrupts can be enabled or disabled by the programmer using the SIM (Set Interrupt Mask) instruction. RST 5.5, RST 6.5, RST 7.5, and INTR are maskable.

Non-maskable interrupts cannot be disabled by software. TRAP is the only non-maskable interrupt in 8085. It is used for critical events like power failure that must be handled regardless of the processor state.

Vectored interrupts automatically transfer control to a fixed, predefined memory address (the interrupt vector). The processor knows exactly where to jump without needing external hardware to supply the address. All RST interrupts and TRAP are vectored.

Non-vectored interrupts do not have a fixed vector address. INTR is non-vectored — the external device must provide the interrupt vector address through the data bus after receiving the INTA (Interrupt Acknowledge) signal from the processor.

Edge-triggered: Activated at the rising or falling edge of the signal. RST 7.5 is edge-triggered — it responds to the transition from low to high, not the sustained level. This makes it suitable for detecting transient events.

Level-triggered: Activated when the signal is held at a high level. RST 5.5, RST 6.5, and INTR are level-triggered. The interrupt signal must remain high until the processor acknowledges it.

TRAP is both edge and level triggered for maximum reliability — it responds to the rising edge AND requires the signal to remain high.

Software interrupts are invoked by executing specific instructions in the program (not by external hardware signals). The 8085 has 8 software interrupts:

InstructionVector Address
RST 00000H
RST 10008H
RST 20010H
RST 30018H
RST 40020H
RST 50028H
RST 60030H
RST 70038H
Exam Tip
Vector address formula for RST n: Address = n × 8. For RST 7.5: 7.5 × 8 = 60 = 003CH. For RST 5.5: 5.5 × 8 = 44 = 002CH. This quick calculation saves time in exams.
Interrupt Priority Simulator

Trigger multiple interrupts simultaneously to see which one the 8085 handles first based on priority.

Click interrupt buttons to simulate

3.2 Pin Diagram of 8085 (40-Pin DIP)

The 8085 microprocessor comes in a 40-pin Dual In-line Package (DIP). Each pin serves a specific purpose. Click on any pin in the diagram below to see its description.

Interactive Pin Diagram — Click any pin

Key Pin Groups Summary

Pin GroupPinsDirectionFunction
PowerVCC(40), VSS(20)Input+5V supply and Ground
ClockX1(1), X2(2)InputCrystal/timing network for internal clock
ResetRESET IN(3), RESET OUT(36)In/OutReset processor and peripherals
Serial I/OSID(4), SOD(5)In/OutSerial data input/output (1-bit)
InterruptsTRAP(6), RST7.5(7), RST6.5(8), RST5.5(9), INTR(10)InputHardware interrupt requests
Interrupt AckINTA(11)OutputAcknowledges INTR interrupt
Address/DataAD0–AD7 (12–19)BidirectionalMultiplexed lower address and data bus
Address HighA8–A15 (21–28)OutputUpper 8 bits of address bus
StatusS0(29), S1(33)OutputMachine cycle status signals
ALEALE(30)OutputAddress Latch Enable for demultiplexing
IO/MIO/M(34)OutputSelects I/O (1) or Memory (0) operation
ReadyREADY(35)InputSynchronizes slow peripherals with MP
Hold/HLDAHOLD(38), HLDA(39)In/OutDMA request and acknowledge
Read/WriteRD(32), WR(31)OutputRead and Write control signals (active low)

3.3 Addressing Modes of 8085

Addressing Mode

The method by which the address of the source operand (data) and the destination of the result is specified in an instruction is called an addressing mode. In every instruction, the programmer must specify: (1) the operation, (2) where the data comes from, and (3) where the result goes. The 8085 has 5 addressing modes.

The operand is available directly in the instruction itself. No memory or register reference is needed — the data is part of the instruction.

Format: Opcode | Data (8-bit for 2-byte instructions, 16-bit for 3-byte instructions)

8085 Assembly
MVI B, 45H    ; Move 45H immediately to register B (2 bytes)
LXI H, 3050H  ; Load H-L pair with 3050H immediately (3 bytes)
MVI A, FFH    ; Load accumulator with FFH
Quick Identify
If the instruction has a data value right after the register/memory reference, it's Immediate addressing. Look for MVI, LXI, or immediate JMP/CALL instructions.

The operands are stored in internal registers. The instruction specifies which registers contain the data. These are always 1-byte instructions since the register codes are embedded in the opcode.

8085 Assembly
MOV A, B   ; Move contents of B to A
ADD C      ; Add contents of C to A, result in A
INR A      ; Increment A by 1
SUB D      ; Subtract D from A

The instruction contains the 16-bit address of the memory location where the operand is stored. Always a 3-byte instruction: opcode + low address byte + high address byte.

8085 Assembly
LDA 2050H  ; Load accumulator with contents of memory location 2050H
LHLD 3000H  ; Load H-L pair from memory locations 3000H and 3001H
STA 4000H   ; Store accumulator contents at memory location 4000H
IN 35       ; Read data from I/O port number 35

The instruction specifies a register pair that contains the address of the operand. The register pair acts as a pointer to memory. "M" refers to the memory location pointed to by H-L pair.

8085 Assembly
MOV A, M   ; Move contents of memory pointed by HL to accumulator
ADD M      ; Add contents of memory pointed by HL to accumulator
LDAX B     ; Load accumulator from memory pointed by B-C pair
STAX D     ; Store accumulator to memory pointed by D-E pair
Exam Tip
"M" in 8085 assembly always means "memory location pointed to by H-L register pair." It does NOT mean "memory" in general. MOV A, M reads from [HL], not from a direct address.

The operand location is implicitly understood from the opcode itself. No register or address needs to be specified — the instruction operates on a fixed operand (usually the accumulator). Always 1-byte instructions.

8085 Assembly
CMA  ; Complement accumulator (1's complement of A)
RAL  ; Rotate accumulator left through carry
RAR  ; Rotate accumulator right through carry
RLC  ; Rotate accumulator left (without carry in old bit)
RRC  ; Rotate accumulator right (without carry in old bit)
Addressing Mode Identifier

Type any 8085 instruction to identify its addressing mode.

Type an instruction and click Identify

Unit 3 — Practice Questions

Unit 4

Instruction Cycle, Machine Cycle & Timing Diagram

Analytical Unit

4.1 Instruction Cycle, Machine Cycle, and T-States

Instruction Cycle

The complete process of fetching an instruction from memory and executing it is called one instruction cycle. The 8085 fetches and executes instructions one at a time, sequentially.

Instruction Cycle = Fetch Cycle + Execute Cycle

Fetch Cycle (4 T-States)

T-StateOperationSignals
T1PC contents (address) placed on address bus. ALE=1 to latch lower address. Status signals sent.ALE=1, IO/M=0, S1=1, S0=1
T2Lower address disappears from AD0-AD7. RD goes low to enable memory.RD=0
T3Opcode from memory placed on data bus. Loaded into Instruction Register. RD goes high.RD=1 (deasserted)
T4Opcode sent to instruction decoder for decoding. 1-byte instructions execute in this state itself.Internal operation

Machine Cycle

Machine Cycle

The time required by the microprocessor to complete one operation of accessing memory or I/O is called a machine cycle. Each clock pulse is called a T-State. The number of T-states required for one machine cycle varies.

Machine CycleIO/MS1S0RDWRT-States
Opcode Fetch0110 (T2-T3)14
Memory Read0100 (T2-T3)13
Memory Write00110 (T2-T3)3
I/O Read1100 (T2-T3)13
I/O Write10110 (T2-T3)3
Exam Tip — S0/S1 Combination
S1=1, S0=1 → Opcode Fetch  |  S1=1, S0=0 → Memory Read  |  S1=0, S0=1 → Memory Write  |  S1=0, S0=0 → HALT. Memorize this table!

4.2 Timing Diagrams with Examples

Timing Diagram for Opcode Fetch

Worked Examples

MOV A, C is a 1-byte instruction stored at a single memory location (e.g., 0011H). Only an Opcode Fetch machine cycle is needed — 4 T-states total.

T-StateALERDWRIO/MS0S1AD0-AD7
T111101111H (lower addr)
T2001011Opcode on bus
T3001011Opcode loaded in IR
T4011011Decode & Execute

MVI C, 00H is a 2-byte instruction. Stored at 0007H (opcode) and 0008H (data 00H). Requires two machine cycles:

M1: Opcode Fetch — 4 T-states (fetch MVI C opcode from 0007H)

M2: Memory Read — 3 T-states (read operand 00H from 0008H)

Total: 7 T-states

Key Difference
In M2 (Memory Read), S0=0 and S1=1 (different from Opcode Fetch where both are 1). This is how you distinguish between the two machine cycles in a timing diagram.
InstructionBytesMachine CyclesT-States
MVI A, 35H2OF + MR4 + 3 = 7
MVI B, 23H2OF + MR4 + 3 = 7
ADD B1OF4
Total55 cycles18
T-State Calculator

Select instructions to calculate total bytes and T-states.

Add instructions to calculate

Unit 4 — Practice Questions

Unit 5

Programmable Logic Devices (PLDs)

Applied Unit

5.1 Introduction to PLDs and Types

Programmable Logic Device (PLD)

A PLD is an electronic component used to build reconfigurable digital circuits. Unlike fixed-function logic gates (where the circuit is determined at manufacture), PLDs can be programmed by the user to implement any combinational or sequential logic function. They contain arrays of AND and OR gates whose connections can be programmed (made or broken).

Types of PLDs

PLD TypeAND ArrayOR ArrayFlexibilityUse Case
PROMFixedProgrammableLowMemory, lookup tables
PALProgrammableFixedMediumCombinational logic, simple state machines
PLAProgrammableProgrammableHighComplex combinational logic with minimized terms
FPGAFull programmable fabricFull programmable fabricVery HighComplex systems, DSP, processors
GALProgrammableFixed (with macrocells)HighReprogrammable alternative to PAL

Advantages of PLDs

  • Design flexibility: Can be reprogrammed to change functionality without changing hardware.
  • Reduced board space: One PLD can replace dozens of individual logic ICs.
  • Faster prototyping: Design changes are made in software, not by rewiring hardware.
  • Cost effective: For medium-volume production, PLDs are cheaper than custom ASICs.
  • Reliability: Fewer components on the board means fewer points of failure.
  • Security: Some PLDs support security bits to prevent unauthorized copying of designs.

Disadvantages of PLDs

  • Speed: PLDs are generally slower than custom ASICs due to programmable interconnect delays.
  • Power consumption: Higher than optimized discrete logic for simple functions.
  • Learning curve: Requires knowledge of HDLs (VHDL, Verilog) and PLD programming tools.
  • Limited capacity: Smaller PLDs cannot implement very complex designs (unlike FPGAs).

5.2 PLA — Programmable Logic Array

PLA

A Programmable Logic Array has both the AND array and the OR array programmable. This dual programmability allows for logic minimization — you only implement the product terms you actually need, making efficient use of the chip's resources.

PLA Architecture

A B C A' B' C' AND Array (Programmable) P1 = AB P2 = A'C P3 = BC OR Array (Programmable) F1 = P1+P2 F2 = P2+P3 F1 F2 Fig: PLA Architecture — Both AND and OR arrays are programmable

Numerical Example: Implement F = AB + A'C using PLA

Given: F = AB + A'C (3 inputs: A, B, C)

Step 1 — Identify product terms: P1 = AB, P2 = A'C

Step 2 — Program AND array: Connect A and B inputs to AND gate for P1. Connect A' and C inputs to AND gate for P2.

Step 3 — Program OR array: Connect both P1 and P2 outputs to a single OR gate for output F.

Step 4 — PLA size: 3 inputs × 2 product terms × 1 output → 3 × 2 × 1 PLA

Why PLA is Efficient
In a PROM, you would need to implement ALL 8 possible minterms (23 = 8). With PLA, you only implement the 2 product terms actually needed. This is why logic minimization (using K-maps or Quine-McCluskey) directly reduces PLA size and cost.

5.3 PAL — Programmable Array Logic

PAL

A Programmable Array Logic device has a programmable AND array but a fixed (hardwired) OR array. The OR connections are predetermined at manufacture — each output has a fixed number of AND terms OR-ed together.

PLA vs PAL Comparison

FeaturePLAPAL
AND ArrayProgrammableProgrammable
OR ArrayProgrammableFixed (hardwired)
FlexibilityHigher — any product term can go to any outputLower — fixed number of terms per output
SpeedSlightly slower (two programmable levels)Faster (only one programmable level)
CostMore expensiveLess expensive
Design ComplexityRequires full minimization for both arraysSimpler — only AND array needs programming
Number of Product TermsShared across all outputsFixed per output (e.g., 4-8 terms per OR gate)
Logic MinimizationEssential — fewer terms save chip resourcesLess critical — each output has dedicated terms
Example DevicePLA16L8PAL16L8, PAL22V10
Exam Tip
The most frequently asked question: "What is the key difference between PLA and PAL?" Answer: PLA has both arrays programmable; PAL has only the AND array programmable with a fixed OR array. Draw both architectures side-by-side for full marks.

5.4 Field Logic Array (FLA) and Applications

Field Logic Array (FLA)

A Field Logic Array is a broader category of programmable logic devices that can be configured "in the field" (i.e., by the end user, not at the factory). FLAs include PLAs, PALs, GALs, and FPGAs. The term emphasizes that the logic function is determined after the chip is manufactured — during field programming.

FLA vs Discrete Logic Circuits

AspectDiscrete Logic (74xx ICs)FLA-based Design
Design MethodManual schematic with individual gatesHDL-based design, synthesized into PLD
Board SpaceMany ICs needed for complex logicSingle chip replaces many ICs
ModificationRequires physical rewiring/replacementReprogram the chip — no hardware change
PrototypingSlow — breadboard, PCB changesFast — simulate in software, program in minutes
PowerLower per gate but more ICsSingle chip, potentially lower total power
SpeedVery fast (dedicated gates)Slightly slower (programmable routing delays)
Cost (low volume)Higher (many ICs + larger board)Lower (one chip + smaller board)
Cost (high volume)Lower (standard parts)Higher (PLD more expensive than simple gates)
ReliabilityLower (more connections, more failure points)Higher (fewer components and connections)

Importance of AND-OR Plane Programmability in PLA

The dual programmability of PLA provides unique advantages:

  1. Product term sharing: The same product term can be used by multiple outputs. For example, if AB is needed in both F1 and F2, it's generated once in the AND array and connected to both OR gates — saving resources.
  2. Optimal use of chip area: Since both arrays are programmable, you only implement exactly what the logic requires — no wasted product terms or fixed limitations.
  3. Supports complex multi-output functions: Unlike PAL where each output has a fixed number of terms, PLA can allocate terms dynamically based on actual need.
  4. Enables logic minimization benefits: K-map or Quine-McCluskey minimization directly translates to fewer programmed connections, smaller chip size, and lower power.

Practical Limitations of PLA and PAL

  • Limited number of inputs/outputs: Traditional PLAs/PALs have fixed pin counts (16 or 24 pins), limiting the complexity of functions they can implement.
  • Limited product terms: PALs restrict the number of AND terms per output (typically 4-8). Complex functions may exceed this limit.
  • No sequential logic in basic PALs: Standard PALs implement only combinational logic. Registered PALs add flip-flops but with limited flexibility.
  • One-time programmable (OTP): Most PALs and PLAs use fuse-based programming — once programmed, they cannot be changed. EEPROM-based GALs solved this.
  • Propagation delay: Programmable connections add RC delay compared to fixed metallization in ASICs.
  • Obsolescence: Many specific PLA/PAL part numbers are now obsolete, replaced by FPGAs and CPLDs.

Real-World Applications of FLA/PLA

ApplicationWhy FLA/PLA is Preferred
Code converters (Binary to Gray, BCD to 7-segment)Multiple outputs sharing product terms — PLA's term sharing is ideal
Address decoders in memory systemsFixed combinational logic, easy to modify for different memory maps
Industrial control systemsCustom logic for sensor interfacing, timing, and sequencing
Automotive electronicsSingle chip replaces many gates, reduces board space in constrained environments
Peripheral interface controllersCustom I/O decoding and control signal generation
Prototyping before ASIC designValidate logic in PLD before committing to expensive ASIC fabrication
Consumer electronics (TVs, appliances)Cost-effective custom logic without full ASIC development cost

Unit 5 — Practice Questions

Study Tool

Flashcard Deck

Click a card to flip. Mark your progress to track learning with spaced repetition.

Card 1 of 0
Select a unit to begin
Back of card
Reference

Formula & Fact Sheet

Quick reference for all key formulas, values, and facts. Use the print button for exam revision.

Assessment

Mock Test

25 MCQs covering all units. Timer: 15 minutes. Simulates exam conditions.

Analytics

Progress Dashboard

Track your study progress, quiz scores, and identify weak areas.