SlideShare a Scribd company logo
Pin diagram 8085a
MVI A, 80H2 byte
MVI B, 76H
Hex code45H, 80H
46,76
Store in memory
0000H 45H
0001H 80H
0002H 46H
0003H 76H
0004H
Addressing modes of 8085
Various ways of specifying the operands in the instruction
are called addressing modes. 8085 supports five different
types of Addressing mode.
MVI A, 80H
1.Register Addressing mode: instructions in which
operand is moving from register to register are called
register addressing mode.
Ex: MOV A, B
BA data move from B to A
Ex: ADD C, ADD B, ADD H
A+CA
If we want to add B & C
MOV A, B
ADD C
2.Immediate Addressing mode: when operand is given
in the instruction directly, then the instruction is a
example of Immediate Addressing mode.
MVI A, 75H=2 byte
MVI C, 45H
MVI H, 7AH
rp register pair (B, D, H).
LXI rp, 16 bit data
Ex: LXI B, 45ACH=3 byte
B=45H, C=ACH
3.Direct Addressing mode: When the address of the
operand is given in the instruction directly then in
that instruction Direct Addressing mode is used.
0014H 45H
054CH 96H
2200H 6BH
LDA 0014H
MOV B, A
A=45H
4.Indirect Addressing mode: When the address of the
operand is given in the instruction indirectly then in
that instruction indirect Addressing mode is used.
Assume reg B=05H & reg C=4CH
MVI r, 8bit data
MOV rd, rs
LDAX rp
LDAX B
Register pair BC=054CHdata96H
A=96H
5.Implied Addressing mode: In instructions where
operand is available in the opcode, then those
instructions are the example of Implied Addressing
mode.
Ex. CMAcomplement accumulator
A=7CH0111 1100
1000 0011
Data Transfer operations (MOV, MVI, OUT, IN)
1.Byte=? (1, 2, 3)
2.Machine cycle used in an instruction=? (1, 2, 3, 4,
5)no. of operations performed by microprocessor
3.T-states used in an instruction=? (4, 7, 10, 13, 16)
In some special cases T states will be (6, 18)
Userwrite in assemblyconvert into hex
codestore in memory
Microprocessor taskfetchdecodeexecute
Operation T-states used
OF 4, 6(in some special case)
MR 3
MW 3
IOR 3
IOW 3
OF, MR, MR, MWTstates13
r= A, B, C, D, E, H, L, M
Data Transfer operations (MOV, MVI, IN, OUT)
1.MOV rd, rs
ASSUME (B=45H, C=A1H)
Ex: MOV B, C (CB)
B= A1H, C=A1H
BYTE: 1
M/C: 1 (OF)
T: 4
HA
MOV A, H (register addressing mode is used)
2.MVI r, 8-bit data
B=45H
MVI B, 45H
BYTE: 2
M/C: 2(OF, MR)
T: 7
3.IN 8-bit address
EX: IN 80H
BYTE: 2
M/C: 3 (OF, MR, IOR)
T: 10
4.OUT 8-bit address
OUT 7CH
BYTE: 2
M/C: 3 (OF, MR, IOW)
T: 10
Machine control operation:
1.HLT:1 byte, M/c=1, T=5
2.NOP: no operation: 1 byte, M/c=1, T=4
0001 45
0002 46
0003 NOP
0004 45
0005 12
0006 45
Arithmetic operations: ADD, ADI, SUB, SUI,
INR, DCR
1.ADD r: if we want to add the data of A & B
ADD B (A+BA)
if we want to add the data of A & H
ADD H (A+HA)
Byte: 1
M/C:1
T:4
Flags affected: S, Z, AC, P, CY
EX: assume we have two data 4C & 2D, add these
data & store the result in reg H.
Program:
MVI A, 2DH
MVI B, 4CH
ADD B
MOV H, A
HLT
Ex2: Read from (1st
input device) 80H & (2nd
input
device) 81H, then add both the data & display the
result into output device (45H).
Program:
IN 80H
MOV B, A
IN 81H
ADD B
OUT 45H
HLT
2.ADI 8-bit data
Ex: ADI 76H
(A+ 76HA)
Byte: 2
M/C: 2
T: 7
Flags affected: S, Z, AC, P, CY
3.SUB r: (A-rA)
EX: A-C
SUB C
Byte: 1
M/C: 1
T: 4
Flags affected: S, Z, AC, P, CY
4.SUI 8 bit data
ASSUME A=4A
SUI 12H
4A-12A
Byte: 2
M/C: 2
T: 7
Flags affected: S, Z, AC, P, CY
5.INR r
EX: H=4DH
INR H
H=4EH
Byte: 1
M/C: 1
T: 4
Flags affected: S, Z, AC, P
CY will not affected by INR
A=FFH
INR A
FF+1
6.DCR r
B=8AH
DCR B
B=89H
Byte: 1
M/C: 1
T: 4
Flags affected: S, Z, AC, P
CY will not affected by DCR
Logical instructions
Logic Operations (ANA, ANI, ORA, ORI, XRA, XRI)
1. ANA r
ANA B (logical AND operation between A, result goes
to A)
Ex: A=48H, B=A6H
ANA B
A=00H
B=A6H
Flags:
Byte: 1
M/C: 1
T: 4
ANI 8-bit data
ANI 7FH
Byte: 2
M/C: 2
T: 7
ORA r
Byte: 1
M/C: 1
T: 4
ORI 8 bit data
Byte: 2
M/C: 2
T: 7
XRA r
Byte: 1
M/C: 1
T: 4
XRI 8 bit data
Byte: 2
M/C: 2
T: 7
Programs
MOV, MVI, IN, OUT
ADD, ADI, SUB, SUI, INR, DCR
ANA, ANI, ORA, ORI, XRA, XRI
PROG1: B=7CH, D=56H add these data & store the result in reg H.
MOV A, B
ADD D
MOV H, A
HLT
PROG2: READ DATA FROM INPUT DEVICE 80H & 81H, LOGICAL
OR BOTH THE DATA & DISPLAY THE RESULT AT OUTPUT 83H.
PORG3: SWAP THE DATA OF REG H & L.
Branch operation (JMP, CALL, RESTART)
Prog: wap to logically XOR the input data 4DH &
2CH. Show the result in output of address 83H. Also
show the status of flags.
Prog: wap to subtract to 8 bit numbers stored in
B=ACH & C=69H. Store the result in reg E. Also show
the status of flags.
ACH1010 1100
69H 0110 1001
CALL instruction:
CALL 16 bit address
JMP 2000H (PC=2000H)
CALL 2000H(PC=2000H)
We jump to subroutine with a CALL instruction.
Subroutine: is a group of instructions written separately
from the main program.
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner
Scanned by CamScanner

