probe_com_os.lst

来自「针对STM32F103的UCOS移植」· LST 代码 · 共 390 行 · 第 1/2 页

LST
390
字号
    125              OSEventNameSet(ProbeCom_OS_Sem, (CPU_INT08U *)"uC/Probe Com", &err);
   \   0000000C   6A46               MOV      R2,SP
   \   0000000E   0249               LDR.N    R1,??ProbeCom_OS_Init_0  ;; `?<Constant "uC/Probe Com">`
   \   00000010   ........           _BLF     OSEventNameSet,??OSEventNameSet??rT
    126          #else
    127          #if (OS_EVENT_NAME_SIZE > 10)
    128              OSEventNameSet(ProbeCom_OS_Sem, (CPU_INT08U *)"Probe Com", &err);
    129          #endif
    130          #endif
    131          #endif
    132          }
   \   00000014   11BD               POP      {R0,R4,PC}       ;; return
   \   00000016   00BF               Nop      
   \                     ??ProbeCom_OS_Init_0:
   \   00000018   ........           DC32     `?<Constant "uC/Probe Com">`
    133          #endif
    134          
    135          /*
    136          *********************************************************************************************************
    137          *                                   Delay for a Certain Number of Ticks
    138          *
    139          * Description: This function implements a delay of a certain number of ticks.
    140          *
    141          * Argument(s): None.
    142          *
    143          * Returns    : None
    144          *********************************************************************************************************
    145          */
    146          
    147          #if (PROBE_COM_SUPPORT_STR > 0)

   \                                 In segment CODE, align 4, keep-with-next
    148          void  ProbeCom_OS_Dly (CPU_INT16U  dly)
    149          {
   \                     ProbeCom_OS_Dly:
   \   00000000   00B5               PUSH     {LR}
    150              OSTimeDly(dly);
   \   00000002   ........           _BLF     OSTimeDly,??OSTimeDly??rT
    151          }
   \   00000006   00BD               POP      {PC}             ;; return
    152          #endif
    153          
    154          
    155          /*
    156          *********************************************************************************************************
    157          *                                       Obtain String Buffer Lock
    158          *
    159          * Description: This function causes the calling task to obtain write access to the string buffer, waiting
    160          *              (if required) until it the buffer has been released by another task.
    161          *
    162          * Argument(s): wait     specifies whether the function should wait until the semaphore is available
    163          *                       or just check if the semaphore is available and, if it is, then accept it.
    164          *
    165          * Returns    : DEF_TRUE  if the semaphore was     obtained
    166          *              DEF_FALSE if the semaphore was NOT obtained
    167          *********************************************************************************************************
    168          */
    169          
    170          #if (PROBE_COM_SUPPORT_STR > 0)

   \                                 In segment CODE, align 4, keep-with-next
    171          CPU_BOOLEAN  ProbeCom_OS_Pend (CPU_BOOLEAN wait)
    172          {
   \                     ProbeCom_OS_Pend:
   \   00000000   01B5               PUSH     {R0,LR}
   \   00000002   0100               MOVS     R1,R0
    173          #if (OS_SEM_EN > 0)
    174              CPU_INT08U  tmp;
    175          
    176          
    177              if (wait == DEF_TRUE) {
   \   00000004   ....               LDR.N    R0,??DataTable2  ;; ProbeCom_OS_Sem
   \   00000006   0068               LDR      R0,[R0, #+0]
   \   00000008   0129               CMP      R1,#+1
   \   0000000A   0BD1               BNE.N    ??ProbeCom_OS_Pend_0
    178                  OSSemPend(ProbeCom_OS_Sem, 0, &tmp);                        /* Wait for string buffer to be released                */
   \   0000000C   6A46               MOV      R2,SP
   \   0000000E   0021               MOVS     R1,#+0
   \   00000010   ........           _BLF     OSSemPend,??OSSemPend??rT
    179          
    180                  if (tmp != OS_NO_ERR) {
   \   00000014   9DF80000           LDRB     R0,[SP, #+0]
   \   00000018   0028               CMP      R0,#+0
   \   0000001A   01D0               BEQ.N    ??ProbeCom_OS_Pend_1
    181                      return (DEF_FALSE);
   \   0000001C   0020               MOVS     R0,#+0
   \   0000001E   02BD               POP      {R1,PC}
    182                  } else {
    183                      return (DEF_TRUE);
   \                     ??ProbeCom_OS_Pend_1:
   \   00000020   0120               MOVS     R0,#+1
   \   00000022   02BD               POP      {R1,PC}
    184                  }
    185              } else {
    186                  tmp = OSSemAccept(ProbeCom_OS_Sem);                         /* Wait for string buffer to be released                */
   \                     ??ProbeCom_OS_Pend_0:
   \   00000024   ........           _BLF     OSSemAccept,??OSSemAccept??rT
   \   00000028   8DF80000           STRB     R0,[SP, #+0]
    187          
    188                  if (tmp == 0) {
   \   0000002C   9DF80000           LDRB     R0,[SP, #+0]
   \   00000030   0028               CMP      R0,#+0
   \   00000032   00D1               BNE.N    ??ProbeCom_OS_Pend_2
    189                      return (DEF_FALSE);
   \   00000034   02BD               POP      {R1,PC}
    190                  } else {
    191                      return (DEF_TRUE);
   \                     ??ProbeCom_OS_Pend_2:
   \   00000036   0120               MOVS     R0,#+1
   \   00000038   02BD               POP      {R1,PC}          ;; return
    192                  }
    193              }
    194          #else
    195              return (DEF_TRUE);
    196          #endif
    197          }
    198          #endif
    199          
    200          
    201          /*
    202          *********************************************************************************************************
    203          *                                       Release String Buffer Lock
    204          *
    205          * Description: This function releases the lock on write access to the string buffer.
    206          *
    207          * Argument(s): None
    208          *
    209          * Returns    : None
    210          *********************************************************************************************************
    211          */
    212          
    213          #if (PROBE_COM_SUPPORT_STR > 0)

   \                                 In segment CODE, align 4, keep-with-next
    214          void  ProbeCom_OS_Post (void)
    215          {
   \                     ProbeCom_OS_Post:
   \   00000000   00B5               PUSH     {LR}
    216          #if (OS_SEM_EN > 0)
    217              OSSemPost(ProbeCom_OS_Sem);                                     /* String buffer is being released                      */
   \   00000002   ....               LDR.N    R0,??DataTable2  ;; ProbeCom_OS_Sem
   \   00000004   0068               LDR      R0,[R0, #+0]
   \   00000006   ........           _BLF     OSSemPost,??OSSemPost??rT
    218          #endif
    219          }
   \   0000000A   00BD               POP      {PC}             ;; return

   \                                 In segment CODE, align 4, keep-with-next
   \                     ??DataTable2:
   \   00000000   ........           DC32     ProbeCom_OS_Sem

   \                                 In segment DATA_C, align 4, align-sorted
   \                     `?<Constant "uC/Probe Com">`:
   \   00000000   75432F50726F       DC8 "uC/Probe Com"
   \              626520436F6D
   \              00          
   \   0000000D   000000             DC8 0, 0, 0
    220          #endif

   Maximum stack usage in bytes:

     Function         CSTACK
     --------         ------
     ProbeCom_OS_Dly      4
     ProbeCom_OS_Init    12
     ProbeCom_OS_Pend     8
     ProbeCom_OS_Post     4


   Segment part sizes:

     Function/Label             Bytes
     --------------             -----
     ProbeCom_OS_Sem               4
     ProbeCom_OS_Init             28
     ProbeCom_OS_Dly               8
     ProbeCom_OS_Pend             58
     ProbeCom_OS_Post             12
     ??DataTable2                  4
     ?<Constant "uC/Probe Com">   16
      Others                      60

 
 158 bytes in segment CODE
  16 bytes in segment DATA_C
   4 bytes in segment DATA_Z
  12 bytes in segment INITTAB
 
 110 bytes of CODE  memory (+ 60 bytes shared)
  16 bytes of CONST memory
   4 bytes of DATA  memory

Errors: none
Warnings: none

⌨️ 快捷键说明

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