Saturday, April 30, 2016

8051 Program – exchange block of data external memory

; exchange block of data
; external memory
ORG 0H
START:
MOV R0,#10H ;Size of an array
MOV 82H,#00H ;DPL=00h
LOOP: MOV 83H,#80H ;DPH=80h
MOVX A,@DPTR ;Src data to acc
MOV R1,A
MOV 83H,#90H ;DPH=90h
MOVX A,@DPTR
XCH A,R1
MOVX @DPTR,A
MOV 83H,#80H ;DPH=80h
MOV A,R1
MOVX @DPTR,A
INC DPTR
DJNZ R0,LOOP
SJMP $
END



Related topics:
8051 Program - move block of data without overlap   |   8051 Program - move block of data with overlap   |   8051 Program - move block of data external memory   |   8051 Program - exchange content of two ram locations   |   8051 Program - memory compare   |   8051 Program - swap nibbles   |   8051 Program - memory subroutines   |   8051 Program - math subroutines   |   8051 Program - conversion subroutines

List of topics: 8051

1 comment:

  1. Your blog article is outstanding; it is informative; in fact, I write on a variety of issues, including app development technology. Please read and give your thoughts on content related to mobile app development company in Navi Mumbai for businesses.

    ReplyDelete