📄 timer.lst
字号:
C51 COMPILER V6.12 TIMER 06/02/2005 08:50:15 PAGE 1
C51 COMPILER V6.12, COMPILATION OF MODULE TIMER
OBJECT MODULE PLACED IN .\TIMER.OBJ
COMPILER INVOKED BY: d:\Keil\C51\BIN\C51.EXE .\TIMER.C DEBUG OBJECTEXTEND
stmt level source
1 #include "public.h"
2
3 //void timer0() interrupt 1 using 3 //50ms
4 void timer1() interrupt 3 using 2 //定时器1的中断服务程序入口为中断3
5 {
6 1 EA=0;
7 1 TH1=-20000/256;
8 1 TL1=-20000%256;
9 1
10 1 if(time_5sta_flg==0){
11 2 temp_state1=P1_0; //司机上状态
12 2 temp_state2=P1_2; //司机下状态
13 2 temp_state3=P1_4; //司机状态
14 2 temp_state4=P1_5; //直驶状态
15 2 temp_state5=P1_6; //保留状态
16 2 sum_state1+=temp_state1;
17 2 sum_state2+=temp_state2;
18 2 sum_state3+=temp_state3;
19 2 sum_state4+=temp_state4;
20 2 sum_state5+=temp_state5;
21 2 }
22 1
23 1 // if(((time_5sta_count--)==0)&&(time_5sta_flg==0)){
24 1 if(time_5sta_flg==0)
25 1 if((time_5sta_count--)==0){
26 2 time_5sta_flg=1;
27 2 time_5sta_count=TIMER_FILTER_NUM;
28 2 }
29 1
30 1 if(time_insel_flg==0){
31 2 //内选数据记录
32 2 if(time_insel_count==5){
33 3 array0[0]=XBYTE[((P2&0x60)|0x91)*256];
34 3 array0[1]=XBYTE[((P2&0x60)|0x92)*256];
35 3 array0[2]=XBYTE[((P2&0x60)|0x93)*256];
36 3 }else if(time_insel_count==4){
37 3 array1[0]=XBYTE[((P2&0x60)|0x91)*256];
38 3 array1[1]=XBYTE[((P2&0x60)|0x92)*256];
39 3 array1[2]=XBYTE[((P2&0x60)|0x93)*256];
40 3 }else if(time_insel_count==3){
41 3 array2[0]=XBYTE[((P2&0x60)|0x91)*256];
42 3 array2[1]=XBYTE[((P2&0x60)|0x92)*256];
43 3 array2[2]=XBYTE[((P2&0x60)|0x93)*256];
44 3 }else if(time_insel_count==2){
45 3 array3[0]=XBYTE[((P2&0x60)|0x91)*256];
46 3 array3[1]=XBYTE[((P2&0x60)|0x92)*256];
47 3 array3[2]=XBYTE[((P2&0x60)|0x93)*256];
48 3 }else if(time_insel_count==1){
49 3 array4[0]=XBYTE[((P2&0x60)|0x91)*256];
50 3 array4[1]=XBYTE[((P2&0x60)|0x92)*256];
51 3 array4[2]=XBYTE[((P2&0x60)|0x93)*256];
52 3 }
53 2 }
54 1
55 1 if(time_insel_flg==0)
C51 COMPILER V6.12 TIMER 06/02/2005 08:50:15 PAGE 2
56 1 if((time_insel_count--)==0){
57 2 time_insel_flg=1;
58 2 time_insel_count=TIMER_100ms;
59 2 }
60 1
61 1 //Can发送时用
62 1 // if(((time_500ms_count--)==0)&&(time_500ms_flg==0)){
63 1 if(time_500ms_flg==0)
64 1 if((time_500ms_count--)==0){
65 2 time_500ms_flg=1;
66 2 time_500ms_count=TIMER_500ms;
67 2 }
68 1
69 1 //到站钟延时
70 1 if(m_cArriveRingFlg==1){
71 2 // if(((time_arrive2s_count--)==0)&&(time_arrive2s_flg==0)){
72 2 if(time_arrive2s_flg==0)
73 2 if((time_arrive2s_count--)==0){
74 3 time_arrive2s_flg=1;
75 3 time_arrive2s_count=TIMER_2s;
76 3 }
77 2 }
78 1
79 1 //蜂鸣器间隔延时
80 1 if(m_cBingFlg==1){
81 2 if(time_bing2s_flg==0)
82 2 if((time_bing2s_count--)==0){
83 3 time_bing2s_flg=1;
84 3 time_bing2s_count=TIMER_2s;
85 3 }
86 2 }
87 1
88 1 if(((time_nocan_count--)==0)&&(time_nocan_flg==0)){
89 2 time_nocan_flg=1;
90 2 time_nocan_count=TIMER_5s;
91 2 }
92 1
93 1 EA=1;
94 1 }
95
96
MODULE INFORMATION: STATIC OVERLAYABLE
CODE SIZE = 430 ----
CONSTANT SIZE = ---- ----
XDATA SIZE = ---- ----
PDATA SIZE = ---- ----
DATA SIZE = ---- ----
IDATA SIZE = ---- ----
BIT SIZE = ---- ----
END OF MODULE INFORMATION.
C51 COMPILATION COMPLETE. 0 WARNING(S), 0 ERROR(S)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -