stm32f7xx_hal_tim_ex.h
Go to the documentation of this file.
1 
20 /* Define to prevent recursive inclusion -------------------------------------*/
21 #ifndef STM32F7xx_HAL_TIM_EX_H
22 #define STM32F7xx_HAL_TIM_EX_H
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
28 /* Includes ------------------------------------------------------------------*/
29 #include "stm32f7xx_hal_def.h"
30 
39 /* Exported types ------------------------------------------------------------*/
48 typedef struct
49 {
50  uint32_t IC1Polarity;
53  uint32_t IC1Prescaler;
56  uint32_t IC1Filter;
59  uint32_t Commutation_Delay;
62 #if defined(TIM_BREAK_INPUT_SUPPORT)
63 
67 typedef struct
68 {
69  uint32_t Source;
71  uint32_t Enable;
73  uint32_t Polarity;
76 }
77 TIMEx_BreakInputConfigTypeDef;
78 
79 #endif /* TIM_BREAK_INPUT_SUPPORT */
80 
83 /* End of exported types -----------------------------------------------------*/
84 
85 /* Exported constants --------------------------------------------------------*/
93 #define TIM_TIM2_TIM8_TRGO (0x00000000U)
94 #define TIM_TIM2_ETH_PTP (0x00000400U)
95 #define TIM_TIM2_USBFS_SOF (0x00000800U)
96 #define TIM_TIM2_USBHS_SOF (0x00000C00U)
97 #define TIM_TIM5_GPIO (0x00000000U)
98 #define TIM_TIM5_LSI (0x00000040U)
99 #define TIM_TIM5_LSE (0x00000080U)
100 #define TIM_TIM5_RTC (0x000000C0U)
101 #define TIM_TIM11_GPIO (0x00000000U)
102 #define TIM_TIM11_SPDIFRX (0x00000001U)
103 #define TIM_TIM11_HSE (0x00000002U)
104 #define TIM_TIM11_MCO1 (0x00000003U)
105 
108 #if defined(TIM_BREAK_INPUT_SUPPORT)
109 
113 #define TIM_BREAKINPUT_BRK 0x00000001U /* !< Timer break input */
114 #define TIM_BREAKINPUT_BRK2 0x00000002U /* !< Timer break2 input */
115 
122 #define TIM_BREAKINPUTSOURCE_BKIN ((uint32_t)0x00000001U) /* !< An external source (GPIO) is connected to the BKIN pin */
123 #define TIM_BREAKINPUTSOURCE_DFSDM1 ((uint32_t)0x00000008U) /* !< The analog watchdog output of the DFSDM1 peripheral is connected to the break input */
124 
131 #define TIM_BREAKINPUTSOURCE_DISABLE 0x00000000U /* !< Break input source is disabled */
132 #define TIM_BREAKINPUTSOURCE_ENABLE 0x00000001U /* !< Break input source is enabled */
133 
140 #define TIM_BREAKINPUTSOURCE_POLARITY_LOW 0x00000001U /* !< Break input source is active low */
141 #define TIM_BREAKINPUTSOURCE_POLARITY_HIGH 0x00000000U /* !< Break input source is active_high */
142 
145 #endif /* TIM_BREAK_INPUT_SUPPORT */
146 
150 /* End of exported constants -------------------------------------------------*/
151 
152 /* Exported macro ------------------------------------------------------------*/
160 /* End of exported macro -----------------------------------------------------*/
161 
162 /* Private macro -------------------------------------------------------------*/
166 #define IS_TIM_REMAP(__TIM_REMAP__) (((__TIM_REMAP__) == TIM_TIM2_TIM8_TRGO)||\
167  ((__TIM_REMAP__) == TIM_TIM2_ETH_PTP) ||\
168  ((__TIM_REMAP__) == TIM_TIM2_USBFS_SOF)||\
169  ((__TIM_REMAP__) == TIM_TIM2_USBHS_SOF)||\
170  ((__TIM_REMAP__) == TIM_TIM5_GPIO) ||\
171  ((__TIM_REMAP__) == TIM_TIM5_LSI) ||\
172  ((__TIM_REMAP__) == TIM_TIM5_LSE) ||\
173  ((__TIM_REMAP__) == TIM_TIM5_RTC) ||\
174  ((__TIM_REMAP__) == TIM_TIM11_GPIO) ||\
175  ((__TIM_REMAP__) == TIM_TIM11_SPDIFRX) ||\
176  ((__TIM_REMAP__) == TIM_TIM11_HSE) ||\
177  ((__TIM_REMAP__) == TIM_TIM11_MCO1))
178 #if defined(TIM_BREAK_INPUT_SUPPORT)
179 
180 #define IS_TIM_BREAKINPUT(__BREAKINPUT__) (((__BREAKINPUT__) == TIM_BREAKINPUT_BRK) || \
181  ((__BREAKINPUT__) == TIM_BREAKINPUT_BRK2))
182 
183 #define IS_TIM_BREAKINPUTSOURCE(__SOURCE__) (((__SOURCE__) == TIM_BREAKINPUTSOURCE_BKIN) || \
184  ((__SOURCE__) == TIM_BREAKINPUTSOURCE_DFSDM))
185 
186 #define IS_TIM_BREAKINPUTSOURCE_STATE(__STATE__) (((__STATE__) == TIM_BREAKINPUTSOURCE_DISABLE) || \
187  ((__STATE__) == TIM_BREAKINPUTSOURCE_ENABLE))
188 
189 #define IS_TIM_BREAKINPUTSOURCE_POLARITY(__POLARITY__) (((__POLARITY__) == TIM_BREAKINPUTSOURCE_POLARITY_LOW) || \
190  ((__POLARITY__) == TIM_BREAKINPUTSOURCE_POLARITY_HIGH))
191 #endif /* TIM_BREAK_INPUT_SUPPORT */
192 
196 /* End of private macro ------------------------------------------------------*/
197 
198 /* Exported functions --------------------------------------------------------*/
207 /* Timer Hall Sensor functions **********************************************/
210 
213 
214 /* Blocking mode: Polling */
217 /* Non-Blocking mode: Interrupt */
220 /* Non-Blocking mode: DMA */
221 HAL_StatusTypeDef HAL_TIMEx_HallSensor_Start_DMA(TIM_HandleTypeDef *htim, uint32_t *pData, uint16_t Length);
231 /* Timer Complementary Output Compare functions *****************************/
232 /* Blocking mode: Polling */
235 
236 /* Non-Blocking mode: Interrupt */
239 
240 /* Non-Blocking mode: DMA */
241 HAL_StatusTypeDef HAL_TIMEx_OCN_Start_DMA(TIM_HandleTypeDef *htim, uint32_t Channel, uint32_t *pData, uint16_t Length);
251 /* Timer Complementary PWM functions ****************************************/
252 /* Blocking mode: Polling */
255 
256 /* Non-Blocking mode: Interrupt */
259 /* Non-Blocking mode: DMA */
260 HAL_StatusTypeDef HAL_TIMEx_PWMN_Start_DMA(TIM_HandleTypeDef *htim, uint32_t Channel, uint32_t *pData, uint16_t Length);
270 /* Timer Complementary One Pulse functions **********************************/
271 /* Blocking mode: Polling */
272 HAL_StatusTypeDef HAL_TIMEx_OnePulseN_Start(TIM_HandleTypeDef *htim, uint32_t OutputChannel);
273 HAL_StatusTypeDef HAL_TIMEx_OnePulseN_Stop(TIM_HandleTypeDef *htim, uint32_t OutputChannel);
274 
275 /* Non-Blocking mode: Interrupt */
286 /* Extended Control functions ************************************************/
288  uint32_t CommutationSource);
290  uint32_t CommutationSource);
292  uint32_t CommutationSource);
294  TIM_MasterConfigTypeDef *sMasterConfig);
296  TIM_BreakDeadTimeConfigTypeDef *sBreakDeadTimeConfig);
297 #if defined(TIM_BREAK_INPUT_SUPPORT)
298 HAL_StatusTypeDef HAL_TIMEx_ConfigBreakInput(TIM_HandleTypeDef *htim, uint32_t BreakInput,
299  TIMEx_BreakInputConfigTypeDef *sBreakInputConfig);
300 #endif /* TIM_BREAK_INPUT_SUPPORT */
311 /* Extended Callback **********************************************************/
324 /* Extended Peripheral State functions ***************************************/
333 /* End of exported functions -------------------------------------------------*/
334 
335 /* Private functions----------------------------------------------------------*/
344 /* End of private functions --------------------------------------------------*/
345 
354 #ifdef __cplusplus
355 }
356 #endif
357 
358 
359 #endif /* STM32F7xx_HAL_TIM_EX_H */
360 
361 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
HAL_TIMEx_PWMN_Start
HAL_StatusTypeDef HAL_TIMEx_PWMN_Start(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_RemapConfig
HAL_StatusTypeDef HAL_TIMEx_RemapConfig(TIM_HandleTypeDef *htim, uint32_t Remap)
HAL_StatusTypeDef
HAL_StatusTypeDef
HAL Status structures definition
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_def.h:40
HAL_TIMEx_HallSensor_MspDeInit
void HAL_TIMEx_HallSensor_MspDeInit(TIM_HandleTypeDef *htim)
HAL_TIMEx_PWMN_Start_DMA
HAL_StatusTypeDef HAL_TIMEx_PWMN_Start_DMA(TIM_HandleTypeDef *htim, uint32_t Channel, uint32_t *pData, uint16_t Length)
HAL_TIMEx_OCN_Stop_DMA
HAL_StatusTypeDef HAL_TIMEx_OCN_Stop_DMA(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_CommutHalfCpltCallback
void HAL_TIMEx_CommutHalfCpltCallback(TIM_HandleTypeDef *htim)
__DMA_HandleTypeDef
DMA handle Structure definition.
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_dma.h:139
HAL_TIMEx_OnePulseN_Stop_IT
HAL_StatusTypeDef HAL_TIMEx_OnePulseN_Stop_IT(TIM_HandleTypeDef *htim, uint32_t OutputChannel)
HAL_TIMEx_BreakCallback
void HAL_TIMEx_BreakCallback(TIM_HandleTypeDef *htim)
HAL_TIMEx_HallSensor_MspInit
void HAL_TIMEx_HallSensor_MspInit(TIM_HandleTypeDef *htim)
HAL_TIMEx_ConfigCommutEvent
HAL_StatusTypeDef HAL_TIMEx_ConfigCommutEvent(TIM_HandleTypeDef *htim, uint32_t InputTrigger, uint32_t CommutationSource)
HAL_TIMEx_HallSensor_Start_IT
HAL_StatusTypeDef HAL_TIMEx_HallSensor_Start_IT(TIM_HandleTypeDef *htim)
TIMEx_DMACommutationCplt
void TIMEx_DMACommutationCplt(DMA_HandleTypeDef *hdma)
HAL_TIMEx_PWMN_Start_IT
HAL_StatusTypeDef HAL_TIMEx_PWMN_Start_IT(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_OnePulseN_Start
HAL_StatusTypeDef HAL_TIMEx_OnePulseN_Start(TIM_HandleTypeDef *htim, uint32_t OutputChannel)
HAL_TIMEx_OCN_Stop_IT
HAL_StatusTypeDef HAL_TIMEx_OCN_Stop_IT(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_ConfigCommutEvent_IT
HAL_StatusTypeDef HAL_TIMEx_ConfigCommutEvent_IT(TIM_HandleTypeDef *htim, uint32_t InputTrigger, uint32_t CommutationSource)
HAL_TIMEx_Break2Callback
void HAL_TIMEx_Break2Callback(TIM_HandleTypeDef *htim)
HAL_TIMEx_OnePulseN_Stop
HAL_StatusTypeDef HAL_TIMEx_OnePulseN_Stop(TIM_HandleTypeDef *htim, uint32_t OutputChannel)
TIM_HallSensor_InitTypeDef
TIM Hall sensor Configuration Structure definition.
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_tim_ex.h:48
HAL_TIMEx_PWMN_Stop_IT
HAL_StatusTypeDef HAL_TIMEx_PWMN_Stop_IT(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_PWMN_Stop
HAL_StatusTypeDef HAL_TIMEx_PWMN_Stop(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_OCN_Stop
HAL_StatusTypeDef HAL_TIMEx_OCN_Stop(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_OCN_Start
HAL_StatusTypeDef HAL_TIMEx_OCN_Start(TIM_HandleTypeDef *htim, uint32_t Channel)
TIM_HandleTypeDef
TIM Time Base Handle Structure definition.
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_tim.h:315
HAL_TIMEx_HallSensor_Stop_DMA
HAL_StatusTypeDef HAL_TIMEx_HallSensor_Stop_DMA(TIM_HandleTypeDef *htim)
HAL_TIMEx_HallSensor_Start_DMA
HAL_StatusTypeDef HAL_TIMEx_HallSensor_Start_DMA(TIM_HandleTypeDef *htim, uint32_t *pData, uint16_t Length)
HAL_TIMEx_HallSensor_Init
HAL_StatusTypeDef HAL_TIMEx_HallSensor_Init(TIM_HandleTypeDef *htim, TIM_HallSensor_InitTypeDef *sConfig)
HAL_TIM_StateTypeDef
HAL_TIM_StateTypeDef
HAL State structures definition.
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_tim.h:288
HAL_TIMEx_HallSensor_Stop
HAL_StatusTypeDef HAL_TIMEx_HallSensor_Stop(TIM_HandleTypeDef *htim)
HAL_TIMEx_CommutCallback
void HAL_TIMEx_CommutCallback(TIM_HandleTypeDef *htim)
HAL_TIMEx_PWMN_Stop_DMA
HAL_StatusTypeDef HAL_TIMEx_PWMN_Stop_DMA(TIM_HandleTypeDef *htim, uint32_t Channel)
HAL_TIMEx_OnePulseN_Start_IT
HAL_StatusTypeDef HAL_TIMEx_OnePulseN_Start_IT(TIM_HandleTypeDef *htim, uint32_t OutputChannel)
HAL_TIMEx_OCN_Start_IT
HAL_StatusTypeDef HAL_TIMEx_OCN_Start_IT(TIM_HandleTypeDef *htim, uint32_t Channel)
stm32f7xx_hal_def.h
This file contains HAL common defines, enumeration, macros and structures definitions.
HAL_TIMEx_HallSensor_Start
HAL_StatusTypeDef HAL_TIMEx_HallSensor_Start(TIM_HandleTypeDef *htim)
TIM_MasterConfigTypeDef
TIM Master configuration Structure definition.
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_tim.h:229
HAL_TIMEx_MasterConfigSynchronization
HAL_StatusTypeDef HAL_TIMEx_MasterConfigSynchronization(TIM_HandleTypeDef *htim, TIM_MasterConfigTypeDef *sMasterConfig)
HAL_TIMEx_HallSensor_GetState
HAL_TIM_StateTypeDef HAL_TIMEx_HallSensor_GetState(TIM_HandleTypeDef *htim)
HAL_TIMEx_ConfigCommutEvent_DMA
HAL_StatusTypeDef HAL_TIMEx_ConfigCommutEvent_DMA(TIM_HandleTypeDef *htim, uint32_t InputTrigger, uint32_t CommutationSource)
HAL_TIMEx_GroupChannel5
HAL_StatusTypeDef HAL_TIMEx_GroupChannel5(TIM_HandleTypeDef *htim, uint32_t Channels)
TIMEx_DMACommutationHalfCplt
void TIMEx_DMACommutationHalfCplt(DMA_HandleTypeDef *hdma)
HAL_TIMEx_HallSensor_DeInit
HAL_StatusTypeDef HAL_TIMEx_HallSensor_DeInit(TIM_HandleTypeDef *htim)
TIM_BreakDeadTimeConfigTypeDef
TIM Break input(s) and Dead time configuration Structure definition.
Definition: stm32f407/stm32f407g-disc1/Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_tim.h:265
HAL_TIMEx_ConfigBreakDeadTime
HAL_StatusTypeDef HAL_TIMEx_ConfigBreakDeadTime(TIM_HandleTypeDef *htim, TIM_BreakDeadTimeConfigTypeDef *sBreakDeadTimeConfig)
HAL_TIMEx_OCN_Start_DMA
HAL_StatusTypeDef HAL_TIMEx_OCN_Start_DMA(TIM_HandleTypeDef *htim, uint32_t Channel, uint32_t *pData, uint16_t Length)
HAL_TIMEx_HallSensor_Stop_IT
HAL_StatusTypeDef HAL_TIMEx_HallSensor_Stop_IT(TIM_HandleTypeDef *htim)


picovoice_driver
Author(s):
autogenerated on Fri Apr 1 2022 02:14:53