-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 20px 0px 0px; WORD-SPACING: 0px; FONT: 14px/25px 宋體, arial; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; PADDING-TOP: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BACKGROUND-COLOR: rgb(255,255,255); orphans: 2; widows: 2; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px"> MOV DPTR,#DAT ;表頭地址送DPTR MOV 20H,#00H ;中斷計數(shù)器清0
MOV B,#00H ;表序號清0
MUSIC1:
NOP
CLR A
MOVC A,@A+DPTR ;查表取代碼
JZ END0 ;是00H,則結束
CJNE A,#0FFH,MUSIC5
LJMP MUSIC3
MUSIC5:
NOP
MOV R6,A
INC DPTR
MOV A,B
MOVC A,@A+DPTR ;取節(jié)拍代碼送R7
MOV R7,A
SETB TR0 ;啟動計數(shù)
MUSIC2:
NOP
CPL P1.0
MOV A,R6
MOV R3,A
LCALL DEL
評論