STM8L15x Standard Peripherals Drivers
|
TIM5 driver modules. More...
Modules | |
TIM5_Exported_Types | |
TIM5_Exported_Macros | |
TIM5_Private_Functions | |
Functions | |
void | TIM5_ARRPreloadConfig (FunctionalState NewState) |
Enables or disables TIM5 peripheral Preload register on ARR. | |
void | TIM5_BKRConfig (TIM5_OSSIState_TypeDef TIM5_OSSIState, TIM5_LockLevel_TypeDef TIM5_LockLevel, TIM5_BreakState_TypeDef TIM5_BreakState, TIM5_BreakPolarity_TypeDef TIM5_BreakPolarity, TIM5_AutomaticOutput_TypeDef TIM5_AutomaticOutput) |
Configures the Break feature, dead time, Lock level, the OSSI, and the AOE(automatic output enable). | |
void | TIM5_CCxCmd (TIM5_Channel_TypeDef TIM5_Channel, FunctionalState NewState) |
Enables or disables the TIM5 Capture Compare Channel x. | |
void | TIM5_ClearFlag (TIM5_FLAG_TypeDef TIM5_FLAG) |
Clears the TIM�s pending flags. | |
void | TIM5_ClearITPendingBit (TIM5_IT_TypeDef TIM5_IT) |
Clears the TIM's interrupt pending bits. | |
void | TIM5_Cmd (FunctionalState NewState) |
Enables or disables the TIM5 peripheral. | |
void | TIM5_CounterModeConfig (TIM5_CounterMode_TypeDef TIM5_CounterMode) |
Specifies the TIM5 Counter Mode to be used. | |
void | TIM5_CtrlPWMOutputs (FunctionalState NewState) |
Enables or disables the TIM5 peripheral Main Outputs. | |
void | TIM5_DeInit (void) |
Deinitialize the TIM5 peripheral registers to their default reset values. | |
void | TIM5_DMACmd (TIM5_DMASource_TypeDef TIM5_DMASource, FunctionalState NewState) |
Enables or disables the TIM5 DMA Requests. | |
void | TIM5_EncoderInterfaceConfig (TIM5_EncoderMode_TypeDef TIM5_EncoderMode, TIM5_ICPolarity_TypeDef TIM5_IC1Polarity, TIM5_ICPolarity_TypeDef TIM5_IC2Polarity) |
Configures the TIM5 Encoder Interface. | |
void | TIM5_ETRClockMode1Config (TIM5_ExtTRGPSC_TypeDef TIM5_ExtTRGPrescaler, TIM5_ExtTRGPolarity_TypeDef TIM5_ExtTRGPolarity, uint8_t ExtTRGFilter) |
Configures the TIM5 External clock Mode1. | |
void | TIM5_ETRClockMode2Config (TIM5_ExtTRGPSC_TypeDef TIM5_ExtTRGPrescaler, TIM5_ExtTRGPolarity_TypeDef TIM5_ExtTRGPolarity, uint8_t ExtTRGFilter) |
Configures the TIM5 External clock Mode2. | |
void | TIM5_ETRConfig (TIM5_ExtTRGPSC_TypeDef TIM5_ExtTRGPrescaler, TIM5_ExtTRGPolarity_TypeDef TIM5_ExtTRGPolarity, uint8_t ExtTRGFilter) |
Configures the TIM5 External Trigger. | |
void | TIM5_ForcedOC1Config (TIM5_ForcedAction_TypeDef TIM5_ForcedAction) |
Forces the TIM5 Channel1 output waveform to active or inactive level. | |
void | TIM5_ForcedOC2Config (TIM5_ForcedAction_TypeDef TIM5_ForcedAction) |
Forces the TIM5 Channel2 output waveform to active or inactive level. | |
void | TIM5_GenerateEvent (TIM5_EventSource_TypeDef TIM5_EventSource) |
Configures the TIM5 event to be generated by software. | |
uint16_t | TIM5_GetCapture1 (void) |
Gets the TIM5 Input Capture 1 value. | |
uint16_t | TIM5_GetCapture2 (void) |
Gets the TIM5 Input Capture 2 value. | |
uint16_t | TIM5_GetCounter (void) |
Gets the TIM5 Counter value. | |
FlagStatus | TIM5_GetFlagStatus (TIM5_FLAG_TypeDef TIM5_FLAG) |
Checks whether the specified TIM5 flag is set or not. | |
ITStatus | TIM5_GetITStatus (TIM5_IT_TypeDef TIM5_IT) |
Checks whether the TIM5 interrupt has occurred or not. | |
TIM5_Prescaler_TypeDef | TIM5_GetPrescaler (void) |
Gets the TIM5 Prescaler value. | |
void | TIM5_ICInit (TIM5_Channel_TypeDef TIM5_Channel, TIM5_ICPolarity_TypeDef TIM5_ICPolarity, TIM5_ICSelection_TypeDef TIM5_ICSelection, TIM5_ICPSC_TypeDef TIM5_ICPrescaler, uint8_t TIM5_ICFilter) |
Initializes the TIM5 peripheral according to the specified parameters. | |
void | TIM5_InternalClockConfig (void) |
Enables the TIM5 internal Clock. | |
void | TIM5_ITConfig (TIM5_IT_TypeDef TIM5_IT, FunctionalState NewState) |
Enables or disables the specified TIM5 interrupts. | |
void | TIM5_OC1FastConfig (FunctionalState NewState) |
Configures the TIM5 Capture Compare 1 Fast feature. | |
void | TIM5_OC1Init (TIM5_OCMode_TypeDef TIM5_OCMode, TIM5_OutputState_TypeDef TIM5_OutputState, uint16_t TIM5_Pulse, TIM5_OCPolarity_TypeDef TIM5_OCPolarity, TIM5_OCIdleState_TypeDef TIM5_OCIdleState) |
Initializes the TIM5 Channel1 according to the specified parameters. | |
void | TIM5_OC1PolarityConfig (TIM5_OCPolarity_TypeDef TIM5_OCPolarity) |
Configures the TIM5 Channel 1 polarity. | |
void | TIM5_OC1PreloadConfig (FunctionalState NewState) |
Enables or disables the TIM5 peripheral Preload Register on CCR1. | |
void | TIM5_OC2FastConfig (FunctionalState NewState) |
Configures the TIM5 Capture Compare 2 Fast feature. | |
void | TIM5_OC2Init (TIM5_OCMode_TypeDef TIM5_OCMode, TIM5_OutputState_TypeDef TIM5_OutputState, uint16_t TIM5_Pulse, TIM5_OCPolarity_TypeDef TIM5_OCPolarity, TIM5_OCIdleState_TypeDef TIM5_OCIdleState) |
Initializes the TIM5 Channel2 according to the specified parameters. | |
void | TIM5_OC2PolarityConfig (TIM5_OCPolarity_TypeDef TIM5_OCPolarity) |
Configures the TIM5 Channel 2 polarity. | |
void | TIM5_OC2PreloadConfig (FunctionalState NewState) |
Enables or disables the TIM5 peripheral Preload Register on CCR2. | |
void | TIM5_PrescalerConfig (TIM5_Prescaler_TypeDef Prescaler, TIM5_PSCReloadMode_TypeDef TIM5_PSCReloadMode) |
Configures the TIM5 Prescaler. | |
void | TIM5_PWMIConfig (TIM5_Channel_TypeDef TIM5_Channel, TIM5_ICPolarity_TypeDef TIM5_ICPolarity, TIM5_ICSelection_TypeDef TIM5_ICSelection, TIM5_ICPSC_TypeDef TIM5_ICPrescaler, uint8_t TIM5_ICFilter) |
Configures the TIM5 peripheral in PWM Input Mode according to the specified parameters. | |
void | TIM5_SelectCCDMA (FunctionalState NewState) |
Selects the TIM5 peripheral Capture Compare DMA source. | |
void | TIM5_SelectHallSensor (FunctionalState NewState) |
Enables or Disables the TIM�s Hall sensor interface. | |
void | TIM5_SelectInputTrigger (TIM5_TRGSelection_TypeDef TIM5_InputTriggerSource) |
Selects the TIM5 Input Trigger source. | |
void | TIM5_SelectMasterSlaveMode (FunctionalState NewState) |
Sets or Resets the TIM5 Master/Slave Mode. | |
void | TIM5_SelectOCxM (TIM5_Channel_TypeDef TIM5_Channel, TIM5_OCMode_TypeDef TIM5_OCMode) |
Selects the TIM5 Output Compare Mode. | |
void | TIM5_SelectOnePulseMode (TIM5_OPMode_TypeDef TIM5_OPMode) |
Selects the TIM�s One Pulse Mode. | |
void | TIM5_SelectOutputTrigger (TIM5_TRGOSource_TypeDef TIM5_TRGOSource) |
Selects the TIM5 Trigger Output Mode. | |
void | TIM5_SelectSlaveMode (TIM5_SlaveMode_TypeDef TIM5_SlaveMode) |
Selects the TIM5 Slave Mode. | |
void | TIM5_SetAutoreload (uint16_t Autoreload) |
Sets the TIM5 Autoreload Register value. | |
void | TIM5_SetCompare1 (uint16_t Compare) |
Sets the TIM5 Capture Compare1 Register value. | |
void | TIM5_SetCompare2 (uint16_t Compare) |
Sets the TIM5 Capture Compare2 Register value. | |
void | TIM5_SetCounter (uint16_t Counter) |
Sets the TIM5 Counter Register value. | |
void | TIM5_SetIC1Prescaler (TIM5_ICPSC_TypeDef TIM5_IC1Prescaler) |
Sets the TIM5 Input Capture 1 prescaler. | |
void | TIM5_SetIC2Prescaler (TIM5_ICPSC_TypeDef TIM5_IC2Prescaler) |
Sets the TIM5 Input Capture 2 prescaler. | |
void | TIM5_TimeBaseInit (TIM5_Prescaler_TypeDef TIM5_Prescaler, TIM5_CounterMode_TypeDef TIM5_CounterMode, uint16_t TIM5_Period) |
Initializes the TIM5 Time Base Unit according to the specified parameters. | |
void | TIM5_TIxExternalClockConfig (TIM5_TIxExternalCLK1Source_TypeDef TIM5_TIxExternalCLKSource, TIM5_ICPolarity_TypeDef TIM5_ICPolarity, uint8_t ICFilter) |
Configures the TIM5 Trigger as External Clock. | |
void | TIM5_UpdateDisableConfig (FunctionalState NewState) |
Enables or Disables the TIM5 Update event. | |
void | TIM5_UpdateRequestConfig (TIM5_UpdateSource_TypeDef TIM5_UpdateSource) |
Selects the TIM5 Update Request Interrupt source. |
Detailed Description
TIM5 driver modules.
Function Documentation
void TIM5_ARRPreloadConfig | ( | FunctionalState | NewState | ) |
Enables or disables TIM5 peripheral Preload register on ARR.
Definition at line 436 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CR1_ARPE.
void TIM5_BKRConfig | ( | TIM5_OSSIState_TypeDef | TIM5_OSSIState, |
TIM5_LockLevel_TypeDef | TIM5_LockLevel, | ||
TIM5_BreakState_TypeDef | TIM5_BreakState, | ||
TIM5_BreakPolarity_TypeDef | TIM5_BreakPolarity, | ||
TIM5_AutomaticOutput_TypeDef | TIM5_AutomaticOutput | ||
) |
Configures the Break feature, dead time, Lock level, the OSSI, and the AOE(automatic output enable).
Definition at line 748 of file stm8l15x_tim5.c.
References IS_TIM5_AUTOMATIC_OUTPUT_STATE, IS_TIM5_BREAK_POLARITY, IS_TIM5_BREAK_STATE, IS_TIM5_LOCK_LEVEL, IS_TIM5_OSSI_STATE, and TIM5.
void TIM5_CCxCmd | ( | TIM5_Channel_TypeDef | TIM5_Channel, |
FunctionalState | NewState | ||
) |
Enables or disables the TIM5 Capture Compare Channel x.
Definition at line 1068 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, IS_TIM5_CHANNEL, TIM5, TIM5_Channel_1, TIM_CCER1_CC1E, and TIM_CCER1_CC2E.
void TIM5_ClearFlag | ( | TIM5_FLAG_TypeDef | TIM5_FLAG | ) |
Clears the TIM�s pending flags.
Definition at line 1500 of file stm8l15x_tim5.c.
References IS_TIM5_CLEAR_FLAG, and TIM5.
void TIM5_ClearITPendingBit | ( | TIM5_IT_TypeDef | TIM5_IT | ) |
Clears the TIM's interrupt pending bits.
Definition at line 1555 of file stm8l15x_tim5.c.
References IS_TIM5_IT, and TIM5.
void TIM5_Cmd | ( | FunctionalState | NewState | ) |
Enables or disables the TIM5 peripheral.
Definition at line 482 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CR1_CEN.
void TIM5_CounterModeConfig | ( | TIM5_CounterMode_TypeDef | TIM5_CounterMode | ) |
Specifies the TIM5 Counter Mode to be used.
Definition at line 300 of file stm8l15x_tim5.c.
References IS_TIM5_COUNTER_MODE, TIM5, TIM_CR1_CMS, and TIM_CR1_DIR.
void TIM5_CtrlPWMOutputs | ( | FunctionalState | NewState | ) |
Enables or disables the TIM5 peripheral Main Outputs.
Definition at line 777 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_BKR_MOE.
void TIM5_DeInit | ( | void | ) |
Deinitialize the TIM5 peripheral registers to their default reset values.
Definition at line 162 of file stm8l15x_tim5.c.
References TIM5, TIM_ARRH_RESET_VALUE, TIM_ARRL_RESET_VALUE, TIM_BKR_RESET_VALUE, TIM_CCER1_RESET_VALUE, TIM_CCMR1_RESET_VALUE, TIM_CCMR2_RESET_VALUE, TIM_CCR1H_RESET_VALUE, TIM_CCR1L_RESET_VALUE, TIM_CCR2H_RESET_VALUE, TIM_CCR2L_RESET_VALUE, TIM_CNTRH_RESET_VALUE, TIM_CNTRL_RESET_VALUE, TIM_CR1_RESET_VALUE, TIM_CR2_RESET_VALUE, TIM_ETR_RESET_VALUE, TIM_IER_RESET_VALUE, TIM_OISR_RESET_VALUE, TIM_PSCR_RESET_VALUE, TIM_SMCR_RESET_VALUE, TIM_SR1_RESET_VALUE, and TIM_SR2_RESET_VALUE.
void TIM5_DMACmd | ( | TIM5_DMASource_TypeDef | TIM5_DMASource, |
FunctionalState | NewState | ||
) |
Enables or disables the TIM5 DMA Requests.
Definition at line 1575 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, IS_TIM5_DMA_SOURCE, and TIM5.
void TIM5_EncoderInterfaceConfig | ( | TIM5_EncoderMode_TypeDef | TIM5_EncoderMode, |
TIM5_ICPolarity_TypeDef | TIM5_IC1Polarity, | ||
TIM5_ICPolarity_TypeDef | TIM5_IC2Polarity | ||
) |
Configures the TIM5 Encoder Interface.
Definition at line 1952 of file stm8l15x_tim5.c.
References IS_TIM5_ENCODER_MODE, IS_TIM5_IC_POLARITY, TIM5, TIM5_ICPolarity_Falling, TIM_CCER1_CC1P, TIM_CCER1_CC2P, TIM_CCMR_CCxS, TIM_CCMR_TIxDirect_Set, TIM_SMCR_MSM, and TIM_SMCR_TS.
void TIM5_ETRClockMode1Config | ( | TIM5_ExtTRGPSC_TypeDef | TIM5_ExtTRGPrescaler, |
TIM5_ExtTRGPolarity_TypeDef | TIM5_ExtTRGPolarity, | ||
uint8_t | ExtTRGFilter | ||
) |
Configures the TIM5 External clock Mode1.
Definition at line 1701 of file stm8l15x_tim5.c.
References TIM5, TIM5_ETRConfig(), TIM5_SlaveMode_External1, TIM5_TRGSelection_ETRF, TIM_SMCR_SMS, and TIM_SMCR_TS.
void TIM5_ETRClockMode2Config | ( | TIM5_ExtTRGPSC_TypeDef | TIM5_ExtTRGPrescaler, |
TIM5_ExtTRGPolarity_TypeDef | TIM5_ExtTRGPolarity, | ||
uint8_t | ExtTRGFilter | ||
) |
Configures the TIM5 External clock Mode2.
Definition at line 1733 of file stm8l15x_tim5.c.
References TIM5, TIM5_ETRConfig(), and TIM_ETR_ECE.
void TIM5_ETRConfig | ( | TIM5_ExtTRGPSC_TypeDef | TIM5_ExtTRGPrescaler, |
TIM5_ExtTRGPolarity_TypeDef | TIM5_ExtTRGPolarity, | ||
uint8_t | ExtTRGFilter | ||
) |
Configures the TIM5 External Trigger.
Definition at line 1905 of file stm8l15x_tim5.c.
References IS_TIM5_EXT_FILTER, IS_TIM5_EXT_POLARITY, IS_TIM5_EXT_PRESCALER, and TIM5.
Referenced by TIM5_ETRClockMode1Config(), and TIM5_ETRClockMode2Config().
void TIM5_ForcedOC1Config | ( | TIM5_ForcedAction_TypeDef | TIM5_ForcedAction | ) |
Forces the TIM5 Channel1 output waveform to active or inactive level.
Definition at line 877 of file stm8l15x_tim5.c.
References IS_TIM5_FORCED_ACTION, TIM5, and TIM_CCMR_OCM.
void TIM5_ForcedOC2Config | ( | TIM5_ForcedAction_TypeDef | TIM5_ForcedAction | ) |
Forces the TIM5 Channel2 output waveform to active or inactive level.
Definition at line 903 of file stm8l15x_tim5.c.
References IS_TIM5_FORCED_ACTION, TIM5, and TIM_CCMR_OCM.
void TIM5_GenerateEvent | ( | TIM5_EventSource_TypeDef | TIM5_EventSource | ) |
Configures the TIM5 event to be generated by software.
Definition at line 1445 of file stm8l15x_tim5.c.
References IS_TIM5_EVENT_SOURCE, and TIM5.
uint16_t TIM5_GetCapture1 | ( | void | ) |
Gets the TIM5 Input Capture 1 value.
Definition at line 1298 of file stm8l15x_tim5.c.
References TIM5.
uint16_t TIM5_GetCapture2 | ( | void | ) |
Gets the TIM5 Input Capture 2 value.
Definition at line 1317 of file stm8l15x_tim5.c.
References TIM5.
uint16_t TIM5_GetCounter | ( | void | ) |
FlagStatus TIM5_GetFlagStatus | ( | TIM5_FLAG_TypeDef | TIM5_FLAG | ) |
Checks whether the specified TIM5 flag is set or not.
Definition at line 1467 of file stm8l15x_tim5.c.
References IS_TIM5_GET_FLAG, RESET, SET, and TIM5.
ITStatus TIM5_GetITStatus | ( | TIM5_IT_TypeDef | TIM5_IT | ) |
Checks whether the TIM5 interrupt has occurred or not.
Definition at line 1520 of file stm8l15x_tim5.c.
References IS_TIM5_GET_IT, RESET, SET, and TIM5.
TIM5_Prescaler_TypeDef TIM5_GetPrescaler | ( | void | ) |
void TIM5_ICInit | ( | TIM5_Channel_TypeDef | TIM5_Channel, |
TIM5_ICPolarity_TypeDef | TIM5_ICPolarity, | ||
TIM5_ICSelection_TypeDef | TIM5_ICSelection, | ||
TIM5_ICPSC_TypeDef | TIM5_ICPrescaler, | ||
uint8_t | TIM5_ICFilter | ||
) |
Initializes the TIM5 peripheral according to the specified parameters.
Definition at line 1178 of file stm8l15x_tim5.c.
References IS_TIM5_CHANNEL, TI1_Config(), TI2_Config(), TIM5_Channel_1, TIM5_SetIC1Prescaler(), and TIM5_SetIC2Prescaler().
void TIM5_InternalClockConfig | ( | void | ) |
Enables the TIM5 internal Clock.
Definition at line 1638 of file stm8l15x_tim5.c.
References TIM5, and TIM_SMCR_SMS.
void TIM5_ITConfig | ( | TIM5_IT_TypeDef | TIM5_IT, |
FunctionalState | NewState | ||
) |
Enables or disables the specified TIM5 interrupts.
Definition at line 1416 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, IS_TIM5_IT, and TIM5.
void TIM5_OC1FastConfig | ( | FunctionalState | NewState | ) |
Configures the TIM5 Capture Compare 1 Fast feature.
Definition at line 971 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CCMR_OCxFE.
void TIM5_OC1Init | ( | TIM5_OCMode_TypeDef | TIM5_OCMode, |
TIM5_OutputState_TypeDef | TIM5_OutputState, | ||
uint16_t | TIM5_Pulse, | ||
TIM5_OCPolarity_TypeDef | TIM5_OCPolarity, | ||
TIM5_OCIdleState_TypeDef | TIM5_OCIdleState | ||
) |
Initializes the TIM5 Channel1 according to the specified parameters.
Definition at line 572 of file stm8l15x_tim5.c.
References IS_TIM5_OC_MODE, IS_TIM5_OC_POLARITY, IS_TIM5_OCIDLE_STATE, IS_TIM5_OUTPUT_STATE, TIM5, TIM5_OCIdleState_Set, TIM5_OCPolarity_Low, TIM5_OutputState_Enable, TIM_CCER1_CC1E, TIM_CCER1_CC1P, TIM_CCMR_OCM, and TIM_OISR_OIS1.
void TIM5_OC1PolarityConfig | ( | TIM5_OCPolarity_TypeDef | TIM5_OCPolarity | ) |
Configures the TIM5 Channel 1 polarity.
Definition at line 1018 of file stm8l15x_tim5.c.
References IS_TIM5_OC_POLARITY, TIM5, TIM5_OCPolarity_Low, and TIM_CCER1_CC1P.
void TIM5_OC1PreloadConfig | ( | FunctionalState | NewState | ) |
Enables or disables the TIM5 peripheral Preload Register on CCR1.
Definition at line 927 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CCMR_OCxPE.
void TIM5_OC2FastConfig | ( | FunctionalState | NewState | ) |
Configures the TIM5 Capture Compare 2 Fast feature.
Definition at line 994 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CCMR_OCxFE.
void TIM5_OC2Init | ( | TIM5_OCMode_TypeDef | TIM5_OCMode, |
TIM5_OutputState_TypeDef | TIM5_OutputState, | ||
uint16_t | TIM5_Pulse, | ||
TIM5_OCPolarity_TypeDef | TIM5_OCPolarity, | ||
TIM5_OCIdleState_TypeDef | TIM5_OCIdleState | ||
) |
Initializes the TIM5 Channel2 according to the specified parameters.
Definition at line 658 of file stm8l15x_tim5.c.
References IS_TIM5_OC_MODE, IS_TIM5_OC_POLARITY, IS_TIM5_OCIDLE_STATE, IS_TIM5_OUTPUT_STATE, TIM5, TIM5_OCIdleState_Set, TIM5_OCPolarity_Low, TIM5_OutputState_Enable, TIM_CCER1_CC2E, TIM_CCER1_CC2P, TIM_CCMR_OCM, and TIM_OISR_OIS2.
void TIM5_OC2PolarityConfig | ( | TIM5_OCPolarity_TypeDef | TIM5_OCPolarity | ) |
Configures the TIM5 Channel 2 polarity.
Definition at line 1042 of file stm8l15x_tim5.c.
References IS_TIM5_OC_POLARITY, TIM5, TIM5_OCPolarity_Low, and TIM_CCER1_CC2P.
void TIM5_OC2PreloadConfig | ( | FunctionalState | NewState | ) |
Enables or disables the TIM5 peripheral Preload Register on CCR2.
Definition at line 949 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CCMR_OCxPE.
void TIM5_PrescalerConfig | ( | TIM5_Prescaler_TypeDef | Prescaler, |
TIM5_PSCReloadMode_TypeDef | TIM5_PSCReloadMode | ||
) |
Configures the TIM5 Prescaler.
Definition at line 268 of file stm8l15x_tim5.c.
References IS_TIM5_PRESCALER, IS_TIM5_PRESCALER_RELOAD, TIM5, TIM5_PSCReloadMode_Immediate, and TIM_EGR_UG.
void TIM5_PWMIConfig | ( | TIM5_Channel_TypeDef | TIM5_Channel, |
TIM5_ICPolarity_TypeDef | TIM5_ICPolarity, | ||
TIM5_ICSelection_TypeDef | TIM5_ICSelection, | ||
TIM5_ICPSC_TypeDef | TIM5_ICPrescaler, | ||
uint8_t | TIM5_ICFilter | ||
) |
Configures the TIM5 peripheral in PWM Input Mode according to the specified parameters.
Definition at line 1229 of file stm8l15x_tim5.c.
References IS_TIM5_CHANNEL, TI1_Config(), TI2_Config(), TIM5_Channel_1, TIM5_ICPolarity_Falling, TIM5_ICPolarity_Rising, TIM5_ICSelection_DirectTI, TIM5_ICSelection_IndirectTI, TIM5_SetIC1Prescaler(), and TIM5_SetIC2Prescaler().
void TIM5_SelectCCDMA | ( | FunctionalState | NewState | ) |
Selects the TIM5 peripheral Capture Compare DMA source.
Definition at line 1599 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CR2_CCDS.
void TIM5_SelectHallSensor | ( | FunctionalState | NewState | ) |
Enables or Disables the TIM�s Hall sensor interface.
Definition at line 2009 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CR2_TI1S.
void TIM5_SelectInputTrigger | ( | TIM5_TRGSelection_TypeDef | TIM5_InputTriggerSource | ) |
Selects the TIM5 Input Trigger source.
Definition at line 1793 of file stm8l15x_tim5.c.
References IS_TIM5_TRIGGER_SELECTION, TIM5, and TIM_SMCR_TS.
Referenced by TIM5_TIxExternalClockConfig().
void TIM5_SelectMasterSlaveMode | ( | FunctionalState | NewState | ) |
Sets or Resets the TIM5 Master/Slave Mode.
Definition at line 1873 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_SMCR_MSM.
void TIM5_SelectOCxM | ( | TIM5_Channel_TypeDef | TIM5_Channel, |
TIM5_OCMode_TypeDef | TIM5_OCMode | ||
) |
Selects the TIM5 Output Compare Mode.
This function disables the selected channel before changing the Output Compare Mode. User has to enable this channel using TIM5_CCxCmd and TIM5_CCxNCmd functions.
Definition at line 812 of file stm8l15x_tim5.c.
References IS_TIM5_CHANNEL, IS_TIM5_OCM, TIM5, TIM5_Channel_1, TIM_CCER1_CC1E, TIM_CCER1_CC2E, and TIM_CCMR_OCM.
void TIM5_SelectOnePulseMode | ( | TIM5_OPMode_TypeDef | TIM5_OPMode | ) |
Selects the TIM�s One Pulse Mode.
Definition at line 460 of file stm8l15x_tim5.c.
References IS_TIM5_OPM_MODE, TIM5, TIM5_OPMode_Single, and TIM_CR1_OPM.
void TIM5_SelectOutputTrigger | ( | TIM5_TRGOSource_TypeDef | TIM5_TRGOSource | ) |
Selects the TIM5 Trigger Output Mode.
Definition at line 1821 of file stm8l15x_tim5.c.
References IS_TIM5_TRGO_SOURCE, TIM5, and TIM_CR2_MMS.
void TIM5_SelectSlaveMode | ( | TIM5_SlaveMode_TypeDef | TIM5_SlaveMode | ) |
Selects the TIM5 Slave Mode.
Definition at line 1849 of file stm8l15x_tim5.c.
References IS_TIM5_SLAVE_MODE, TIM5, and TIM_SMCR_SMS.
void TIM5_SetAutoreload | ( | uint16_t | Autoreload | ) |
Sets the TIM5 Autoreload Register value.
Definition at line 338 of file stm8l15x_tim5.c.
References TIM5.
void TIM5_SetCompare1 | ( | uint16_t | Compare | ) |
Sets the TIM5 Capture Compare1 Register value.
Definition at line 849 of file stm8l15x_tim5.c.
References TIM5.
void TIM5_SetCompare2 | ( | uint16_t | Compare | ) |
Sets the TIM5 Capture Compare2 Register value.
Definition at line 862 of file stm8l15x_tim5.c.
References TIM5.
void TIM5_SetCounter | ( | uint16_t | Counter | ) |
Sets the TIM5 Counter Register value.
Definition at line 324 of file stm8l15x_tim5.c.
References TIM5.
void TIM5_SetIC1Prescaler | ( | TIM5_ICPSC_TypeDef | TIM5_IC1Prescaler | ) |
Sets the TIM5 Input Capture 1 prescaler.
Definition at line 1341 of file stm8l15x_tim5.c.
References IS_TIM5_IC_PRESCALER, TIM5, and TIM_CCMR_ICxPSC.
Referenced by TIM5_ICInit(), and TIM5_PWMIConfig().
void TIM5_SetIC2Prescaler | ( | TIM5_ICPSC_TypeDef | TIM5_IC2Prescaler | ) |
Sets the TIM5 Input Capture 2 prescaler.
Definition at line 1369 of file stm8l15x_tim5.c.
References IS_TIM5_IC_PRESCALER, TIM5, and TIM_CCMR_ICxPSC.
Referenced by TIM5_ICInit(), and TIM5_PWMIConfig().
void TIM5_TimeBaseInit | ( | TIM5_Prescaler_TypeDef | TIM5_Prescaler, |
TIM5_CounterMode_TypeDef | TIM5_CounterMode, | ||
uint16_t | TIM5_Period | ||
) |
Initializes the TIM5 Time Base Unit according to the specified parameters.
Definition at line 225 of file stm8l15x_tim5.c.
References IS_TIM5_COUNTER_MODE, IS_TIM5_PRESCALER, TIM5, TIM5_EventSource_Update, TIM_CR1_CMS, and TIM_CR1_DIR.
void TIM5_TIxExternalClockConfig | ( | TIM5_TIxExternalCLK1Source_TypeDef | TIM5_TIxExternalCLKSource, |
TIM5_ICPolarity_TypeDef | TIM5_ICPolarity, | ||
uint8_t | ICFilter | ||
) |
Configures the TIM5 Trigger as External Clock.
Definition at line 1659 of file stm8l15x_tim5.c.
References IS_TIM5_IC_FILTER, IS_TIM5_IC_POLARITY, IS_TIM5_TIXCLK_SOURCE, TI1_Config(), TI2_Config(), TIM5, TIM5_ICSelection_DirectTI, TIM5_SelectInputTrigger(), TIM5_SlaveMode_External1, and TIM5_TIxExternalCLK1Source_TI2.
void TIM5_UpdateDisableConfig | ( | FunctionalState | NewState | ) |
Enables or Disables the TIM5 Update event.
Definition at line 390 of file stm8l15x_tim5.c.
References DISABLE, IS_FUNCTIONAL_STATE, TIM5, and TIM_CR1_UDIS.
void TIM5_UpdateRequestConfig | ( | TIM5_UpdateSource_TypeDef | TIM5_UpdateSource | ) |
Selects the TIM5 Update Request Interrupt source.
Definition at line 414 of file stm8l15x_tim5.c.
References IS_TIM5_UPDATE_SOURCE, TIM5, TIM5_UpdateSource_Regular, and TIM_CR1_URS.