Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of TUKS-COURSE-TIMER by
Time Encoder functions
[TIM Exported Functions]
Time Encoder functions. More...
Functions | |
HAL_StatusTypeDef | HAL_TIM_Encoder_Init (TIM_HandleTypeDef *htim, TIM_Encoder_InitTypeDef *sConfig) |
Initializes the TIM Encoder Interface and initialize the associated handle. | |
HAL_StatusTypeDef | HAL_TIM_Encoder_DeInit (TIM_HandleTypeDef *htim) |
DeInitialize the TIM Encoder interface. | |
__weak void | HAL_TIM_Encoder_MspInit (TIM_HandleTypeDef *htim) |
Initializes the TIM Encoder Interface MSP. | |
__weak void | HAL_TIM_Encoder_MspDeInit (TIM_HandleTypeDef *htim) |
DeInitialize TIM Encoder Interface MSP. | |
HAL_StatusTypeDef | HAL_TIM_Encoder_Start (TIM_HandleTypeDef *htim, uint32_t Channel) |
Starts the TIM Encoder Interface. | |
HAL_StatusTypeDef | HAL_TIM_Encoder_Stop (TIM_HandleTypeDef *htim, uint32_t Channel) |
Stops the TIM Encoder Interface. | |
HAL_StatusTypeDef | HAL_TIM_Encoder_Start_IT (TIM_HandleTypeDef *htim, uint32_t Channel) |
Starts the TIM Encoder Interface in interrupt mode. | |
HAL_StatusTypeDef | HAL_TIM_Encoder_Stop_IT (TIM_HandleTypeDef *htim, uint32_t Channel) |
Stops the TIM Encoder Interface in interrupt mode. | |
HAL_StatusTypeDef | HAL_TIM_Encoder_Start_DMA (TIM_HandleTypeDef *htim, uint32_t Channel, uint32_t *pData1, uint32_t *pData2, uint16_t Length) |
Starts the TIM Encoder Interface in DMA mode. | |
HAL_StatusTypeDef | HAL_TIM_Encoder_Stop_DMA (TIM_HandleTypeDef *htim, uint32_t Channel) |
Stops the TIM Encoder Interface in DMA mode. |
Detailed Description
Time Encoder functions.
============================================================================== ##### Time Encoder functions ##### ============================================================================== [..] This section provides functions allowing to: (+) Initialize and configure the TIM Encoder. (+) De-initialize the TIM Encoder. (+) Start the Time Encoder. (+) Stop the Time Encoder. (+) Start the Time Encoder and enable interrupt. (+) Stop the Time Encoder and disable interrupt. (+) Start the Time Encoder and enable DMA transfer. (+) Stop the Time Encoder and disable DMA transfer.
Function Documentation
HAL_StatusTypeDef HAL_TIM_Encoder_DeInit | ( | TIM_HandleTypeDef * | htim ) |
DeInitialize the TIM Encoder interface.
- Parameters:
-
htim,: TIM Encoder handle
- Return values:
-
HAL status
Definition at line 2355 of file stm32l4xx_hal_tim.c.
HAL_StatusTypeDef HAL_TIM_Encoder_Init | ( | TIM_HandleTypeDef * | htim, |
TIM_Encoder_InitTypeDef * | sConfig | ||
) |
Initializes the TIM Encoder Interface and initialize the associated handle.
- Parameters:
-
htim,: TIM Encoder Interface handle sConfig,: TIM Encoder Interface configuration structure
- Return values:
-
HAL status
Definition at line 2265 of file stm32l4xx_hal_tim.c.
__weak void HAL_TIM_Encoder_MspDeInit | ( | TIM_HandleTypeDef * | htim ) |
DeInitialize TIM Encoder Interface MSP.
- Parameters:
-
htim,: TIM handle
- Return values:
-
None
Definition at line 2397 of file stm32l4xx_hal_tim.c.
__weak void HAL_TIM_Encoder_MspInit | ( | TIM_HandleTypeDef * | htim ) |
Initializes the TIM Encoder Interface MSP.
- Parameters:
-
htim,: TIM handle
- Return values:
-
None
Definition at line 2382 of file stm32l4xx_hal_tim.c.
HAL_StatusTypeDef HAL_TIM_Encoder_Start | ( | TIM_HandleTypeDef * | htim, |
uint32_t | Channel | ||
) |
Starts the TIM Encoder Interface.
- Parameters:
-
htim : TIM Encoder Interface handle Channel : TIM Channels to be enabled This parameter can be one of the following values: - TIM_CHANNEL_1: TIM Channel 1 selected
- TIM_CHANNEL_2: TIM Channel 2 selected
- TIM_CHANNEL_ALL: TIM Channel 1 and TIM Channel 2 are selected
- Return values:
-
HAL status
Definition at line 2417 of file stm32l4xx_hal_tim.c.
HAL_StatusTypeDef HAL_TIM_Encoder_Start_DMA | ( | TIM_HandleTypeDef * | htim, |
uint32_t | Channel, | ||
uint32_t * | pData1, | ||
uint32_t * | pData2, | ||
uint16_t | Length | ||
) |
Starts the TIM Encoder Interface in DMA mode.
- Parameters:
-
htim : TIM Encoder Interface handle Channel : TIM Channels to be enabled This parameter can be one of the following values: - TIM_CHANNEL_1: TIM Channel 1 selected
- TIM_CHANNEL_2: TIM Channel 2 selected
- TIM_CHANNEL_ALL: TIM Channel 1 and TIM Channel 2 are selected
pData1,: The destination Buffer address for IC1. pData2,: The destination Buffer address for IC2. Length,: The length of data to be transferred from TIM peripheral to memory.
- Return values:
-
HAL status
Definition at line 2611 of file stm32l4xx_hal_tim.c.
HAL_StatusTypeDef HAL_TIM_Encoder_Start_IT | ( | TIM_HandleTypeDef * | htim, |
uint32_t | Channel | ||
) |
Starts the TIM Encoder Interface in interrupt mode.
- Parameters:
-
htim : TIM Encoder Interface handle Channel : TIM Channels to be enabled This parameter can be one of the following values: - TIM_CHANNEL_1: TIM Channel 1 selected
- TIM_CHANNEL_2: TIM Channel 2 selected
- TIM_CHANNEL_ALL: TIM Channel 1 and TIM Channel 2 are selected
- Return values:
-
HAL status
Definition at line 2507 of file stm32l4xx_hal_tim.c.
HAL_StatusTypeDef HAL_TIM_Encoder_Stop | ( | TIM_HandleTypeDef * | htim, |
uint32_t | Channel | ||
) |
Stops the TIM Encoder Interface.
- Parameters:
-
htim : TIM Encoder Interface handle Channel : TIM Channels to be disabled This parameter can be one of the following values: - TIM_CHANNEL_1: TIM Channel 1 selected
- TIM_CHANNEL_2: TIM Channel 2 selected
- TIM_CHANNEL_ALL: TIM Channel 1 and TIM Channel 2 are selected
- Return values:
-
HAL status
Definition at line 2461 of file stm32l4xx_hal_tim.c.
HAL_StatusTypeDef HAL_TIM_Encoder_Stop_DMA | ( | TIM_HandleTypeDef * | htim, |
uint32_t | Channel | ||
) |
Stops the TIM Encoder Interface in DMA mode.
- Parameters:
-
htim : TIM Encoder Interface handle Channel : TIM Channels to be enabled This parameter can be one of the following values: - TIM_CHANNEL_1: TIM Channel 1 selected
- TIM_CHANNEL_2: TIM Channel 2 selected
- TIM_CHANNEL_ALL: TIM Channel 1 and TIM Channel 2 are selected
- Return values:
-
HAL status
Definition at line 2728 of file stm32l4xx_hal_tim.c.
HAL_StatusTypeDef HAL_TIM_Encoder_Stop_IT | ( | TIM_HandleTypeDef * | htim, |
uint32_t | Channel | ||
) |
Stops the TIM Encoder Interface in interrupt mode.
- Parameters:
-
htim : TIM Encoder Interface handle Channel : TIM Channels to be disabled This parameter can be one of the following values: - TIM_CHANNEL_1: TIM Channel 1 selected
- TIM_CHANNEL_2: TIM Channel 2 selected
- TIM_CHANNEL_ALL: TIM Channel 1 and TIM Channel 2 are selected
- Return values:
-
HAL status
Definition at line 2557 of file stm32l4xx_hal_tim.c.
Generated on Tue Jul 12 2022 17:38:54 by
