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

📄 monitor.lst

📁 Texas-Instrument C2000 Series DSP example programs
💻 LST
📖 第 1 页 / 共 5 页
字号:
C:\DSP\2XX\DSPTOOLS\CGT\6.63B\dspa.exe -v2xx -iencoder\include -irs232\include -s -l monitor.asm monitor.obj -tC:\WINDOWS\TEMP\monitor.tmp 

TMS320C1x/C2x/C2xx/C5x COFF Assembler Beta Version 6.63  Mon Feb  9 04:57:53 1998
Copyright (c) 1987-1996  Texas Instruments Incorporated 
monitor.asm                                                          PAGE    1

       1            *******************************************************
       2            * TMS320C2x/C2xx/C5x ANSI C Codegen Beta Version 6.63       
       3            *******************************************************
       4            ;       C:\DSP\2XX\DSPTOOLS\CGT\6.63B\dspac.exe -v2xx -iencoder\include -irs232\include monitor.c C:\WINDOWS\TEM
       5            ;       C:\DSP\2XX\DSPTOOLS\CGT\6.63B\dspopt.exe -v2xx -s -O2 -Z C:\WINDOWS\TEMP\monitor.if C:\WINDOWS\TEMP\moni
       6            ;       C:\DSP\2XX\DSPTOOLS\CGT\6.63B\dspcg.exe -v2xx -o -s -o -n -o C:\WINDOWS\TEMP\monitor.opt C:\WINDOWS\TEMP
       7                    .port
       8 0000               .bss    _qep_sample$1,1,1
       9                    .file   "monitor.c"
      10                    .file   "c:\dsp\2xx\dsptools\cgt\6.63b\stdlib.h"
      11                    .sym    _size_t,0,14,13,16
      12                    .sym    _wchar_t,0,4,13,16
      13                    .globl  _atoi
      14                    .globl  _atol
      15                    .globl  _atof
      16                    .globl  _strtod
      17                    .globl  _strtol
      18                    .globl  _strtoul
      19            
      20                    .stag   __div_t,32
      21                    .member _quot,0,4,8,16
      22                    .member _rem,16,4,8,16
      23                    .eos
      24                    .sym    _div_t,0,8,13,32,__div_t
      25            
      26                    .stag   __ldiv_t,64
      27                    .member _quot,0,5,8,32
      28                    .member _rem,32,5,8,32
      29                    .eos
      30                    .sym    _ldiv_t,0,8,13,64,__ldiv_t
      31                    .globl  _div
      32                    .globl  _ldiv
      33                    .globl  _rand
      34                    .globl  _srand
      35                    .globl  _calloc
      36                    .globl  _free
      37                    .globl  _malloc
      38                    .globl  _minit
      39                    .globl  _realloc
      40                    .globl  _abort
      41                    .globl  _exit
      42                    .globl  _atexit
      43                    .globl  _abs
      44                    .globl  _labs
      45                    .globl  _qsort
      46                    .globl  _bsearch
      47                    .globl  _getenv
      48                    .globl  _ti_sprintf
      49                    .file   "c:\dsp\2xx\dsptools\cgt\6.63b\math.h"
      50                    .globl  _asin
      51                    .globl  _acos
      52                    .globl  _atan
      53                    .globl  _atan2
      54                    .globl  _ceil
TMS320C1x/C2x/C2xx/C5x COFF Assembler Beta Version 6.63  Mon Feb  9 04:57:53 1998
Copyright (c) 1987-1996  Texas Instruments Incorporated 
monitor.asm                                                          PAGE    2

      55                    .globl  _cos
      56                    .globl  _cosh
      57                    .globl  _exp
      58                    .globl  _fabs
      59                    .globl  _floor
      60                    .globl  _fmod
      61                    .globl  _frexp
      62                    .globl  _ldexp
      63                    .globl  _log
      64                    .globl  _log10
      65                    .globl  _modf
      66                    .globl  _pow
      67                    .globl  _sin
      68                    .globl  _sinh
      69                    .globl  _sqrt
      70                    .globl  _tan
      71                    .globl  _tanh
      72                    .file   "rs232\include\conio.h"
      73                    .globl  _getch
      74                    .globl  _putch
      75                    .globl  _clrscr
      76                    .globl  _sendstr_PMEM
      77                    .globl  _sendstr_DMEM
      78                    .globl  _getline
      79                    .globl  _getlong
      80                    .globl  _atol_F240
      81                    .globl  _read_PMEM
      82                    .file   "rs232\include\sci.h"
      83                    .globl  _SCI_Init
      84                    .globl  _kbhit
      85                    .globl  _SCI_Getc
      86                    .globl  _SCI_Sendc
      87                    .globl  _SCI_Rdy_to_Send
      88                    .file   "encoder\include\evm_qep.h"
      89                    .globl  _qep_rollover
      90                    .globl  _qep_diff
      91                    .globl  _QEP_GetIncr
      92                    .globl  _QEP_Init
      93                    .file   "encoder\include\encoder.h"
      94      2000  QEP_ROLLOVER  .set 8192 
      95                    .globl  _encoder_position
      96                    .globl  _Encoder_Init
      97                    .globl  _Encoder_ZeroPosition
      98                    .globl  _Encoder_MatchIncrPhase
      99                    .globl  _Encoder_CalcPhase
     100                    .globl  _Encoder_SamplePosition
     101                    .globl  _Encoder_CalcPosition
     102                    .file   "monitor.h"
     103                    .globl  _monitor
     104                    .globl  _Encoder_MSG
     105                    .file   "monitor.c"
     106 0000               .text
     107            
     108                    .sym    _monitor,_monitor,32,2,0
TMS320C1x/C2x/C2xx/C5x COFF Assembler Beta Version 6.63  Mon Feb  9 04:57:53 1998
Copyright (c) 1987-1996  Texas Instruments Incorporated 
monitor.asm                                                          PAGE    3

     109                    .globl  _monitor
     110            
     111                    .func   49
     112            ;>>>>   void monitor(void)
     113            ;>>>>      char c;
     114            ******************************************************
     115            * FUNCTION DEF : _monitor
     116            ******************************************************
     117 0000       _monitor:
     118 0000 8aa0          POPD    *+
     119 0001 80a0          SAR     AR0,*+
     120 0002 8180          SAR     AR1,*
     121 0003 b029          LARK    AR0,41
     122 0004 00e0          LAR     AR0,*0+
     123            ;       <save register vars>
     124 0005 86a0          SAR     AR6,*+
     125 0006 87af          SAR     AR7,*+,AR7
     126 0007 b701          LARK    AR7,1
     127 0008 8bea          MAR     *0+,AR2
     128            
     129            
     130                    .sym    _qep_sample,_qep_sample$1,14,3,16
     131            *
     132            * AR5   assigned to variable  c
     133            * AR5   assigned to variable  i
     134            * AR6   assigned to temp var  L$1
     135            * AR6   assigned to temp var  L$2
     136            * AR6   assigned to temp var  L$3
     137            * AR6   assigned to temp var  L$4
     138            * AR6   assigned to temp var  L$5
     139            * AR6   assigned to temp var  L$6
     140            *  ---  c shares AUTO storage with Y$3
     141            *
     142            *** 52  -----------------------    b[0] = 0;
     143                    .sym    Y$1,1,14,1,16
     144                    .sym    Y$2,2,4,1,16
     145                    .sym    _c,3,4,1,16
     146                    .sym    _b,4,52,1,160,,10
     147                    .sym    _str,14,52,1,320,,20
     148                    .sym    _val,34,52,1,48,,3
     149                    .sym    _angle,37,15,1,32
     150                    .sym    _fbuffer,39,6,1,32
     151                    .line   4
     152            ;>>>>      char b[10]="";
     153            ;>>>>      char str[20];               /* general purpose buffer */
     154            ;>>>>      int i;                      /* general purpose counter */
     155            ;>>>>      int val[3];
     156            ;>>>>      static unsigned qep_sample;
     157            ;>>>>      volatile unsigned long  angle;
     158            ;>>>>      volatile float fbuffer;
     159 0009 b900          LACK    0
     160 000a b204          LARK    AR2,4
     161 000b 8be0          MAR     *0+
     162 000c 9089          SACL    * ,AR1
