(完整版)基于单片机的万年历毕业论文 下载本文

LJMP S_PLAY Y33:

MOV 57H,#02H SETB F0 LJMP S_PLAY Y32:

MOV 56H,#29H ;前一个月不是闰月 MOV A,R6 JB ACC.5,Y34 MOV 56H,#30H Y34:

MOV 57H,#02H CLR F0 LJMP S_PLAY Y31: MOV A,R2

MOV R0,A ;R2中为日的值 LCALL D_BCD MOV 56H,A MOV 57H,#03H CLR F0 LJMP S_PLAY RY3:

CJNE R2,#00H,RY31 MOV 56H,#29H

MOV A,R6

JB ACC.4,RY32 ;R2中为0,则为前一个月 MOV 56H,#30H ;的的最后一天 RY32:

MOV 57H,#03H CLR F0 LJMP S_PLAY RY31:

MOV A,R2 ;R2中为日的值 MOV R0,A LCALL D_BCD MOV 56H,A MOV 57H,#03H SETB F0 LJMP S_PLAY Y4:

CJNE R2,#00H,Y41

LCALL CHECKRE ;查前一个月是否为闰月 CJNE A,#03H,Y42

MOV 56H,#29H ;前一个月是闰月 MOV A,R4 ;R2中为0,则为前一个月 ANL A,#0FH ;的最后一天 JNZ Y43 MOV 56H,#30H MOV 57H,#03H

SETB F0 LJMP S_PLAY Y43:

MOV 57H,#03H SETB F0 LJMP S_PLAY Y42:

MOV 56H,#29H ;前一个月不是闰月 MOV A,R6 JB ACC.4,Y44 MOV 56H,#30H Y44:

MOV 57H,#03H CLR F0 LJMP S_PLAY Y41:

MOV A,R2 ;R2中为日的值 MOV R0,A LCALL D_BCD MOV 56H,A MOV 57H,#04H CLR F0 LJMP S_PLAY RY4:

CJNE R2,#00H,RY41

MOV 56H,#29H ;R2中为0,则为前一个月 MOV A,R6 ;的的最后一天 JB ACC.2,RY42 MOV 56H,#30H RY42:

MOV 57H,#04H CLR F0 LJMP S_PLAY RY41:

MOV A,R2 ;R2中为日的值 MOV R0,A LCALL D_BCD MOV 56H,A MOV 57H,#04H SETB F0 LJMP S_PLAY Y5:

CJNE R2,#00H,Y51

LCALL CHECKRE ;查前一个月是否为闰月 CJNE A,#04H,Y52

MOV 56H,#29H ;前一个月是闰月 MOV A,R4 ;R2中为0,则为前一个月 ANL A,#0FH ;的最后一天 JNZ Y53 MOV 56H,#30H