📄 stm32f10x_tim.lst
字号:
###############################################################################
# #
# IAR ANSI C/C++ Compiler V6.10.2.52244/W32 for ARM 07/Aug/2011 12:10:41 #
# Copyright 1999-2010 IAR Systems AB. #
# #
# Cpu mode = thumb #
# Endian = little #
# Source file = F:\stm32\我的程序\Micrium\Software\EWARM\BSP\ST\STM32F10 #
# x_StdPeriph_Driver\src\stm32f10x_tim.c #
# Command line = F:\stm32\我的程序\Micrium\Software\EWARM\BSP\ST\STM32F10 #
# x_StdPeriph_Driver\src\stm32f10x_tim.c -D #
# USE_STDPERIPH_DRIVER -D STM32F10X_CL -lCN #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\Flash\Lis #
# t\ -o F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\Fla #
# sh\Obj\ --no_cse --no_unroll --no_inline #
# --no_code_motion --no_tbaa --no_clustering #
# --no_scheduling --debug --endian=little --cpu=Cortex-M3 #
# -e --fpu=None --dlib_config #
# D:\arm\INC\c\DLib_Config_Normal.h -I #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\APP\ -I #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\..\BSP\ #
# -I F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\..\BSP #
# \ST\CMSIS\CM3\CoreSupport\ -I #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\..\BSP\ST #
# \CMSIS\CM3\DeviceSupport\ST\STM32F10x\ -I #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\..\BSP\ST #
# \STM32F10x_StdPeriph_Driver\inc\ -I #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\..\BSP\uC #
# OS-II\ -I F:\stm32\我的程序\Micrium\Software\EWARM\OS-II #
# \..\..\uCOS-II\Ports\ARM-Cortex-M3\Generic\IAR\ -I #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\..\..\uCO #
# S-II\Source\ -I F:\stm32\我的程序\Micrium\Software\EWARM #
# \OS-II\..\..\uC-LIB\ -I F:\stm32\我的程序\Micrium\Softwa #
# re\EWARM\OS-II\..\..\uC-LIB\Ports\ARM-Cortex-M3\IAR\ -I #
# F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\..\..\uC- #
# CPU\ -I F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\. #
# .\..\uC-CPU\ARM-Cortex-M3\IAR\ -On --use_c++_inline #
# List file = F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\Flash\Lis #
# t\stm32f10x_tim.lst #
# Object file = F:\stm32\我的程序\Micrium\Software\EWARM\OS-II\Flash\Obj #
# \stm32f10x_tim.o #
# #
# #
###############################################################################
F:\stm32\我的程序\Micrium\Software\EWARM\BSP\ST\STM32F10x_StdPeriph_Driver\src\stm32f10x_tim.c
1 /**
2 ******************************************************************************
3 * @file stm32f10x_tim.c
4 * @author MCD Application Team
5 * @version V3.4.0
6 * @date 10/15/2010
7 * @brief This file provides all the TIM firmware functions.
8 ******************************************************************************
9 * @copy
10 *
11 * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
12 * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
13 * TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY
14 * DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
15 * FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
16 * CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
17 *
18 * <h2><center>© COPYRIGHT 2010 STMicroelectronics</center></h2>
19 */
20
21 /* Includes ------------------------------------------------------------------*/
22 #include "stm32f10x_tim.h"
23 #include "stm32f10x_rcc.h"
24
25 /** @addtogroup STM32F10x_StdPeriph_Driver
26 * @{
27 */
28
29 /** @defgroup TIM
30 * @brief TIM driver modules
31 * @{
32 */
33
34 /** @defgroup TIM_Private_TypesDefinitions
35 * @{
36 */
37
38 /**
39 * @}
40 */
41
42 /** @defgroup TIM_Private_Defines
43 * @{
44 */
45
46 /* ---------------------- TIM registers bit mask ------------------------ */
47 #define SMCR_ETR_Mask ((uint16_t)0x00FF)
48 #define CCMR_Offset ((uint16_t)0x0018)
49 #define CCER_CCE_Set ((uint16_t)0x0001)
50 #define CCER_CCNE_Set ((uint16_t)0x0004)
51
52 /**
53 * @}
54 */
55
56 /** @defgroup TIM_Private_Macros
57 * @{
58 */
59
60 /**
61 * @}
62 */
63
64 /** @defgroup TIM_Private_Variables
65 * @{
66 */
67
68 /**
69 * @}
70 */
71
72 /** @defgroup TIM_Private_FunctionPrototypes
73 * @{
74 */
75
76 static void TI1_Config(TIM_TypeDef* TIMx, uint16_t TIM_ICPolarity, uint16_t TIM_ICSelection,
77 uint16_t TIM_ICFilter);
78 static void TI2_Config(TIM_TypeDef* TIMx, uint16_t TIM_ICPolarity, uint16_t TIM_ICSelection,
79 uint16_t TIM_ICFilter);
80 static void TI3_Config(TIM_TypeDef* TIMx, uint16_t TIM_ICPolarity, uint16_t TIM_ICSelection,
81 uint16_t TIM_ICFilter);
82 static void TI4_Config(TIM_TypeDef* TIMx, uint16_t TIM_ICPolarity, uint16_t TIM_ICSelection,
83 uint16_t TIM_ICFilter);
84 /**
85 * @}
86 */
87
88 /** @defgroup TIM_Private_Macros
89 * @{
90 */
91
92 /**
93 * @}
94 */
95
96 /** @defgroup TIM_Private_Variables
97 * @{
98 */
99
100 /**
101 * @}
102 */
103
104 /** @defgroup TIM_Private_FunctionPrototypes
105 * @{
106 */
107
108 /**
109 * @}
110 */
111
112 /** @defgroup TIM_Private_Functions
113 * @{
114 */
115
116 /**
117 * @brief Deinitializes the TIMx peripheral registers to their default reset values.
118 * @param TIMx: where x can be 1 to 17 to select the TIM peripheral.
119 * @retval None
120 */
\ In section .text, align 2, keep-with-next
121 void TIM_DeInit(TIM_TypeDef* TIMx)
122 {
\ TIM_DeInit:
\ 00000000 10B5 PUSH {R4,LR}
\ 00000002 0400 MOVS R4,R0
123 /* Check the parameters */
124 assert_param(IS_TIM_ALL_PERIPH(TIMx));
125
126 if (TIMx == TIM1)
\ 00000004 ........ LDR.W R0,??DataTable7 ;; 0x40012c00
\ 00000008 8442 CMP R4,R0
\ 0000000A 0AD1 BNE.N ??TIM_DeInit_0
127 {
128 RCC_APB2PeriphResetCmd(RCC_APB2Periph_TIM1, ENABLE);
\ 0000000C 0121 MOVS R1,#+1
\ 0000000E 4FF40060 MOV R0,#+2048
\ 00000012 ........ BL RCC_APB2PeriphResetCmd
129 RCC_APB2PeriphResetCmd(RCC_APB2Periph_TIM1, DISABLE);
\ 00000016 0021 MOVS R1,#+0
\ 00000018 4FF40060 MOV R0,#+2048
\ 0000001C ........ BL RCC_APB2PeriphResetCmd
\ 00000020 DDE0 B.N ??TIM_DeInit_1
130 }
131 else if (TIMx == TIM2)
\ ??TIM_DeInit_0:
\ 00000022 B4F1804F CMP R4,#+1073741824
\ 00000026 08D1 BNE.N ??TIM_DeInit_2
132 {
133 RCC_APB1PeriphResetCmd(RCC_APB1Periph_TIM2, ENABLE);
\ 00000028 0121 MOVS R1,#+1
\ 0000002A 0120 MOVS R0,#+1
\ 0000002C ........ BL RCC_APB1PeriphResetCmd
134 RCC_APB1PeriphResetCmd(RCC_APB1Periph_TIM2, DISABLE);
\ 00000030 0021 MOVS R1,#+0
\ 00000032 0120 MOVS R0,#+1
\ 00000034 ........ BL RCC_APB1PeriphResetCmd
\ 00000038 D1E0 B.N ??TIM_DeInit_1
135 }
136 else if (TIMx == TIM3)
\ ??TIM_DeInit_2:
\ 0000003A ........ LDR.W R0,??DataTable8 ;; 0x40000400
\ 0000003E 8442 CMP R4,R0
\ 00000040 08D1 BNE.N ??TIM_DeInit_3
137 {
138 RCC_APB1PeriphResetCmd(RCC_APB1Periph_TIM3, ENABLE);
\ 00000042 0121 MOVS R1,#+1
\ 00000044 0220 MOVS R0,#+2
\ 00000046 ........ BL RCC_APB1PeriphResetCmd
139 RCC_APB1PeriphResetCmd(RCC_APB1Periph_TIM3, DISABLE);
\ 0000004A 0021 MOVS R1,#+0
\ 0000004C 0220 MOVS R0,#+2
\ 0000004E ........ BL RCC_APB1PeriphResetCmd
\ 00000052 C4E0 B.N ??TIM_DeInit_1
140 }
141 else if (TIMx == TIM4)
\ ??TIM_DeInit_3:
\ 00000054 ........ LDR.W R0,??DataTable8_1 ;; 0x40000800
\ 00000058 8442 CMP R4,R0
\ 0000005A 08D1 BNE.N ??TIM_DeInit_4
142 {
143 RCC_APB1PeriphResetCmd(RCC_APB1Periph_TIM4, ENABLE);
\ 0000005C 0121 MOVS R1,#+1
\ 0000005E 0420 MOVS R0,#+4
\ 00000060 ........ BL RCC_APB1PeriphResetCmd
144 RCC_APB1PeriphResetCmd(RCC_APB1Periph_TIM4, DISABLE);
\ 00000064 0021 MOVS R1,#+0
\ 00000066 0420 MOVS R0,#+4
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -