80C51指令表
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
80C51指令表
一、数据传送指令
MOV A,Rn ; (Rn)→A
MOV A,direct ; (direct)→A
MOV A,@Ri ; ((Ri))→A
MOV A,#data ; #data→A
MOV Rn,A ; (A)→ Rn
MOV Rn,direct ; (direct)→ Rn
MOV Rn,#data ; #data→ Rn
MOV direct,A ; (A)→direct
MOV direct,Rn ; (Rn)→direct
MOV direct1,direct2 ; (direct1)→direct2
MOV direct,@Ri ; ((Ri))→direct
MOV direct,#data ; #data→direct
MOV @Ri,A ; ((Ri))→A
MOV @Ri,direct ; (direct)→(Ri)
MOV @Ri,#data ; #data→ ((Ri))
MOV DPTR,#data16 ; dataH→ DPH,data → LDPL MOVX A,@DPTR ; ((DPTR))→A
MOVX @DPTR,A ; (A)→(DPTR)
MOVX A,@Ri ; ((Ri))→A
MOVX @Ri,A ;(A) →(Ri)
MOVC A,@A+PC ; (PC)+1→PC,((A)+(PC))→ A MOVC A,@A+DPTR ; (A)+(DPTR)→A
PUSH direct ; (SP)+1 → SP,(direct) → (SP) POP direct ;((SP)) → (direct), (SP)-1 → SP XCH A,Rn ; (A) ←→(Rn)
XCH A,direct ; (A) ←→(direct)
XCH A,@Ri ; (A) ←→((Ri))
XCHD A,@Ri ; (A)0~3 ←→((Ri))0~3
SWAP A ; (A)0~3 ←→(A)4~7
二、算术运算指令
ADD A,Rn ; (A) + (Rn)→ A
ADD A,direct ; (A) + (direct)→ A
ADD A,@Ri ; (A) + ((Ri))→ A
ADD A,#data ; (A) + #data→ A
ADDC A,Rn ; (A) + (Rn) + cy→ A
ADDC A,direct ; (A) + (direct) + cy→ A
ADDC A,@Ri ; (A) + ((Ri)) + cy→ A
ADDC A,#data ; (A) + # data + cy→ A
SUBB A,Rn ; (A) - ( Rn) - cy→ A
SUBB A,direct ; (A) - (direct) - cy→ A
SUBB A,@Ri ; (A) - ((Ri)) - cy→ A
SUBB A,#data ; (A) - # data - cy→ A
INC A ; (A) + 1 → A
INC Rn ; (Rn) + 1 →Rn
INC direct ; (direct) + 1 →direct
INC @Ri ; ((Ri)) + 1 → (Ri)
INC DPTR ; (DPTR) + 1 → DPTR
DEC A ; (A) - 1 → A
DEC Rn ; (Rn) - 1 →Rn
DEC direct ; (direct) - 1 →direct
DEC @Ri ; ((Ri)) - 1 → (Ri)
MUL AB ; (A)·(B) → AB
DIV AB ; (A) / (B) 商→ A , 余数→ B DA A ; 对A进行十进制调整
三、逻辑操作指令
ANL A,Rn ; (A)∧(Rn) → A
ANL A,direct ; (A)∧(direct) →A
ANL A,@Ri ; (A)∧((Ri)) → A
ANL A,#data ; (A)∧#data → A
ANL direct,A ; (direct)∧(A) →direct
ANL direct,#data ; (direct)∧#data →direct
ORL A,Rn ; (A)∨(Rn) → A
ORL A,direct ; (A)∨(direct) → A
ORL A,@Ri ; (A)∨((Ri)) → A
ORL A,#data ; (A)∨#data → A
ORL direct,A ; (direct)∨(A) →direct
ORL direct,#data ; (direct)∨#data →direct
XRL A,Rn ; (A)⊕(Rn) → A
XRL A,direct ; (A)⊕(direct) → A
XRL A,@Ri ; (A)⊕((Ri)) → A
XRL A,#data ; (A)⊕#data → A
XRL direct,A ; (direct)⊕(A) →direct
XRL direct,#data ; (direct)⊕#data →direct
CLR A ; 0 → A
CPL A ; (A) → A
RL A ; (A)循环左移1位
RLC A ; (A)带进位循环左移1位
RR A ; (A)循环右移1位
RRC A ; (A)带进位循环右移1位SWAP A ;(A)半字节交换