STM8L15x Standard Peripherals Drivers: Specific interface management functions

STM8L15x/16x Standard Peripherals Drivers

STM8L15x Standard Peripherals Drivers

Specific interface management functions

Specific interface management functions. More...

Functions

void TIM1_EncoderInterfaceConfig (TIM1_EncoderMode_TypeDef TIM1_EncoderMode, TIM1_ICPolarity_TypeDef TIM1_IC1Polarity, TIM1_ICPolarity_TypeDef TIM1_IC2Polarity)
 Configures the TIM1 Encoder Interface.
void TIM1_SelectHallSensor (FunctionalState NewState)
 Enables or Disables the TIM�s Hall sensor interface.

Detailed Description

Specific interface management functions.

 ===============================================================================
                    Specific interface management functions
 ===============================================================================  


Function Documentation

void TIM1_EncoderInterfaceConfig ( TIM1_EncoderMode_TypeDef  TIM1_EncoderMode,
TIM1_ICPolarity_TypeDef  TIM1_IC1Polarity,
TIM1_ICPolarity_TypeDef  TIM1_IC2Polarity 
)

Configures the TIM1 Encoder Interface.

Parameters:
TIM1_EncoderModespecifies the TIM1 Encoder Mode. This parameter can be one of the following values
  • TIM1_EncoderMode_TI1: Counter counts on TI1FP1 edge depending on TI2FP2 level.
  • TIM1_EncoderMode_TI2: Counter counts on TI2FP2 edge depending on TI1FP1 level.
  • TIM1_EncoderMode_TI12: Counter counts on both TI1FP1 and TI2FP2 edges depending on the level of the other input.
TIM1_IC1Polarityspecifies the IC1 Polarity. This parameter can be one of the following values:
  • TIM1_ICPolarity_Rising: Input capture polarity rising
  • TIM1_ICPolarity_Falling: Input capture polarity falling
TIM1_IC2Polarityspecifies the IC2 Polarity. This parameter can be one of the following values:
  • TIM1_ICPolarity_Rising: Input capture polarity rising
  • TIM1_ICPolarity_Falling: Input capture polarity falling
Return values:
None

Definition at line 2541 of file stm8l15x_tim1.c.

References CCMR_TIxDirect_Set, IS_TIM1_ENCODER_MODE, IS_TIM1_IC_POLARITY, TIM1, TIM1_CCER1_CC1P, TIM1_CCER1_CC2P, TIM1_CCMR_CCxS, TIM1_ICPolarity_Rising, TIM1_SMCR_MSM, and TIM1_SMCR_TS.

void TIM1_SelectHallSensor ( FunctionalState  NewState)

Enables or Disables the TIM�s Hall sensor interface.

Parameters:
NewState: The new state of the TIM1 Hall sensor interface. This parameter can be ENABLE or DISABLE
Return values:
None

Definition at line 2583 of file stm8l15x_tim1.c.

References DISABLE, IS_FUNCTIONAL_STATE, TIM1, and TIM1_CR2_TI1S.

STM8S Firmware Library: Overview

 

 

 

For complete documentation on STM8L15x 8-bit microcontrollers platform visit www.st.com