TMS320C1x/C2x/C2xx/C5x COFF Assembler Beta Version 6.63  Mon Feb  9 04:57:53 1998
Copyright (c) 1987-1996  Texas Instruments Incorporated 
monitor.asm                                                          PAGE    4

     163            *** 63  -----------------------    SCI_Init(130u);
     164                    .line   15
     165            ;>>>>      SCI_Init(((SYSCLK*10)/8/BAUDRATE+5)/10);
     166            ;>>>>      for (;;)
     167            ;>>>>         clrscr(); 
     168            ;>>>>         sendstr_PMEM(header);
     169            ;>>>>         sendstr_PMEM("\rMain Menu\r");
     170            ;>>>>         sendstr_PMEM("\r\t1) Encoder Initialization");
     171            ;>>>>         sendstr_PMEM("\r\t2) ADC1,2 & QEP Test");
     172            ;>>>>         sendstr_PMEM("\r\t3) Print Encoder Increment & Phase");
     173            ;>>>>         sendstr_PMEM("\r\t4) Print Position (1/1000 Degrees)");
     174            ;>>>>         sendstr_PMEM("\r\r Press '1'..'4'. Please make your choice. \r");
     175            ;>>>>         for (c = 0; c<'1' || c>'6';c = SCI_Getc());
     176            ;>>>>         switch (c)
     177            ;>>>>            case '1': /*------------------------*/
     178            ;>>>>                      Encoder_Init(QEP_ROLLOVER);
     179            ;>>>>                      sendstr_PMEM("\r\r");                 
     180            ;>>>>                      sendstr_PMEM(" +--------------------+\r");
     181            ;>>>>                      sendstr_PMEM(" | Encoder setup done |\r");          /* Screen Output */
     182            ;>>>>                      sendstr_PMEM(" +--------------------+\r");
     183            ;>>>>                      sendstr_PMEM(" >> Press any key to confirm\r");
     184            ;>>>>                      for (c=0; c==0; c = (kbhit() ? getch() : 0) );
     185            ;>>>>                      break; 
     186            ;>>>>            case '2': /*----------------*/
     187            ;>>>>                      clrscr();
     188            ;>>>>                      sendstr_PMEM("\rInput from ADC1, ADC2, QEP: 000000 000000 000000");
     189            ;>>>>                      do
     190            ;>>>>                         sendstr_PMEM("\b\b\b\b\b\b\b\b\b\b\b\b\b\b");
     191            ;>>>>                         sendstr_PMEM("\b\b\b\b\b\b\b");
     192            ;>>>>                         ADC_START(5,13);
     193            ;>>>>                         ADC_READ2(val[0],val[1]);
     194            ;>>>>                         val[0] = (val[0] - ENC_U0_OFFSET) << 1;
     195            ;>>>>                         val[1] = (val[1] - ENC_U90_OFFSET)<< 1;
     196            ;>>>>                         #ifndef QEP_POWER2
     197            ;>>>>                            val[2] = QEP_GetIncr();
     198            ;>>>>                         #else
     199            ;>>>>                            val[2] = (T2CNT - qep_diff) & (QEP_ROLLOVER-1);
     200            ;>>>>                         #endif
     201            ;>>>>                         ltoa ((long)val[0], str);
     202            ;>>>>                         for (i=strlen(str); i<7; i++)
     203            ;>>>>                            sendstr_PMEM(" ");
     204            ;>>>>                         sendstr_DMEM(str);
     205            ;>>>>                        ltoa ((long)val[1], str);
     206            ;>>>>                        for (i=strlen(str); i<7; i++)
     207            ;>>>>                           sendstr_PMEM(" ");
     208            ;>>>>                        sendstr_DMEM(str);
     209            ;>>>>                        ltoa ((unsigned long)val[2], str);
     210            ;>>>>                        for (i=strlen(str); i<7; i++)
     211            ;>>>>                           sendstr_PMEM(" ");
     212            ;>>>>                        sendstr_DMEM(str);
     213            ;>>>>                     } while( SCI_Getc() == -1 );
     214            ;>>>>                     break;
     215            ;>>>>            case '3': /*----------------------------------*/
     216            ;>>>>                      clrscr();
