51 SCM controlled LOVE heart-shaped creative lantern PROTEUS and 51 SCM tutorial (with simulation file + source code)

51 MCU controlled LOVE heart-shaped creative lantern
PROTEUS and 51 MCU tutorial with simulation file screenshot
Insert picture description here
Insert picture description here

SCM-controlled LOVE heart-shaped creative lantern reference source code

ORG 0000H
LJMP START
ORG 0030H

; Initialize
START: MOV DPTR, # TAB
MOV R0, # 00H; count from 00
MAIN: MOV A, R0
MOVC A, @ A + DPTR
MOV P0, A
MOV P1, A
LCALL DELAY
LCALL DELAY
INC R0
CJNE R0, # 46, MAIN
MOV R0, # 00H
LJMP MAIN
; blink delay function
DELAY: MOV R5, # 20
D1: MOV R6, # 20
D2: MOV R7, # 248
DJNZ R7, $
DJNZ R6, D2
DJNZ R5, D1
RET

;查表
TAB: DB 0FEH,0FDH,0FBH,0F7H,0EFH,0DFH,0BFH
DB 0FFH,00H,0FFH,00H,0FFH,00H,0FFH
DB 0BFH,0DFH,0EFH,0F7H,0FBH,0FDH,0FEH
DB 0FFH,00H,0FFH,00H,0FFH,00H,0FFH
DB 0FCH,0F9H,0F3H,0E7H,0CFH,9FH
DB 0FFH,00H,0FFH,00H,0FFH,00H,0FFH
DB 9FH,0CFH,0E7H,0F3H,0F9H,0FCH
END

Finally, if you have any comments or suggestions, you are welcome to leave a message to me, let us learn together and progress together.
If you need the complete code or design file, please leave a message or private message me below.

Thank you!

Published 97 original articles · 200 praises · 80,000+ views

Guess you like

Origin blog.csdn.net/weixin_44212493/article/details/104335386