⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 intemp.lst

📁 智能计时计数器 有计两脉冲间隔时间、几脉冲间隔时间、30秒脉冲数等
💻 LST
📖 第 1 页 / 共 3 页
字号:
A51 MACRO ASSEMBLER  INTEMP                                                               07/15/2004 09:46:25 PAGE     1


MACRO ASSEMBLER A51 V6.20
OBJECT MODULE PLACED IN INTEMP.OBJ
ASSEMBLER INVOKED BY: C:\Keil\C51\BIN\A51.EXE INTEMP.ASM SET(SMALL) DEBUG EP

LOC  OBJ            LINE     SOURCE

                       1     ; interrup.asm generated from: interrup.c
                       2     
                       3     
                       4     NAME    INTEMP
                       5     
                       6     ?PR?int_0?INTEMP   SEGMENT CODE
                       7     ?PR?int_1?INTEMP   SEGMENT CODE
                       8     ?PR?TIME_0?INTEMP   SEGMENT CODE
                       9     ?PR?TIME_1?INTEMP   SEGMENT CODE
                      10     ?PR?START_00?INTEMP   SEGMENT CODE
                      11     ?PR?START_11?INTEMP   SEGMENT CODE
                      12             EXTRN   BIT (acce_chose)
                      13             EXTRN   BIT (acce_id)
                      14             EXTRN   BIT (time1_new)
                      15             EXTRN   BIT (time2_new)
                      16             EXTRN   BIT (star1_flat)
                      17             EXTRN   BIT (star0_flat)
                      18             EXTRN   BIT (over0_flat)
                      19             EXTRN   BIT (over)
                      20             EXTRN   DATA (select_id)
                      21             EXTRN   DATA (time_tl0)
                      22             EXTRN   DATA (time_tl1)
                      23             EXTRN   DATA (n)
                      24             EXTRN   DATA (n1)
                      25             EXTRN   DATA (temp)
                      26             EXTRN   DATA (time_hh)
                      27             EXTRN   DATA (time1_hh)
                      28             PUBLIC  START_11
                      29             PUBLIC  START_00
                      30             PUBLIC  TIME_1
                      31             PUBLIC  TIME_0
                      32             PUBLIC  int_1
                      33             PUBLIC  int_0
----                  34     CSEG    AT      00003H
0003 020000   F       35             LJMP    int_0
                      36     
                      37     ; void int_0() interrupt 1 using 0
                      38     
----                  39             RSEG  ?PR?int_0?INTEMP
                      40             USING   3
0000 C0E0             41     int_0:   PUSH   ACC             ;2
0002 C0D0             42             PUSH    PSW               ;2
                      43     
0004 C289             44             clr ie0                   ;1
0006 E500     F       45             mov a,select_id             ;1
0008 B41127           46             cjne a,#11h,other_1          ;2
                      47     ;deal with mode 1-1 ,
                      48     ; start: set n=2 ,open  interrup 0(ex0),set time0 (th0,tl0),clear star_flat
                      49     ;waiting: over_flat is 1
000B 20001B   F       50             jb star0_flat,read_11
000E 750000   F       51              mov time_hh,#00
0011 750000   F       52     mov time_hh+1,#00
0014 750000   F       53     mov time_hh+2,#00
0017 750000   F       54     mov time_hh+3,#00
001A 750000   F       55     mov time_tl0,#00
001D 758A06           56     mov tl0,#6
0020 C28D             57             clr tf0
0022 D28C             58             setb tr0
A51 MACRO ASSEMBLER  INTEMP                                                               07/15/2004 09:46:25 PAGE     2

0024 D200     F       59             setb star0_flat
0026 020000   F       60             ljmp end_int0
0029                  61     read_11:
0029 C28C             62     clr TR0
002B D200     F       63     setb time1_new
002D C200     F       64     clr star0_flat
                      65     
002F 020000   F       66     end_11: ljmp  end_int0
0032 B43013           67     other_1:        cjne a,#30h,other_2     ;2
                      68     ;mode 1-1 over
0035                  69     mode_3:
                      70     ;deal with mode 3-0,3-1,3-2,3-3
0035 C2AA             71             clr ex1
0037 D2CA             72             SETB 0CAH      ;setb TR2
0039 C3               73             clr c
003A 7401             74             mov a,#01h
003C 2500     F       75             add a,n+01h
003E F500     F       76             mov n+01h,a
0040 E4               77             clr a
0041 3500     F       78             addc a,n
0043 F500     F       79             mov n,a
0045 020000   F       80             ljmp end_int0
0048 B43103           81     other_2:cjne a,#31h,other_3       ;2
004B 020000   F       82             ljmp   mode_3                ;2
004E B43203           83     other_3:cjne a,#32h,other_4         ;2
0051 020000   F       84             ljmp mode_3
0054 B43303           85     other_4:cjne a,#33h,other_0            ;2
0057 020000   F       86             ljmp mode_3
                      87     ;mode 3-0,3-1,3-2,3-3 over
                      88     ;other mode
005A                  89     other_0:
005A B4022A           90             cjne a,#02h,other_00
005D 20000B   F       91             jb star0_flat,deal_with02         ;3
0060 C28D             92             clr tf0
0062 D28C             93             setb tr0                          ;1
0064 D200     F       94             setb star0_flat
0066 C2A8             95             clr EX0                   ;1
0068 020000   F       96             ljmp end_int0
006B                  97     deal_with02:                                    ;1
006B C28C             98             clr tr0                              ;1
006D 758300           99             mov dph,#00
0070 758204          100             mov dpl,#04h
                     101             ;mov dptr,#04h