More Related Content

What's hot

Instruction set-of-8085
Instruction set-of-8085Instruction set-of-8085
Instruction set-of-8085
saleForce
 
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
Saumitra Rukmangad
 
Instruction set of 8085 Microprocessor By Er. Swapnil Kaware
Instruction set of 8085 Microprocessor By Er. Swapnil KawareInstruction set of 8085 Microprocessor By Er. Swapnil Kaware
Instruction set of 8085 Microprocessor By Er. Swapnil Kaware
Prof. Swapnil V. Kaware
 
8085 instruction set (detailed)
8085 instruction set (detailed)8085 instruction set (detailed)
8085 instruction set (detailed)
Ravi Anand
 
Ecet 330 final exam new 2016
Ecet 330 final exam new 2016Ecet 330 final exam new 2016
Ecet 330 final exam new 2016
Olly_March
 
Instruction set of 8085 microprocessor
Instruction set of 8085 microprocessorInstruction set of 8085 microprocessor
Instruction set of 8085 microprocessor
Rahul Sahu
 
Data transfer instruction set of 8085 micro processor
Data transfer instruction set of 8085 micro processorData transfer instruction set of 8085 micro processor
Data transfer instruction set of 8085 micro processor
vishalgohel12195
 
SAP II ARTICTURE ,SAP 2
SAP II ARTICTURE ,SAP 2SAP II ARTICTURE ,SAP 2
SAP II ARTICTURE ,SAP 2
Apar Pramod
 
8085 instruction set
8085 instruction set8085 instruction set
Instruction set 8085
Instruction set 8085Instruction set 8085
Instruction set 8085
varun sukheja
 
Digital Logic Design
Digital Logic Design Digital Logic Design
Digital Logic Design
Alihyderkolachi
 
Programming with 8085
Programming with 8085Programming with 8085
Programming with 8085
Shehrevar Davierwala
 
Instruction set of 8085
Instruction set  of 8085Instruction set  of 8085
Instruction set of 8085
shiji v r
 
MICROPROCESSOR INSTRUCTION SET OF 8085
MICROPROCESSOR INSTRUCTION SET OF 8085MICROPROCESSOR INSTRUCTION SET OF 8085
MICROPROCESSOR INSTRUCTION SET OF 8085
Sumadeep Juvvalapalem
 
Logical instruction of 8085
Logical instruction of 8085Logical instruction of 8085
Logical instruction of 8085
vishalgohel12195
 
Intel 8085 mp
Intel 8085 mpIntel 8085 mp
Intel 8085 mp
Shaswata Chowdhury
 
8085 assembly language programming
8085 assembly language programming8085 assembly language programming
8085 assembly language programming
Prof. Dr. K. Adisesha
 

What's hot (17)

Instruction set-of-8085
Instruction set-of-8085Instruction set-of-8085
Instruction set-of-8085
 
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
8085 Paper Presentation slides,ppt,microprocessor 8085 ,guide, instruction set
 
Instruction set of 8085 Microprocessor By Er. Swapnil Kaware
Instruction set of 8085 Microprocessor By Er. Swapnil KawareInstruction set of 8085 Microprocessor By Er. Swapnil Kaware
Instruction set of 8085 Microprocessor By Er. Swapnil Kaware
 
8085 instruction set (detailed)
8085 instruction set (detailed)8085 instruction set (detailed)
8085 instruction set (detailed)
 
Ecet 330 final exam new 2016
Ecet 330 final exam new 2016Ecet 330 final exam new 2016
Ecet 330 final exam new 2016
 
Instruction set of 8085 microprocessor
Instruction set of 8085 microprocessorInstruction set of 8085 microprocessor
Instruction set of 8085 microprocessor
 
Data transfer instruction set of 8085 micro processor
Data transfer instruction set of 8085 micro processorData transfer instruction set of 8085 micro processor
Data transfer instruction set of 8085 micro processor
 
SAP II ARTICTURE ,SAP 2
SAP II ARTICTURE ,SAP 2SAP II ARTICTURE ,SAP 2
SAP II ARTICTURE ,SAP 2
 
8085 instruction set
8085 instruction set8085 instruction set
8085 instruction set
 
Instruction set 8085
Instruction set 8085Instruction set 8085
Instruction set 8085
 
Digital Logic Design
Digital Logic Design Digital Logic Design
Digital Logic Design
 
Programming with 8085
Programming with 8085Programming with 8085
Programming with 8085
 
Instruction set of 8085
Instruction set  of 8085Instruction set  of 8085
Instruction set of 8085
 
MICROPROCESSOR INSTRUCTION SET OF 8085
MICROPROCESSOR INSTRUCTION SET OF 8085MICROPROCESSOR INSTRUCTION SET OF 8085
MICROPROCESSOR INSTRUCTION SET OF 8085
 
Logical instruction of 8085
Logical instruction of 8085Logical instruction of 8085
Logical instruction of 8085
 
Intel 8085 mp
Intel 8085 mpIntel 8085 mp
Intel 8085 mp
 
8085 assembly language programming
8085 assembly language programming8085 assembly language programming
8085 assembly language programming
 

Similar to Unit 2 Complete Notes.pdf

8085 Architecture
8085 Architecture8085 Architecture
8085 Architecture
Kumar Anand Singh
 
Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085
Shubham Singh
 
INTEL 8085 DATA FORMAT AND INSTRUCTIONS
INTEL 8085 DATA FORMAT AND INSTRUCTIONSINTEL 8085 DATA FORMAT AND INSTRUCTIONS
INTEL 8085 DATA FORMAT AND INSTRUCTIONS
Swapnil Mishra
 
microp-8085 74 instructions for mct-A :P
microp-8085 74 instructions for mct-A :Pmicrop-8085 74 instructions for mct-A :P
microp-8085 74 instructions for mct-A :P
Jathin Kanumuri
 
microp-8085 74 instructions for mct-A :P-2
microp-8085 74 instructions for mct-A :P-2microp-8085 74 instructions for mct-A :P-2
microp-8085 74 instructions for mct-A :P-2
Jathin Kanumuri
 
8085 micro processor
8085 micro processor8085 micro processor
8085 micro processor
Poojith Chowdhary
 
8085_Microprocessor(simar).ppt
8085_Microprocessor(simar).ppt8085_Microprocessor(simar).ppt
8085_Microprocessor(simar).ppt
KanikaJindal9
 
