detailed review of the 8085 instruction set
DESCRIPTION
Detailed Review of the 8085 Instruction Set. 8085 Instruction Set. The 8085 instructions can be classified as follows: Data transfer operations Arithmetic operations (ADD, SUB, INR, DCR) Logic operations Branching operations (JMP, CALL, RET). Between registers - PowerPoint PPT PresentationTRANSCRIPT
![Page 1: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/1.jpg)
Detailed Review of the 8085 Instruction Set
![Page 2: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/2.jpg)
8085 Instruction Set
The 8085 instructions can be classified as follows:
Data transfer operations
Arithmetic operations (ADD, SUB, INR, DCR)
Logic operations
Branching operations (JMP, CALL, RET)
• Between registers• Between memory location and a register• Direct write to a register / memory• Between I/O device and accumulator
![Page 3: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/3.jpg)
8085 Instruction Types
![Page 4: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/4.jpg)
8085 Instruction Types
![Page 5: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/5.jpg)
8085 Instruction Types
![Page 6: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/6.jpg)
Simple Data Transfer Operations
Examples:
MOV B,A 47 From ACC to REG MOV C,D 4A Between two REGs MVI D,47 16 Direct-write into REG D
47
![Page 7: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/7.jpg)
Simple Data Transfer Operations
Example:
OUT 05 D305
Contents of ACC sent to output port number 05.
![Page 8: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/8.jpg)
Simple Memory Access Operations
![Page 9: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/9.jpg)
Simple Memory Access Operations
![Page 10: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/10.jpg)
Arithmetic Operations
![Page 11: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/11.jpg)
Arithmetic Operations
![Page 12: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/12.jpg)
Arithmetic Operations
![Page 13: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/13.jpg)
Arithmetic Operations
![Page 14: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/14.jpg)
Overview of Logic Operations
![Page 15: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/15.jpg)
Logic Operations
![Page 16: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/16.jpg)
Logic Operations
![Page 17: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/17.jpg)
Logic Operations
![Page 18: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/18.jpg)
Branching Operations
Note: This is an unconditional jump operation. It will always force the program counter to a fixed memory address continuous loop !
![Page 19: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/19.jpg)
Branching Operations
Conditional jump operations are very useful for decision making during the execution of the program.
![Page 20: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/20.jpg)
Example
Write a 8085 machine code program:
Read two different memory locations
Add the contents
Send the result to output port 02 (display) if there is no overflow
Display “FF” if there is an overflow
Stop
![Page 21: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/21.jpg)
Example
2000 LDA 2050 3A2001 502002 202003 MOV B,A 472004 LDA 2051 3A2005 512006 202007 ADD B 802008 JNC XXYY D22009 YY2010 XX2011 MVI A,FF 3E2012 FF2013 OUT 02 D32014 022015 HLT 76
Load contents of memory location 2050 into accumulator
Load contents of memory location 2051 into accumulator
Save the first number in B
Add accumulator with B
Jump to YYXX if no carry !
Direct write FF into accumulator
Display accumulator contents at output port 02
Stop
![Page 22: Detailed Review of the 8085 Instruction Set](https://reader035.vdocuments.us/reader035/viewer/2022081417/568139e1550346895da19838/html5/thumbnails/22.jpg)
Updated Code
2000 LDA 2050 3A2001 502002 202003 MOV B,A 472004 LDA 2051 3A2005 512006 202007 ADD B 802008 JNC 2013 D22009 132010 202011 MVI A,FF 3E2012 FF2013 OUT 02 D32014 022015 HLT 76
Load contents of memory location 2050 into accumulator
Load contents of memory location 2051 into accumulator
Save the first number in B
Add accumulator with B
Jump to 2013 if no carry !
Direct write FF into accumulator
Display accumulator contents at output port 02
Stop