0% found this document useful (0 votes)
13 views16 pages

Lecture-3 (8085 Microprocessor-Internal Architecture)

The document provides an overview of the 8085 microprocessor, detailing its internal architecture, including the ALU, registers, and memory structure. It discusses the functionality of various registers, the stack memory, and includes a simple assembly program example. The course is taught by Dr. Md. Obaidur Rahman at the Islamic University of Technology.

Uploaded by

saidurrahman
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views16 pages

Lecture-3 (8085 Microprocessor-Internal Architecture)

The document provides an overview of the 8085 microprocessor, detailing its internal architecture, including the ALU, registers, and memory structure. It discusses the functionality of various registers, the stack memory, and includes a simple assembly program example. The course is taught by Dr. Md. Obaidur Rahman at the Islamic University of Technology.

Uploaded by

saidurrahman
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

8085 Microprocessor:

Internal Architecture

Course Teacher:
Md. Obaidur Rahman, Ph.D.
Professor
Department of Computer Science and Engineering (CSE)
Dhaka University of Engineering & Technology (DUET), Gazipur.

Course ID: CSE - 4503


Course Title: Microprocessors and Assembly Language
Department of Computer Science and Engineering (CSE)
Islamic University of Technology (IUT), Gazipur.
Lecture References:
 Book:
 Microprocessor, architecture, programming & application with the
8085, Chapter # 2, Author: Gaonkar

 Lecture Materials:
 IBM PC Organization, CAP/IT221

2 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
Internal Structure of a Microprocessor

Address bus
ALU Register
Section
Data bus

Control and timing


section Control bus

Block Diagram of a Microprocessor

3 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
8085 Microprocessor
 Intel 8085
 The 8085 microprocessor was introduced by Intel in the year
1976.
 8-bit microprocessor with 16-bit address bus and 8-bit data
bus.
 This microprocessor is an update of 8080 microprocessor.
 It is an 8-bit microprocessor with a 40 pin Dual in Line Package
(DIP)
 Total 74 operation codes in assembly language and those can
generate 246 instructions.

4 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
8-Bit 8085 Intel Processor Architecture
8-bit_Internal_databus

Accumulator Temp. Flag Instruction B C


Register Register Register
D E

Arithmetic H L
and Logic Instruction
Stack Pointer
Unit decoder
Program Counter
Controller for
Address latch

Address Buffer Data/address


A8-A15 Buffer AD0-AD7
Timing and Control unit
8- bit External
Data bus
Clock Write Read RAM memory

5 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
8-Bit 8085 Intel Processor (Pin Diagram)

6 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
8085 Registers and Memory
 Registers: FFFF
FFFE
 Total 11 registers and 1
FFFD
temporary register FFFC
 Information is stored in FFFB
registers FFFA
FFF9
 Registers are classified ….
according to the functions they ….
perform ….
….
….
 64 Kbytes of memory and 65536 0003
memory locations. 0002
0001
0000
7 CSE-4503: Microprocessors and Assembly Language
Islamic University of Technology (IUT)
8085 Register Categories
 Accumulator – 8 bit register which holds the latest result from ALU
 B, C, D, E, H and L are general purpose registers
 HL pair can be used for indirect addressing as well
 Program counter – 16 bit register which holds the address of the
next instruction to be executed
 Instruction Register – It holds the instruction that is currently being
processed.
 Stack Pointer is used during subroutine calling and execution.
 Address Latch – It increments/ decrements the address before sent
to the address buffer

8 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
8085 Register Categories
 Flag Register

 Sign Flag: If the result of the latest arithmetic operation is having MSB
(most- significant byte) ‘1’ (meaning it is a negative number), then the sign
flag is set to ‘1’. Otherwise, it is reset to ‘0’ which means it is a positive
number.

 Zero Flag: If the result of the latest operation is zero, then zero flag will be
set to ‘1’; otherwise it be reset to ‘0’.

 Auxiliary Carry Flag: This flag is not accessible to programmer. This flag
will be used by the system during BCD (binary-coded decimal) operations.

 Parity Flag: If the result of the latest operation is having even number of
‘1’s, then this flag will be set to ‘1’ Otherwise this will be reset to ‘0’. This
is used for error checking.

 Carry Flag: If the result of the latest operations exceeds 8-bits then this flag
will be set to ‘1’. Otherwise it be reset to ‘0’.
9 CSE-4503: Microprocessors and Assembly Language
Islamic University of Technology (IUT)
Simple Assembly Program in 8085
MVI A, 32H Memory Contents Contents Operation
MVI B , 48H Address (Binary) (Hex)
ADD B 2000h 0011 1110 3E Load Reg.
Acc.
OUT 01H
2001h 0011 0010 32 Value is 32h
HLT
2002h 0000 0110 06 Load Reg. B
2003h 0100 1000 48 Value is 48h
Task:
2004h 1000 0000 80 Add B with
 Derive the
A & Store in
flag values A
after the
2005h 1101 0011 D3 Display
ADD
instructions 2006h 0000 0001 01 Port Id 01h
2007h 0111 1100 76 End

10 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
Stack Pointer and Stack Memory
 The stack is an area of memory identified by the
programmer for temporary storage of information.
 The stack is a LIFO structure.
 The stack normally grows backwards into memory.
 Programmer can defines the
bottom of the stack (SP) The Stack Bottom of
and the stack grows up into Grows the Stack
backwards Memory
reducing address range. Into memory

11 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
Stack Memory
 Grows backwards into memory
 Better to place the bottom of the stack at the end of
memory
 To keep it as far away from user programs as possible.
 Stack is defined by setting the SP (Stack Pointer) register.

LXI SP, FFFFh ; Load 16-bit number in a register

 This sets SP to location FFFFh (end of memory for 8085).

12 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
Saving Information in Stack
 Save information by PUSHing onto STACK
 Retrieved from STACK by POPing it off.
 PUSH and POP work with register pairs only.
 Example “PUSH B”
 Decrement SP, Copy B to 0(SP)
FFFF
 Decrement SP, Copy C tp 0(SP) FFFE 12
FFFD F3 SP
 Example “POP B” FFFC
 Copy SP to C, Increment SP FFFB

 Copy SP to B, Increment SP B C
12 F3

13 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)
Thank You !!

14 CSE-4503: Microprocessors and Assembly Language


Islamic University of Technology (IUT)

You might also like