Microprocessor Part 3
Microprocessor    Part  3Microprocessor    Part  3
Microprocessor Part 3
Sajan Agrawal
 
8085-paper-presentation.ppt
8085-paper-presentation.ppt8085-paper-presentation.ppt
8085-paper-presentation.ppt
KalaiSelvan911913
 
Unit 2 Instruction set.pdf
Unit 2 Instruction set.pdfUnit 2 Instruction set.pdf
Unit 2 Instruction set.pdf
HimanshuPant41
 
Addressing modes
Addressing modesAddressing modes
Addressing modes
karthiga selvaraju
 
UNIT II.pptx
UNIT II.pptxUNIT II.pptx
UNIT II.pptx
ssuser47c811
 
The 8051 assembly language
The 8051 assembly languageThe 8051 assembly language
The 8051 assembly language
hemant meena
 
addressing-mode-of-8051.pdf
addressing-mode-of-8051.pdfaddressing-mode-of-8051.pdf
addressing-mode-of-8051.pdf
DhilibanSwaminathan
 
8085 instruction-set part 1
8085 instruction-set part 18085 instruction-set part 1
8085 instruction-set part 1
RENUKASHIRBAVIKAR1
 
Lec03
Lec03Lec03
Microprocessor 11el01
Microprocessor 11el01Microprocessor 11el01
Chapter 7 - Programming Techniques with Additional Instructions
Chapter 7 - Programming Techniques with Additional InstructionsChapter 7 - Programming Techniques with Additional Instructions
Chapter 7 - Programming Techniques with Additional Instructions
cmkandemir
 
Microprocessorandmicroconrollermcq3 121116120640-phpapp02
Microprocessorandmicroconrollermcq3 121116120640-phpapp02Microprocessorandmicroconrollermcq3 121116120640-phpapp02
Microprocessorandmicroconrollermcq3 121116120640-phpapp02
Yazeed Khalid
 
Assemblylanguageprogrammingof8085 100523023329-phpapp02
Assemblylanguageprogrammingof8085 100523023329-phpapp02Assemblylanguageprogrammingof8085 100523023329-phpapp02
Assemblylanguageprogrammingof8085 100523023329-phpapp02
Swati Watve-Phadke
 

Similar to Unit 2 Complete Notes.pdf (20)

8085 Architecture
8085 Architecture8085 Architecture
8085 Architecture
 
Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085Chapter 3 instruction set-of-8085
Chapter 3 instruction set-of-8085
 
INTEL 8085 DATA FORMAT AND INSTRUCTIONS
INTEL 8085 DATA FORMAT AND INSTRUCTIONSINTEL 8085 DATA FORMAT AND INSTRUCTIONS
INTEL 8085 DATA FORMAT AND INSTRUCTIONS
 
microp-8085 74 instructions for mct-A :P
microp-8085 74 instructions for mct-A :Pmicrop-8085 74 instructions for mct-A :P
microp-8085 74 instructions for mct-A :P
 
microp-8085 74 instructions for mct-A :P-2
microp-8085 74 instructions for mct-A :P-2microp-8085 74 instructions for mct-A :P-2
microp-8085 74 instructions for mct-A :P-2
 
8085 micro processor
8085 micro processor8085 micro processor
8085 micro processor
 
8085_Microprocessor(simar).ppt
8085_Microprocessor(simar).ppt8085_Microprocessor(simar).ppt
8085_Microprocessor(simar).ppt
 
Microprocessor Part 3
Microprocessor    Part  3Microprocessor    Part  3
Microprocessor Part 3
 
8085-paper-presentation.ppt
8085-paper-presentation.ppt8085-paper-presentation.ppt
8085-paper-presentation.ppt
 
Unit 2 Instruction set.pdf
Unit 2 Instruction set.pdfUnit 2 Instruction set.pdf
Unit 2 Instruction set.pdf
 
Addressing modes
Addressing modesAddressing modes
Addressing modes
 
UNIT II.pptx
UNIT II.pptxUNIT II.pptx
UNIT II.pptx
 
The 8051 assembly language
The 8051 assembly languageThe 8051 assembly language
The 8051 assembly language
 
addressing-mode-of-8051.pdf
addressing-mode-of-8051.pdfaddressing-mode-of-8051.pdf
addressing-mode-of-8051.pdf
 
8085 instruction-set part 1
8085 instruction-set part 18085 instruction-set part 1
8085 instruction-set part 1
 
Lec03
Lec03Lec03
Lec03
 
