ISR.LST
资源名称:51-SD.rar [点击查看]
上传用户:jcsy2001
上传日期:2013-11-29
资源大小:201k
文件大小:4k
源码类别:
嵌入式/单片机编程
开发平台:
C/C++
- C51 COMPILER V8.02 ISR 04/29/2007 12:48:53 PAGE 1
- C51 COMPILER V8.02, COMPILATION OF MODULE ISR
- OBJECT MODULE PLACED IN ISR.OBJ
- COMPILER INVOKED BY: D:KeilC51BINC51.EXE ISR.C BROWSE DEBUG OBJECTEXTEND
- line level source
- 1 #include "common.h"
- 2 #include "HAL.H"
- 3 #include "HPI.H"
- 4 #include "HPI32.H"
- 5
- 6 extern FLAGS bdata bFlags;
- 7 extern unsigned char xdata UARTBUF[UARTBUF_LENGTH];
- 8 extern Command_Def xdata Command;
- 9 //////////////////////////////////////////
- 10 void ISR_COMM(void) interrupt 4
- 11 {
- 12 1 unsigned char *pBuf=(unsigned char *)&Command; //Low Bit at Head
- 13 1 unsigned long xdata timecount;
- 14 1 unsigned int cnt;
- 15 1
- 16 1 MCU_LED3=0;
- 17 1
- 18 1 if(RI==0)
- 19 1 {
- 20 2 MCU_LED3=1;
- 21 2 return;
- 22 2 }
- 23 1
- 24 1 for(cnt=0;cnt<37;cnt++)
- 25 1 {
- 26 2 timecount=0;
- 27 2 while(!RI&&++timecount<20005);
- 28 2 if(timecount>20000)
- 29 2 {
- 30 3 Command.CLass=0xff;
- 31 3 bFlags.bits.bUartInDone=1;
- 32 3 RI=0;
- 33 3 MCU_LED3=1;
- 34 3 return;
- 35 3 }
- 36 2 *(pBuf+cnt)=SBUF;
- 37 2 RI=0;
- 38 2 }
- 39 1
- 40 1 /////// data phase /////////////////////
- 41 1 if(Command.CLass==0x04||Command.CLass==0x05||Command.CLass==0x09) ///GreatFile/GreatDir/WriteFile
- 42 1 {
- 43 2 if(Command.len>MAX_WRITE_LENGTH)
- 44 2 {
- 45 3 Command.CLass=0xff;
- 46 3 bFlags.bits.bUartInDone=1;
- 47 3 MCU_LED3=1;
- 48 3 return;
- 49 3 }
- 50 2
- 51 2 for(cnt=0;cnt<Command.len;cnt++)
- 52 2 {
- 53 3 timecount=0;
- 54 3 while(!RI&&++timecount<20005);
- 55 3 if(timecount>20000)
- C51 COMPILER V8.02 ISR 04/29/2007 12:48:53 PAGE 2
- 56 3 {
- 57 4 Command.CLass=0xff;
- 58 4 bFlags.bits.bUartInDone=1;
- 59 4 RI=0;
- 60 4 MCU_LED3=1;
- 61 4 return;
- 62 4 }
- 63 3 UARTBUF[cnt]=SBUF;
- 64 3 RI=0;
- 65 3 }
- 66 2 }
- 67 1 //////////////////////////
- 68 1 bFlags.bits.bUartInDone=1;
- 69 1 RI=0;
- 70 1 MCU_LED3=1;
- 71 1 }
- 72
- 73
- MODULE INFORMATION: STATIC OVERLAYABLE
- CODE SIZE = 372 ----
- CONSTANT SIZE = ---- ----
- XDATA SIZE = ---- 4
- PDATA SIZE = ---- ----
- DATA SIZE = ---- 5
- IDATA SIZE = ---- ----
- BIT SIZE = ---- ----
- END OF MODULE INFORMATION.
- C51 COMPILATION COMPLETE. 0 WARNING(S), 0 ERROR(S)