←Back to Subject
Notes
Notes
Study material and explanations
Diagrams
Diagrams
Visualize concepts easily
Mnemonics
Mnemonics
Tricks to remember faster
One Night Prep
One Night Prep
Short and focused revision
Revision
Revision
Quick summary and key points
Important Questions
Important Questions
Practice most relevant questions
Notes

Instruction Codes, Computer Registers & Common Bus System

Study material and explanations for Unit 3

Instruction Codes, Computer Registers, and the Common Bus System

Introduction: The Stored Program Concept

All modern computers follow the Stored Program Organization designed by mathematician John von Neumann.

  • In this model, both your program code (instructions) and your data (variables, numbers) live together in the same RAM memory.
  • The CPU fetches instructions one by one and executes them in sequence.

1. Instruction Codes and Addressing Bits

An Instruction Code is a group of binary bits that tells the CPU what math or logic operation to perform, and where to find the data.

In the classic Basic Computer (Morris Mano model used in DAVV exams), an instruction word has 16 bits:

16-Bit Instruction Format
Bit 15 (I)
Addressing Mode Bit
0 = Direct, 1 = Indirect
Bits 12–14 (Opcode)
Operation Code (3 bits)
Tells what action to do (ADD, SUB, AND)
Bits 0–11 (Address)
Memory Address (12 bits)
Points to one of 4,096 memory words

Direct vs. Indirect Addressing:

  • Direct Addressing (I = 0): The 12-bit address points directly to the data operand in memory.
  • Indirect Addressing (I = 1): The address points to a memory location that contains another address where the real data is stored!

💡 Real-Life Indian Student Analogy:

  • Direct Addressing (I = 0): Your friend gives you the exact room number where your lecture is held. You go straight there!
  • Indirect Addressing (I = 1): Your friend gives you a note telling you to check the college notice board, and the notice board tells you the real room number!

2. Basic Computer Registers

To fetch and execute instructions, the CPU needs special internal storage boxes called Registers:

Register Symbol Size Full Name Simple Meaning & Purpose
DR 16 bits Data Register Holds the data operand read from memory.
AR 12 bits Address Register Holds the memory address (needs 12 bits because 2¹² = 4096 words).
AC 16 bits Accumulator The main working register; stores calculation results from the ALU.
IR 16 bits Instruction Register Holds the current instruction just fetched from memory.
PC 12 bits Program Counter Holds the memory address of the next instruction to run.
TR 16 bits Temporary Register Holds temporary scratchpad numbers during math steps.
INPR 8 bits Input Register Holds an 8-bit character received from the keyboard.
OUTR 8 bits Output Register Holds an 8-bit character ready to display on the monitor.

3. The Common Bus System

If you connected individual wires between every register, the CPU would be a tangled mess of copper!

  • Instead, all registers share one common 16-line highway called the Common Bus.
  • At any given moment, only one register is allowed to place its data on the bus.
  • Three select lines (S₂, S₁, S₀) control the multiplexers to choose which register uses the bus:
Common Bus Multiplexer Selection
Registers (AR, PC, DR, AC, IR, TR, Memory)
→ Multiplexer Selection (S₂, S₁, S₀)
→ 16-Bit Shared Bus Highway → Destination Register

Bus Selection Codes:

  • 001: AR places address on the bus.
  • 010: PC places next address on the bus.
  • 011: DR places data on the bus.
  • 100: AC places accumulator value on the bus.
  • 101: IR places instruction on the bus.
  • 110: TR places temp data on the bus.
  • 111: Memory Unit (RAM) places data on the bus.

Each register has a Load (LD) pin. Only the target register whose LD = 1 reads and saves the data from the bus on the clock tick!


💡 DAVV Exam Preparation Tips

5-Mark Question: “Explain the roles of AR, PC, DR, and AC registers in a basic computer system with their bit sizes.”

  • Clearly list all 4 registers with their sizes: AR (12 bits), PC (12 bits), DR (16 bits), AC (16 bits).
  • Give their direct purpose in 1 sentence each.
  • Mention why AR and PC are 12 bits: memory has 4096 locations (2¹² = 4096).

10-Mark Question: “Draw and explain the Common Bus System for basic computer registers using multiplexers. Show the selection table.”

  • Draw the block diagram showing AR, PC, DR, AC, IR, TR, and Memory Unit connected to the 16-bit bus.
  • Write down the full 8-row selection table for S₂, S₁, S₀ (000 to 111).
  • Explain how data transfers from one register to another in 1 clock cycle (e.g. AR ← PC).