Microprocessor 11el01
Microprocessor 11el01Microprocessor 11el01
Microprocessor 11el01
 
Chapter 7 - Programming Techniques with Additional Instructions
Chapter 7 - Programming Techniques with Additional InstructionsChapter 7 - Programming Techniques with Additional Instructions
Chapter 7 - Programming Techniques with Additional Instructions
 
Microprocessorandmicroconrollermcq3 121116120640-phpapp02
Microprocessorandmicroconrollermcq3 121116120640-phpapp02Microprocessorandmicroconrollermcq3 121116120640-phpapp02
Microprocessorandmicroconrollermcq3 121116120640-phpapp02
 
Assemblylanguageprogrammingof8085 100523023329-phpapp02
Assemblylanguageprogrammingof8085 100523023329-phpapp02Assemblylanguageprogrammingof8085 100523023329-phpapp02
Assemblylanguageprogrammingof8085 100523023329-phpapp02
 

Recently uploaded

Properties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptxProperties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptx
MDSABBIROJJAMANPAYEL
 
cnn.pptx Convolutional neural network used for image classication
cnn.pptx Convolutional neural network used for image classicationcnn.pptx Convolutional neural network used for image classication
cnn.pptx Convolutional neural network used for image classication
SakkaravarthiShanmug
 
Certificates - Mahmoud Mohamed Moursi Ahmed
Certificates - Mahmoud Mohamed Moursi AhmedCertificates - Mahmoud Mohamed Moursi Ahmed
Certificates - Mahmoud Mohamed Moursi Ahmed
Mahmoud Morsy
 
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by AnantLLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
Anant Corporation
 
Generative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of contentGenerative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of content
Hitesh Mohapatra
 
AI assisted telemedicine KIOSK for Rural India.pptx
AI assisted telemedicine KIOSK for Rural India.pptxAI assisted telemedicine KIOSK for Rural India.pptx
AI assisted telemedicine KIOSK for Rural India.pptx
architagupta876
 
CEC 352 - SATELLITE COMMUNICATION UNIT 1
CEC 352 - SATELLITE COMMUNICATION UNIT 1CEC 352 - SATELLITE COMMUNICATION UNIT 1
CEC 352 - SATELLITE COMMUNICATION UNIT 1
PKavitha10
 
Null Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAMNull Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAM
Divyanshu
 
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressionsKuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
Victor Morales
 
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
171ticu
 
132/33KV substation case study Presentation
132/33KV substation case study Presentation132/33KV substation case study Presentation
132/33KV substation case study Presentation
kandramariana6
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
insn4465
 
BRAIN TUMOR DETECTION for seminar ppt.pdf
BRAIN TUMOR DETECTION for seminar ppt.pdfBRAIN TUMOR DETECTION for seminar ppt.pdf
BRAIN TUMOR DETECTION for seminar ppt.pdf
LAXMAREDDY22
 
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have oneISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
Las Vegas Warehouse
 
Welding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdfWelding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdf
AjmalKhan50578
 
Manufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptxManufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptx
Madan Karki
 
Data Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason WebinarData Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason Webinar
UReason
 
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student MemberIEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
VICTOR MAESTRE RAMIREZ
 
Hematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood CountHematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood Count
shahdabdulbaset
 
Computational Engineering IITH Presentation
Computational Engineering IITH PresentationComputational Engineering IITH Presentation
Computational Engineering IITH Presentation
co23btech11018
 

Recently uploaded (20)

Properties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptxProperties Railway Sleepers and Test.pptx
Properties Railway Sleepers and Test.pptx
 
cnn.pptx Convolutional neural network used for image classication
cnn.pptx Convolutional neural network used for image classicationcnn.pptx Convolutional neural network used for image classication
cnn.pptx Convolutional neural network used for image classication
 
Certificates - Mahmoud Mohamed Moursi Ahmed
Certificates - Mahmoud Mohamed Moursi AhmedCertificates - Mahmoud Mohamed Moursi Ahmed
Certificates - Mahmoud Mohamed Moursi Ahmed
 
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by AnantLLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
LLM Fine Tuning with QLoRA Cassandra Lunch 4, presented by Anant
 
Generative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of contentGenerative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of content
 
AI assisted telemedicine KIOSK for Rural India.pptx
AI assisted telemedicine KIOSK for Rural India.pptxAI assisted telemedicine KIOSK for Rural India.pptx
AI assisted telemedicine KIOSK for Rural India.pptx
 
CEC 352 - SATELLITE COMMUNICATION UNIT 1
CEC 352 - SATELLITE COMMUNICATION UNIT 1CEC 352 - SATELLITE COMMUNICATION UNIT 1
CEC 352 - SATELLITE COMMUNICATION UNIT 1
 
Null Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAMNull Bangalore | Pentesters Approach to AWS IAM
Null Bangalore | Pentesters Approach to AWS IAM
 
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressionsKuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
KuberTENes Birthday Bash Guadalajara - K8sGPT first impressions
 
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样学校原版美国波士顿大学毕业证学历学位证书原版一模一样
学校原版美国波士顿大学毕业证学历学位证书原版一模一样
 
132/33KV substation case study Presentation
132/33KV substation case study Presentation132/33KV substation case study Presentation
132/33KV substation case study Presentation
 
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
哪里办理(csu毕业证书)查尔斯特大学毕业证硕士学历原版一模一样
 
BRAIN TUMOR DETECTION for seminar ppt.pdf
BRAIN TUMOR DETECTION for seminar ppt.pdfBRAIN TUMOR DETECTION for seminar ppt.pdf
BRAIN TUMOR DETECTION for seminar ppt.pdf
 
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have oneISPM 15 Heat Treated Wood Stamps and why your shipping must have one
ISPM 15 Heat Treated Wood Stamps and why your shipping must have one
 
Welding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdfWelding Metallurgy Ferrous Materials.pdf
Welding Metallurgy Ferrous Materials.pdf
 
Manufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptxManufacturing Process of molasses based distillery ppt.pptx
Manufacturing Process of molasses based distillery ppt.pptx
 
Data Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason WebinarData Driven Maintenance | UReason Webinar
Data Driven Maintenance | UReason Webinar
 
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student MemberIEEE Aerospace and Electronic Systems Society as a Graduate Student Member
IEEE Aerospace and Electronic Systems Society as a Graduate Student Member
 
Hematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood CountHematology Analyzer Machine - Complete Blood Count
Hematology Analyzer Machine - Complete Blood Count
 
Computational Engineering IITH Presentation
Computational Engineering IITH PresentationComputational Engineering IITH Presentation
Computational Engineering IITH Presentation
 

Unit 2 Complete Notes.pdf

  • 1. Pin diagram 8085a MVI A, 80H2 byte MVI B, 76H Hex code45H, 80H 46,76 Store in memory 0000H 45H 0001H 80H 0002H 46H 0003H 76H
  • 3. Various ways of specifying the operands in the instruction are called addressing modes. 8085 supports five different types of Addressing mode. MVI A, 80H 1.Register Addressing mode: instructions in which operand is moving from register to register are called register addressing mode. Ex: MOV A, B BA data move from B to A Ex: ADD C, ADD B, ADD H A+CA If we want to add B & C MOV A, B ADD C 2.Immediate Addressing mode: when operand is given in the instruction directly, then the instruction is a example of Immediate Addressing mode. MVI A, 75H=2 byte
  • 4. MVI C, 45H MVI H, 7AH rp register pair (B, D, H). LXI rp, 16 bit data Ex: LXI B, 45ACH=3 byte B=45H, C=ACH 3.Direct Addressing mode: When the address of the operand is given in the instruction directly then in that instruction Direct Addressing mode is used. 0014H 45H 054CH 96H 2200H 6BH LDA 0014H MOV B, A A=45H 4.Indirect Addressing mode: When the address of the operand is given in the instruction indirectly then in that instruction indirect Addressing mode is used. Assume reg B=05H & reg C=4CH MVI r, 8bit data MOV rd, rs LDAX rp LDAX B Register pair BC=054CHdata96H
  • 5. A=96H 5.Implied Addressing mode: In instructions where operand is available in the opcode, then those instructions are the example of Implied Addressing mode. Ex. CMAcomplement accumulator A=7CH0111 1100 1000 0011 Data Transfer operations (MOV, MVI, OUT, IN) 1.Byte=? (1, 2, 3) 2.Machine cycle used in an instruction=? (1, 2, 3, 4, 5)no. of operations performed by microprocessor 3.T-states used in an instruction=? (4, 7, 10, 13, 16) In some special cases T states will be (6, 18) Userwrite in assemblyconvert into hex codestore in memory Microprocessor taskfetchdecodeexecute Operation T-states used OF 4, 6(in some special case) MR 3 MW 3 IOR 3 IOW 3
  • 6. OF, MR, MR, MWTstates13 r= A, B, C, D, E, H, L, M Data Transfer operations (MOV, MVI, IN, OUT) 1.MOV rd, rs ASSUME (B=45H, C=A1H) Ex: MOV B, C (CB) B= A1H, C=A1H BYTE: 1 M/C: 1 (OF) T: 4 HA MOV A, H (register addressing mode is used) 2.MVI r, 8-bit data B=45H MVI B, 45H BYTE: 2
  • 7. M/C: 2(OF, MR) T: 7 3.IN 8-bit address EX: IN 80H BYTE: 2 M/C: 3 (OF, MR, IOR) T: 10 4.OUT 8-bit address OUT 7CH BYTE: 2 M/C: 3 (OF, MR, IOW) T: 10
  • 8. Machine control operation: 1.HLT:1 byte, M/c=1, T=5 2.NOP: no operation: 1 byte, M/c=1, T=4 0001 45 0002 46 0003 NOP 0004 45 0005 12 0006 45 Arithmetic operations: ADD, ADI, SUB, SUI, INR, DCR 1.ADD r: if we want to add the data of A & B ADD B (A+BA) if we want to add the data of A & H ADD H (A+HA) Byte: 1 M/C:1 T:4 Flags affected: S, Z, AC, P, CY
  • 9. EX: assume we have two data 4C & 2D, add these data & store the result in reg H. Program: MVI A, 2DH MVI B, 4CH ADD B MOV H, A HLT Ex2: Read from (1st input device) 80H & (2nd input device) 81H, then add both the data & display the result into output device (45H). Program: IN 80H MOV B, A IN 81H ADD B OUT 45H HLT 2.ADI 8-bit data Ex: ADI 76H (A+ 76HA) Byte: 2 M/C: 2 T: 7 Flags affected: S, Z, AC, P, CY
  • 10. 3.SUB r: (A-rA) EX: A-C SUB C Byte: 1 M/C: 1 T: 4 Flags affected: S, Z, AC, P, CY 4.SUI 8 bit data ASSUME A=4A SUI 12H 4A-12A Byte: 2 M/C: 2 T: 7 Flags affected: S, Z, AC, P, CY 5.INR r EX: H=4DH
  • 11. INR H H=4EH Byte: 1 M/C: 1 T: 4 Flags affected: S, Z, AC, P CY will not affected by INR A=FFH INR A FF+1 6.DCR r B=8AH DCR B B=89H Byte: 1 M/C: 1
  • 12. T: 4 Flags affected: S, Z, AC, P CY will not affected by DCR Logical instructions Logic Operations (ANA, ANI, ORA, ORI, XRA, XRI) 1. ANA r ANA B (logical AND operation between A, result goes to A) Ex: A=48H, B=A6H ANA B A=00H B=A6H Flags:
  • 13. Byte: 1 M/C: 1 T: 4 ANI 8-bit data ANI 7FH Byte: 2 M/C: 2 T: 7 ORA r
  • 14. Byte: 1 M/C: 1 T: 4 ORI 8 bit data Byte: 2 M/C: 2 T: 7 XRA r Byte: 1 M/C: 1 T: 4
  • 15. XRI 8 bit data Byte: 2 M/C: 2 T: 7 Programs MOV, MVI, IN, OUT ADD, ADI, SUB, SUI, INR, DCR ANA, ANI, ORA, ORI, XRA, XRI PROG1: B=7CH, D=56H add these data & store the result in reg H. MOV A, B ADD D MOV H, A HLT PROG2: READ DATA FROM INPUT DEVICE 80H & 81H, LOGICAL OR BOTH THE DATA & DISPLAY THE RESULT AT OUTPUT 83H. PORG3: SWAP THE DATA OF REG H & L. Branch operation (JMP, CALL, RESTART)
  • 16. Prog: wap to logically XOR the input data 4DH & 2CH. Show the result in output of address 83H. Also show the status of flags. Prog: wap to subtract to 8 bit numbers stored in B=ACH & C=69H. Store the result in reg E. Also show the status of flags. ACH1010 1100 69H 0110 1001 CALL instruction: CALL 16 bit address JMP 2000H (PC=2000H) CALL 2000H(PC=2000H) We jump to subroutine with a CALL instruction. Subroutine: is a group of instructions written separately from the main program.
  • 17.