TMS320C1x/C2x/C2xx/C5x COFF Assembler Beta Version 6.63  Mon Feb  9 04:57:53 1998
Copyright (c) 1987-1996  Texas Instruments Incorporated 
monitor.asm                                                          PAGE    5

     217            ;>>>>                      sendstr_PMEM("\rSIN/COS Q-Encoder, Increments, Phase: 000000 000000");
     218            ;>>>>                      do
     219            ;>>>>                         sendstr_PMEM("\b\b\b\b\b\b\b\b\b\b\b\b\b\b");
     220            ;>>>>                         qep_sample = Encoder_SamplePosition();
     221            ;>>>>                         Encoder_CalcPosition(qep_sample);
     222            ;>>>>                         ltoa ((unsigned long) encoder_position[1], str);
     223            ;>>>>                         for (i=strlen(str); i<7; i++)
     224            ;>>>>                            sendstr_PMEM(" ");
     225            ;>>>>                        sendstr_DMEM(str);
     226            ;>>>>                         ltoa ((unsigned long) encoder_position[0], str);
     227            ;>>>>                         for (i=strlen(str); i<7; i++)
     228            ;>>>>                            sendstr_PMEM(" ");
     229            ;>>>>                        sendstr_DMEM(str);
     230            ;>>>>                     } while( SCI_Getc() == -1 );
     231            ;>>>>                     break;
     232            ;>>>>            case '4': /*----------------*/
     233 000d b982          LACK    130
     234 000e 90a0          SACL    *+
     235 000f 7a80          CALL    _SCI_Init
         0010 0000! 
     236 0011 8b90          MAR     *-
     237            *** 63  -----------------------    goto g37;
     238 0012 7980          B       L37
         0013 01ef' 
     239 0014       L1:
     240            ***     -----------------------g1:
     241            *** 179 -----------------------    clrscr();
     242                    .line   131
     243            ;>>>>                      clrscr();
     244 0014 7a89          CALL    _clrscr,AR1
         0015 0000! 
     245            *** 180 -----------------------    sendstr_PMEM("\rAngle (1/1000 * Degrees): 000000000");
     246                    .line   132
     247            ;>>>>                      sendstr_PMEM("\rAngle (1/1000 * Degrees): 000000000");
     248            ;>>>>                      do
     249 0016 bf0b          LRLK    AR3,SL0
         0017 0000+ 
     250 0018 83a0          SAR     AR3,*+
     251 0019 7a80          CALL    _sendstr_PMEM
         001a 0000! 
     252 001b 8b90          MAR     *-
     253 001c       L3:
     254            ***     -----------------------g3:
     255            *** 184 -----------------------    sendstr_PMEM("\b\b\b\b\b\b\b\b\b\b");
     256                    .line   136
     257            ;>>>>                         sendstr_PMEM("\b\b\b\b\b\b\b\b\b\b");
     258 001c bf0b          LRLK    AR3,SL1
         001d 0025+ 
     259 001e 83a0          SAR     AR3,*+
     260 001f 7a80          CALL    _sendstr_PMEM
         0020 0000! 

⌨️ 快捷键说明

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