0073 E500     F      102             mov a,time_hh+1
0075 F0              103             movx @dptr,a
0076 A3              104             inc dptr
0077 E500     F      105             mov a,time_hh+2
0079 F0              106             movx @dptr,a
007A A3              107             inc dptr
007B E500     F      108             mov a,time_hh+3
007D F0              109             movx @dptr,a
007E A3              110             inc dptr
007F E58A            111             mov a,tl0
0081 F0              112             movx @dptr,a
0082 D200     F      113             setb over
0084 020000   F      114             ljmp end_int0
                     115     
0087 B4231C          116     other_00:cjne a,#23h,other_000
008A 20000B   F      117             jb star0_flat,deal_with002         ;3
008D C28D            118             clr tf0
008F D28C            119             setb tr0                          ;1
0091 D200     F      120             setb star0_flat
0093 C2AA            121             clr EX1                   ;1
                     122     
0095 020000   F      123             ljmp end_int0
0098                 124     deal_with002:
A51 MACRO ASSEMBLER  INTEMP                                                               07/15/2004 09:46:25 PAGE     3

0098 E500     F      125             mov a,n+1                            ;1
                     126     
009A B40315          127             cjne a,#3,deal_with
009D C2A8            128              clr EX0
009F C28B            129              clr ie1
00A1 D2AA            130              setb EX1
00A3 020000   F      131             ljmp deal_with
00A6 200009   F      132     other_000:jb star0_flat,deal_with         ;3
00A9 C28D            133             clr tf0
00AB D28C            134             setb tr0                          ;1
00AD D200     F      135             setb star0_flat                   ;1
00AF 020000   F      136             ljmp end_int0
                     137     
00B2                 138     deal_with:
                     139     
00B2 A88A            140             mov r0,tl0                        ;2
00B4 A900     F      141             mov r1,time_hh+1                  ;2
00B6 AA00     F      142             mov r2,time_hh+2                   ;2
00B8 AB00     F      143             mov r3,time_hh+3                   ;2
00BA 858A00   F      144             mov time_tl0,tl0                        ;2
00BD AD00     F      145             mov r5,time_hh+1                  ;2
00BF AE00     F      146             mov r6,time_hh+2                   ;2
00C1 AF00     F      147             mov r7,time_hh+3                               ;1
00C3 C3              148             clr c
00C4 E8              149             mov a,r0
                     150     
00C5 B50003   F      151             cjne a,time_tl0,dodo1
00C8 020000   F      152             ljmp  save_data0
00CB                 153      dodo1:       ;tl0>new tl0  c=0
00CB 400D            154             jc save_data0
00CD C3              155             clr c
00CE EF              156             mov a,r7
00CF 9401            157             subb a,#1
00D1 FB              158             mov r3,a
00D2 EE              159             mov a,r6
00D3 9400            160             subb a,#00
00D5 FA              161             mov r2,a
00D6 ED              162             mov a,r5
00D7 9400            163             subb a,#00
00D9 F9              164             mov r1,a
00DA E500     F      165     save_data0:  mov a,n+1                        ;1
00DC 75F004          166             mov b,#4                              ;2
00DF A4              167             mul ab                                ;4
00E0 85F083          168             mov dph,b                             ;2
00E3 F582            169             mov dpl,a                             ;2
00E5 E9              170             mov a,r1                              ;1
00E6 F0              171             movx @dptr,a                          ;2
00E7 A3              172             inc dptr                              ;1
00E8 EA              173             mov a,r2                              ;1
00E9 F0              174             movx @dptr,a                          ;2
00EA A3              175             inc dptr                              ;1
00EB EB              176             mov a,r3                              ;1
00EC F0              177             movx @dptr,a                          ;2
00ED A3              178             inc dptr                              ;1
00EE E8              179             mov a,r0                              ;1
00EF F0              180             movx @dptr,a                          ;2
00F0 E500     F      181             mov a,n+1                            ;1
00F2 14              182             dec a                                ;1
00F3 F500     F      183             mov n+1,a                            ;1
00F5 B40004          184             cjne a,#0,end_int0                   ;2                            ;1
00F8 C28C            185             clr tr0                              ;1
00FA D200     F      186             setb over                            ;1
00FC                 187     end_int0:
00FC D0D0            188             POP     PSW
00FE D0E0            189             POP     ACC
0100 32              190             RETI
A51 MACRO ASSEMBLER  INTEMP                                                               07/15/2004 09:46:25 PAGE     4

                     191     ; END OF int0
                     192     
                     193     
                     194     
----                 195     CSEG    AT      00013H
0013 020000   F      196             LJMP    int_1
                     197     
                     198     ; void int_1() interrupt 3 using 2
                     199     
----                 200             RSEG  ?PR?int_1?INTEMP
                     201             USING   2
0000 C0E0            202     int_1:   PUSH   ACC             ;2
0002 C0D0            203             PUSH    PSW               ;2
                     204     
0004 C28B            205             clr ie1                   ;1
0006 E500     F      206             mov a,select_id             ;1
0008 B41127          207             cjne a,#11h,other_b1          ;2
                     208     ;deal with mode 1-1 ,
                     209     ; start: set n=2 ,open  interrup 0(ex0),set time0 (th0,tl0),clear star_flat
                     210     ;waiting: over_flat is 1
000B 20001B   F      211             jb star1_flat,read_b11
000E 750000   F      212             mov time1_hh,#00
0011 750000   F      213             mov time1_hh+1,#00
0014 750000   F      214             mov time1_hh+2,#00
0017 750000   F      215             mov time1_hh+3,#00
001A 750000   F      216             mov time_tl1,#00
001D 758B06          217             mov tl1,#06h
0020 C28F            218             clr tf1
0022 D28E            219             setb tr1
0024 D200     F      220             setb star1_flat
0026 020000   F      221             ljmp end_b11
0029                 222     read_b11:
0029 C28E            223              clr TR1

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -