LED_DIS.LST
上传用户:woden7206
上传日期:2015-11-28
资源大小:14486k
文件大小:14k
源码类别:

单片机开发

开发平台:

MultiPlatform

  1. C51 COMPILER V8.08   LED_DIS                                                               04/26/2008 20:29:08 PAGE 1   
  2. C51 COMPILER V8.08, COMPILATION OF MODULE LED_DIS
  3. OBJECT MODULE PLACED IN LED_DIS.OBJ
  4. COMPILER INVOKED BY: C:KeilC51BINC51.EXE LED_DIS.c BROWSE DEBUG OBJECTEXTEND
  5. line level    source
  6.    1          #include<reg52.h> 
  7.    2          #include <intrins.h>
  8.    3          #include"type.h"
  9.    4          #include"LED_DIS.H"
  10.    5          void delay(UINT t)
  11.    6          {
  12.    7   1              UCHAR i;
  13.    8   1              while(t--)
  14.    9   1              {
  15.   10   2                      for(i=0;i<10;i++);
  16.   11   2              }
  17.   12   1      
  18.   13   1      }
  19.   14          void switch_DIS(UCHAR S_DAT)
  20.   15          {
  21.   16   1                      switch(S_DAT)
  22.   17   1              {
  23.   18   2                              case 0:
  24.   19   2                      {       
  25.   20   3                              LED_DIS_D0=0;
  26.   21   3                              LED_DIS_D1=0;
  27.   22   3                              LED_DIS_D2=0;
  28.   23   3                              LED_DIS_D3=0;
  29.   24   3                      
  30.   25   3                       } break;
  31.   26   2                       case 1:
  32.   27   2                      {       
  33.   28   3                              LED_DIS_D0=1;
  34.   29   3                              LED_DIS_D1=0;
  35.   30   3                              LED_DIS_D2=0;
  36.   31   3                              LED_DIS_D3=0;
  37.   32   3                      
  38.   33   3                       } break;
  39.   34   2                       case 2:
  40.   35   2                      {       
  41.   36   3                      
  42.   37   3                              LED_DIS_D0=0;
  43.   38   3                              LED_DIS_D1=1;
  44.   39   3                              LED_DIS_D2=0;
  45.   40   3                              LED_DIS_D3=0;
  46.   41   3                              
  47.   42   3                       } break;
  48.   43   2                       case 3:
  49.   44   2                      {       
  50.   45   3                      
  51.   46   3                              LED_DIS_D0=1;
  52.   47   3                              LED_DIS_D1=1;
  53.   48   3                              LED_DIS_D2=0;
  54.   49   3                              LED_DIS_D3=0;
  55.   50   3                              
  56.   51   3                       } break;
  57.   52   2                       case 4:
  58.   53   2                      {       
  59.   54   3                      
  60.   55   3                              LED_DIS_D0=0;
  61. C51 COMPILER V8.08   LED_DIS                                                               04/26/2008 20:29:08 PAGE 2   
  62.   56   3                              LED_DIS_D1=0;
  63.   57   3                              LED_DIS_D2=1;
  64.   58   3                              LED_DIS_D3=0;
  65.   59   3                              
  66.   60   3                       } break;
  67.   61   2                       case 5:
  68.   62   2                      {       
  69.   63   3                                      
  70.   64   3                      
  71.   65   3                              LED_DIS_D0=1;
  72.   66   3                              LED_DIS_D1=0;
  73.   67   3                              LED_DIS_D2=1;
  74.   68   3                              LED_DIS_D3=0;
  75.   69   3                      
  76.   70   3                       } break;
  77.   71   2                       case 6:
  78.   72   2                      {       
  79.   73   3                              
  80.   74   3                              LED_DIS_D0=0;
  81.   75   3                              LED_DIS_D1=1;
  82.   76   3                              LED_DIS_D2=1;
  83.   77   3                              LED_DIS_D3=0;
  84.   78   3                      
  85.   79   3                       } break;
  86.   80   2                       case 7:
  87.   81   2                      {       
  88.   82   3                              LED_DIS_D0=1;
  89.   83   3                              LED_DIS_D1=1;
  90.   84   3                              LED_DIS_D2=1;
  91.   85   3                              LED_DIS_D3=0;
  92.   86   3                              
  93.   87   3                       } break;
  94.   88   2                       case 8:
  95.   89   2                      {       
  96.   90   3                      
  97.   91   3                              LED_DIS_D0=0;
  98.   92   3                              LED_DIS_D1=0;
  99.   93   3                              LED_DIS_D2=0;
  100.   94   3                              LED_DIS_D3=1;
  101.   95   3                              
  102.   96   3                       } break;
  103.   97   2                       case 9:
  104.   98   2                      {       
  105.   99   3                      
  106.  100   3                              LED_DIS_D0=1;
  107.  101   3                              LED_DIS_D1=0;
  108.  102   3                              LED_DIS_D2=0;
  109.  103   3                              LED_DIS_D3=1;
  110.  104   3                      
  111.  105   3                       } break;
  112.  106   2                       default:break;
  113.  107   2                              
  114.  108   2              
  115.  109   2              }
  116.  110   1      }
  117.  111          void LED_DIS(UCHAR LED_DSI_DAT)
  118.  112          {
  119.  113   1              UCHAR DIS_DAT0,DIS_DAT1;
  120.  114   1      
  121.  115   1              DIS_DAT0=LED_DSI_DAT/10;
  122.  116   1              DIS_DAT1=LED_DSI_DAT%10;
  123.  117   1                                      
  124. C51 COMPILER V8.08   LED_DIS                                                               04/26/2008 20:29:08 PAGE 3   
  125.  118   1              LED_DIS_A0=0;
  126.  119   1              LED_DIS_A1=1;
  127.  120   1              switch_DIS(DIS_DAT0);
  128.  121   1              delay(5);
  129.  122   1              LED_DIS_A0=1;
  130.  123   1              LED_DIS_A1=0;
  131.  124   1              switch_DIS(DIS_DAT1);
  132.  125   1              delay(5);
  133.  126   1              /*      case 0:
  134.  127   1                      {       
  135.  128   1                              LED_DIS_D0=0;
  136.  129   1                              LED_DIS_D1=0;
  137.  130   1                              LED_DIS_D2=0;
  138.  131   1                              LED_DIS_D3=0;
  139.  132   1                              LED_DIS_A0=0;
  140.  133   1                              LED_DIS_A1=0;
  141.  134   1                       } break;
  142.  135   1                       case 1:
  143.  136   1                      {       
  144.  137   1                              LED_DIS_D0=0;
  145.  138   1                              LED_DIS_D1=0;
  146.  139   1                              LED_DIS_D2=0;
  147.  140   1                              LED_DIS_D3=0;
  148.  141   1                              LED_DIS_A0=0;
  149.  142   1                              LED_DIS_A1=1;
  150.  143   1                              delay(1);
  151.  144   1                              LED_DIS_A0=1;
  152.  145   1                              LED_DIS_A1=0;
  153.  146   1                              LED_DIS_D0=1;
  154.  147   1                              LED_DIS_D1=0;
  155.  148   1                              LED_DIS_D2=0;
  156.  149   1                              LED_DIS_D3=0;
  157.  150   1                              delay(1);
  158.  151   1                       } break;
  159.  152   1                       case 2:
  160.  153   1                      {       
  161.  154   1                              LED_DIS_D0=0;
  162.  155   1                              LED_DIS_D1=0;
  163.  156   1                              LED_DIS_D2=0;
  164.  157   1                              LED_DIS_D3=0;
  165.  158   1                              LED_DIS_A0=0;
  166.  159   1                              LED_DIS_A1=1;
  167.  160   1                              delay(1);
  168.  161   1                              LED_DIS_A0=1;
  169.  162   1                              LED_DIS_A1=0;
  170.  163   1                              LED_DIS_D0=0;
  171.  164   1                              LED_DIS_D1=1;
  172.  165   1                              LED_DIS_D2=0;
  173.  166   1                              LED_DIS_D3=0;
  174.  167   1                              delay(1);
  175.  168   1                       } break;
  176.  169   1                       case 3:
  177.  170   1                      {       
  178.  171   1                              LED_DIS_D0=0;
  179.  172   1                              LED_DIS_D1=0;
  180.  173   1                              LED_DIS_D2=0;
  181.  174   1                              LED_DIS_D3=0;
  182.  175   1                              LED_DIS_A0=0;
  183.  176   1                              LED_DIS_A1=1;
  184.  177   1                              delay(1);
  185.  178   1                              LED_DIS_A0=1;
  186.  179   1                              LED_DIS_A1=0;
  187. C51 COMPILER V8.08   LED_DIS                                                               04/26/2008 20:29:08 PAGE 4   
  188.  180   1                              LED_DIS_D0=1;
  189.  181   1                              LED_DIS_D1=1;
  190.  182   1                              LED_DIS_D2=0;
  191.  183   1                              LED_DIS_D3=0;
  192.  184   1                              delay(1);
  193.  185   1                       } break;
  194.  186   1                       case 4:
  195.  187   1                      {       
  196.  188   1                              LED_DIS_D0=0;
  197.  189   1                              LED_DIS_D1=0;
  198.  190   1                              LED_DIS_D2=0;
  199.  191   1                              LED_DIS_D3=0;
  200.  192   1                              LED_DIS_A0=0;
  201.  193   1                              LED_DIS_A1=1;
  202.  194   1                              delay(1);
  203.  195   1                              LED_DIS_A0=1;
  204.  196   1                              LED_DIS_A1=0;
  205.  197   1                              LED_DIS_D0=0;
  206.  198   1                              LED_DIS_D1=0;
  207.  199   1                              LED_DIS_D2=1;
  208.  200   1                              LED_DIS_D3=0;
  209.  201   1                              delay(1);
  210.  202   1                       } break;
  211.  203   1                       case 5:
  212.  204   1                      {       
  213.  205   1                                      
  214.  206   1                              LED_DIS_D0=0;
  215.  207   1                              LED_DIS_D1=0;
  216.  208   1                              LED_DIS_D2=0;
  217.  209   1                              LED_DIS_D3=0;
  218.  210   1                              LED_DIS_A0=0;
  219.  211   1                              LED_DIS_A1=1;
  220.  212   1                              delay(1);
  221.  213   1                              LED_DIS_A0=1;
  222.  214   1                              LED_DIS_A1=0;
  223.  215   1                              LED_DIS_D0=1;
  224.  216   1                              LED_DIS_D1=0;
  225.  217   1                              LED_DIS_D2=1;
  226.  218   1                              LED_DIS_D3=0;
  227.  219   1                              delay(1);
  228.  220   1                       } break;
  229.  221   1                       case 6:
  230.  222   1                      {       
  231.  223   1                              LED_DIS_D0=0;
  232.  224   1                              LED_DIS_D1=0;
  233.  225   1                              LED_DIS_D2=0;
  234.  226   1                              LED_DIS_D3=0;
  235.  227   1                              LED_DIS_A0=0;
  236.  228   1                              LED_DIS_A1=1;
  237.  229   1                              delay(1);
  238.  230   1                              LED_DIS_A0=1;
  239.  231   1                              LED_DIS_A1=0;
  240.  232   1                              LED_DIS_D0=0;
  241.  233   1                              LED_DIS_D1=1;
  242.  234   1                              LED_DIS_D2=1;
  243.  235   1                              LED_DIS_D3=0;
  244.  236   1                              delay(1);
  245.  237   1                       } break;
  246.  238   1                       case 7:
  247.  239   1                      {       LED_DIS_D0=0;
  248.  240   1                              LED_DIS_D1=0;
  249.  241   1                              LED_DIS_D2=0;
  250. C51 COMPILER V8.08   LED_DIS                                                               04/26/2008 20:29:08 PAGE 5   
  251.  242   1                              LED_DIS_D3=0;
  252.  243   1                              LED_DIS_A0=0;
  253.  244   1                              LED_DIS_A1=1;
  254.  245   1                              delay(1);
  255.  246   1                              LED_DIS_A0=1;
  256.  247   1                              LED_DIS_A1=0;
  257.  248   1                              LED_DIS_D0=1;
  258.  249   1                              LED_DIS_D1=1;
  259.  250   1                              LED_DIS_D2=1;
  260.  251   1                              LED_DIS_D3=0;
  261.  252   1                              delay(1);
  262.  253   1                       } break;
  263.  254   1                       case 8:
  264.  255   1                      {       
  265.  256   1                              LED_DIS_D0=0;
  266.  257   1                              LED_DIS_D1=0;
  267.  258   1                              LED_DIS_D2=0;
  268.  259   1                              LED_DIS_D3=0;
  269.  260   1                              LED_DIS_A0=0;
  270.  261   1                              LED_DIS_A1=1;
  271.  262   1                              delay(1);
  272.  263   1                              LED_DIS_A0=1;
  273.  264   1                              LED_DIS_A1=0;
  274.  265   1                              LED_DIS_D0=0;
  275.  266   1                              LED_DIS_D1=0;
  276.  267   1                              LED_DIS_D2=0;
  277.  268   1                              LED_DIS_D3=1;
  278.  269   1                              delay(1);
  279.  270   1                       } break;
  280.  271   1                       case 9:
  281.  272   1                      {       
  282.  273   1                              LED_DIS_D0=0;
  283.  274   1                              LED_DIS_D1=0;
  284.  275   1                              LED_DIS_D2=0;
  285.  276   1                              LED_DIS_D3=0;
  286.  277   1                              LED_DIS_A0=0;
  287.  278   1                              LED_DIS_A1=1;
  288.  279   1                              delay(1);
  289.  280   1                              LED_DIS_A0=1;
  290.  281   1                              LED_DIS_A1=0;
  291.  282   1                              LED_DIS_D0=1;
  292.  283   1                              LED_DIS_D1=0;
  293.  284   1                              LED_DIS_D2=0;
  294.  285   1                              LED_DIS_D3=1;
  295.  286   1                              delay(1);
  296.  287   1                       } break;         */
  297.  288   1              
  298.  289   1              
  299.  290   1                      
  300.  291   1      }
  301. MODULE INFORMATION:   STATIC OVERLAYABLE
  302.    CODE SIZE        =    175    ----
  303.    CONSTANT SIZE    =   ----    ----
  304.    XDATA SIZE       =   ----    ----
  305.    PDATA SIZE       =   ----    ----
  306.    DATA SIZE        =   ----    ----
  307.    IDATA SIZE       =   ----    ----
  308.    BIT SIZE         =   ----    ----
  309. END OF MODULE INFORMATION.
  310. C51 COMPILATION COMPLETE.  0 WARNING(S),  0 ERROR(S)