Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
T1 T2 T3
A0-A15
Memory Address
AD0- AD7
ALE
IO / M
WR
Memory Read Cycle
T1 T2 T3
A0-A15
Memory Address
ALE
IO / M
RD
Instruction Set of 8085
•1 74 Operations
•2 246 Op-codes
•3 5 instruction groups
o1 Data Transfer instruction
•1 MVI, MOV, LXI, IN, OUT, LDA, STA…
o2 Arithmetic instructions
•1 ADD, SUB, ADI, SUI, INC, DED
o3 Logical Instruction
•1 ANA, ORA, XRA, RLC, RAR
o4 Branch Instruction
•1 JMP, JZ, CAL, RET (conditional)
o5 Stack and Machine control instruction
•1 EI, DI, RIM, SIM, HLT, NOP
•4 5 Flags
o1 Sign, Zero, Auxiliary Carry, Parity, Carry
•5 1+6 GPR’s
A (Accumulator) Flags
B C
D E
H L
Stack pointer (16 bit)
Program Counter (16 bit)
Simple Examples
ADDITION
---------
16Bit addition
Start: LXI H, 1234H
LXI B, 4567H
DAD B
HLT
LXI H, 1234H
LXI B, 4567H
MOV A, L
ADD C
MOV L, A
MOV A, H
ADC B
MOV H, A
HLT
SUBSTRACTION
-------------
16Bit subtraction
HLT
START:
MVI A, 25H ; BCD 25
MOV B, A
ANI 0FH
MOV C, A ; Reg. C is 05h
MOV A, B
ANI F0H ; Reg. A is 20h
LOOP: DCX H 6
MOV A, H 4
ORA L 4
RET 10
if count = FFFFH
Then delay is
= 20 + 24 * 65536
= 20 + 1572840
= 1572860 T.