STM8S/A Standard Peripherals Drivers: TIM1_Exported_Types

STM8S/A

STM8S/A Standard Peripherals Drivers

Defines

#define IS_TIM1_AUTOMATIC_OUTPUT_STATE_OK(STATE)
#define IS_TIM1_BREAK_POLARITY_OK(POLARITY)
#define IS_TIM1_BREAK_STATE_OK(STATE)
#define IS_TIM1_CHANNEL_OK(CHANNEL)
#define IS_TIM1_CLEAR_FLAG_OK(FLAG)   ((((uint16_t)(FLAG) & (uint16_t)0xE100) == 0x0000) && ((FLAG) != 0x0000))
#define IS_TIM1_COMPLEMENTARY_CHANNEL_OK(CHANNEL)
#define IS_TIM1_COUNTER_MODE_OK(MODE)
#define IS_TIM1_ENCODER_MODE_OK(MODE)
#define IS_TIM1_EVENT_SOURCE_OK(SOURCE)   ((SOURCE) != 0x00)
#define IS_TIM1_EXT_POLARITY_OK(POLARITY)
#define IS_TIM1_EXT_PRESCALER_OK(PRESCALER)
#define IS_TIM1_EXT_TRG_FILTER_OK(FILTER)   ((FILTER) <= 0x0F)
 TIM1 External Trigger Filer Value.
#define IS_TIM1_FORCED_ACTION_OK(ACTION)
#define IS_TIM1_GET_FLAG_OK(FLAG)
#define IS_TIM1_GET_IT_OK(IT)
#define IS_TIM1_IC_FILTER_OK(ICFILTER)   ((ICFILTER) <= 0x0F)
 TIM1 Input Capture Filer Value.
#define IS_TIM1_IC_POLARITY_OK(POLARITY)
#define IS_TIM1_IC_PRESCALER_OK(PRESCALER)
#define IS_TIM1_IC_SELECTION_OK(SELECTION)
#define IS_TIM1_IT_OK(IT)   ((IT) != 0x00)
#define IS_TIM1_LOCK_LEVEL_OK(LEVEL)
#define IS_TIM1_OC_MODE_OK(MODE)
#define IS_TIM1_OC_POLARITY_OK(POLARITY)
#define IS_TIM1_OCIDLE_STATE_OK(STATE)
#define IS_TIM1_OCM_OK(MODE)
#define IS_TIM1_OCN_POLARITY_OK(POLARITY)
#define IS_TIM1_OCNIDLE_STATE_OK(STATE)
#define IS_TIM1_OPM_MODE_OK(MODE)
#define IS_TIM1_OSSI_STATE_OK(STATE)
#define IS_TIM1_OUTPUT_STATE_OK(STATE)
#define IS_TIM1_OUTPUTN_STATE_OK(STATE)
#define IS_TIM1_PRESCALER_RELOAD_OK(RELOAD)
#define IS_TIM1_PWMI_CHANNEL_OK(CHANNEL)
#define IS_TIM1_SLAVE_MODE_OK(MODE)
#define IS_TIM1_TIX_TRIGGER_SELECTION_OK(SELECTION)
#define IS_TIM1_TIXCLK_SOURCE_OK(SOURCE)
#define IS_TIM1_TRGO_SOURCE_OK(SOURCE)
#define IS_TIM1_TRIGGER_SELECTION_OK(SELECTION)
#define IS_TIM1_UPDATE_SOURCE_OK(SOURCE)

Enumerations

enum  TIM1_AutomaticOutput_TypeDef { TIM1_AUTOMATICOUTPUT_ENABLE = ((uint8_t)0x40), TIM1_AUTOMATICOUTPUT_DISABLE = ((uint8_t)0x00) }
 TIM1 AOE Bit Set/Reset. More...
enum  TIM1_BreakPolarity_TypeDef { TIM1_BREAKPOLARITY_LOW = ((uint8_t)0x00), TIM1_BREAKPOLARITY_HIGH = ((uint8_t)0x20) }
 TIM1 Break Polarity. More...
enum  TIM1_BreakState_TypeDef { TIM1_BREAK_ENABLE = ((uint8_t)0x10), TIM1_BREAK_DISABLE = ((uint8_t)0x00) }
 TIM1 Break Input enable/disable. More...
enum  TIM1_Channel_TypeDef { TIM1_CHANNEL_1 = ((uint8_t)0x00), TIM1_CHANNEL_2 = ((uint8_t)0x01), TIM1_CHANNEL_3 = ((uint8_t)0x02), TIM1_CHANNEL_4 = ((uint8_t)0x03) }
 TIM1 Channel. More...
enum  TIM1_CounterMode_TypeDef {
  TIM1_COUNTERMODE_UP = ((uint8_t)0x00), TIM1_COUNTERMODE_DOWN = ((uint8_t)0x10), TIM1_COUNTERMODE_CENTERALIGNED1 = ((uint8_t)0x20), TIM1_COUNTERMODE_CENTERALIGNED2 = ((uint8_t)0x40),
  TIM1_COUNTERMODE_CENTERALIGNED3 = ((uint8_t)0x60)
}
 TIM1 Counter Mode. More...
enum  TIM1_EncoderMode_TypeDef { TIM1_ENCODERMODE_TI1 = ((uint8_t)0x01), TIM1_ENCODERMODE_TI2 = ((uint8_t)0x02), TIM1_ENCODERMODE_TI12 = ((uint8_t)0x03) }
 TIM1 Encoder Mode. More...
enum  TIM1_EventSource_TypeDef {
  TIM1_EVENTSOURCE_UPDATE = ((uint8_t)0x01), TIM1_EVENTSOURCE_CC1 = ((uint8_t)0x02), TIM1_EVENTSOURCE_CC2 = ((uint8_t)0x04), TIM1_EVENTSOURCE_CC3 = ((uint8_t)0x08),
  TIM1_EVENTSOURCE_CC4 = ((uint8_t)0x10), TIM1_EVENTSOURCE_COM = ((uint8_t)0x20), TIM1_EVENTSOURCE_TRIGGER = ((uint8_t)0x40), TIM1_EVENTSOURCE_BREAK = ((uint8_t)0x80)
}
 TIM1 Event Source. More...
enum  TIM1_ExtTRGPolarity_TypeDef { TIM1_EXTTRGPOLARITY_INVERTED = ((uint8_t)0x80), TIM1_EXTTRGPOLARITY_NONINVERTED = ((uint8_t)0x00) }
 TIM1 External Trigger Polarity. More...
enum  TIM1_ExtTRGPSC_TypeDef { TIM1_EXTTRGPSC_OFF = ((uint8_t)0x00), TIM1_EXTTRGPSC_DIV2 = ((uint8_t)0x10), TIM1_EXTTRGPSC_DIV4 = ((uint8_t)0x20), TIM1_EXTTRGPSC_DIV8 = ((uint8_t)0x30) }
 TIM1 External Trigger Prescaler. More...
enum  TIM1_FLAG_TypeDef {
  TIM1_FLAG_UPDATE = ((uint16_t)0x0001), TIM1_FLAG_CC1 = ((uint16_t)0x0002), TIM1_FLAG_CC2 = ((uint16_t)0x0004), TIM1_FLAG_CC3 = ((uint16_t)0x0008),
  TIM1_FLAG_CC4 = ((uint16_t)0x0010), TIM1_FLAG_COM = ((uint16_t)0x0020), TIM1_FLAG_TRIGGER = ((uint16_t)0x0040), TIM1_FLAG_BREAK = ((uint16_t)0x0080),
  TIM1_FLAG_CC1OF = ((uint16_t)0x0200), TIM1_FLAG_CC2OF = ((uint16_t)0x0400), TIM1_FLAG_CC3OF = ((uint16_t)0x0800), TIM1_FLAG_CC4OF = ((uint16_t)0x1000)
}
 TIM1 Flags. More...
enum  TIM1_ForcedAction_TypeDef { TIM1_FORCEDACTION_ACTIVE = ((uint8_t)0x50), TIM1_FORCEDACTION_INACTIVE = ((uint8_t)0x40) }
 TIM1 Forced Action. More...
enum  TIM1_ICPolarity_TypeDef { TIM1_ICPOLARITY_RISING = ((uint8_t)0x00), TIM1_ICPOLARITY_FALLING = ((uint8_t)0x01) }
 TIM1 Input Capture Polarity. More...
enum  TIM1_ICPSC_TypeDef { TIM1_ICPSC_DIV1 = ((uint8_t)0x00), TIM1_ICPSC_DIV2 = ((uint8_t)0x04), TIM1_ICPSC_DIV4 = ((uint8_t)0x08), TIM1_ICPSC_DIV8 = ((uint8_t)0x0C) }
 TIM1 Input Capture Prescaler. More...
enum  TIM1_ICSelection_TypeDef { TIM1_ICSELECTION_DIRECTTI = ((uint8_t)0x01), TIM1_ICSELECTION_INDIRECTTI = ((uint8_t)0x02), TIM1_ICSELECTION_TRGI = ((uint8_t)0x03) }
 TIM1 Input Capture Selection. More...
enum  TIM1_IT_TypeDef {
  TIM1_IT_UPDATE = ((uint8_t)0x01), TIM1_IT_CC1 = ((uint8_t)0x02), TIM1_IT_CC2 = ((uint8_t)0x04), TIM1_IT_CC3 = ((uint8_t)0x08),
  TIM1_IT_CC4 = ((uint8_t)0x10), TIM1_IT_COM = ((uint8_t)0x20), TIM1_IT_TRIGGER = ((uint8_t)0x40), TIM1_IT_BREAK = ((uint8_t)0x80)
}
 TIM1 interrupt sources. More...
enum  TIM1_LockLevel_TypeDef { TIM1_LOCKLEVEL_OFF = ((uint8_t)0x00), TIM1_LOCKLEVEL_1 = ((uint8_t)0x01), TIM1_LOCKLEVEL_2 = ((uint8_t)0x02), TIM1_LOCKLEVEL_3 = ((uint8_t)0x03) }
 TIM1 Lock levels. More...
enum  TIM1_OCIdleState_TypeDef { TIM1_OCIDLESTATE_SET = ((uint8_t)0x55), TIM1_OCIDLESTATE_RESET = ((uint8_t)0x00) }
 TIM1 Output Compare Idle State. More...
enum  TIM1_OCMode_TypeDef {
  TIM1_OCMODE_TIMING = ((uint8_t)0x00), TIM1_OCMODE_ACTIVE = ((uint8_t)0x10), TIM1_OCMODE_INACTIVE = ((uint8_t)0x20), TIM1_OCMODE_TOGGLE = ((uint8_t)0x30),
  TIM1_OCMODE_PWM1 = ((uint8_t)0x60), TIM1_OCMODE_PWM2 = ((uint8_t)0x70)
}
 TIM1 Output Compare and PWM modes. More...
enum  TIM1_OCNIdleState_TypeDef { TIM1_OCNIDLESTATE_SET = ((uint8_t)0x2A), TIM1_OCNIDLESTATE_RESET = ((uint8_t)0x00) }
 TIM1 Output Compare N Idle State. More...
enum  TIM1_OCNPolarity_TypeDef { TIM1_OCNPOLARITY_HIGH = ((uint8_t)0x00), TIM1_OCNPOLARITY_LOW = ((uint8_t)0x88) }
 TIM1 Output Compare N Polarity. More...
enum  TIM1_OCPolarity_TypeDef { TIM1_OCPOLARITY_HIGH = ((uint8_t)0x00), TIM1_OCPOLARITY_LOW = ((uint8_t)0x22) }
 TIM1 Output Compare Polarity. More...
enum  TIM1_OPMode_TypeDef { TIM1_OPMODE_SINGLE = ((uint8_t)0x01), TIM1_OPMODE_REPETITIVE = ((uint8_t)0x00) }
 TIM1 One Pulse Mode. More...
enum  TIM1_OSSIState_TypeDef { TIM1_OSSISTATE_ENABLE = ((uint8_t)0x04), TIM1_OSSISTATE_DISABLE = ((uint8_t)0x00) }
 TIM1 OSSI: Off-State Selection for Idle mode states. More...
enum  TIM1_OutputNState_TypeDef { TIM1_OUTPUTNSTATE_DISABLE = ((uint8_t)0x00), TIM1_OUTPUTNSTATE_ENABLE = ((uint8_t)0x44) }
 TIM1 Output Compare N States. More...
enum  TIM1_OutputState_TypeDef { TIM1_OUTPUTSTATE_DISABLE = ((uint8_t)0x00), TIM1_OUTPUTSTATE_ENABLE = ((uint8_t)0x11) }
 TIM1 Output Compare states. More...
enum  TIM1_PSCReloadMode_TypeDef { TIM1_PSCRELOADMODE_UPDATE = ((uint8_t)0x00), TIM1_PSCRELOADMODE_IMMEDIATE = ((uint8_t)0x01) }
 TIM1 Prescaler Reload Mode. More...
enum  TIM1_SlaveMode_TypeDef { TIM1_SLAVEMODE_RESET = ((uint8_t)0x04), TIM1_SLAVEMODE_GATED = ((uint8_t)0x05), TIM1_SLAVEMODE_TRIGGER = ((uint8_t)0x06), TIM1_SLAVEMODE_EXTERNAL1 = ((uint8_t)0x07) }
 TIM1 Slave Mode. More...
enum  TIM1_TIxExternalCLK1Source_TypeDef { TIM1_TIXEXTERNALCLK1SOURCE_TI1ED = ((uint8_t)0x40), TIM1_TIXEXTERNALCLK1SOURCE_TI1 = ((uint8_t)0x50), TIM1_TIXEXTERNALCLK1SOURCE_TI2 = ((uint8_t)0x60) }
 TIM1 TIx External Clock Source. More...
enum  TIM1_TRGOSource_TypeDef {
  TIM1_TRGOSOURCE_RESET = ((uint8_t)0x00), TIM1_TRGOSOURCE_ENABLE = ((uint8_t)0x10), TIM1_TRGOSOURCE_UPDATE = ((uint8_t)0x20), TIM1_TRGOSource_OC1 = ((uint8_t)0x30),
  TIM1_TRGOSOURCE_OC1REF = ((uint8_t)0x40), TIM1_TRGOSOURCE_OC2REF = ((uint8_t)0x50), TIM1_TRGOSOURCE_OC3REF = ((uint8_t)0x60)
}
 TIM1 Trigger Output Source. More...
enum  TIM1_TS_TypeDef {
  TIM1_TS_TIM6 = ((uint8_t)0x00), TIM1_TS_TIM5 = ((uint8_t)0x30), TIM1_TS_TI1F_ED = ((uint8_t)0x40), TIM1_TS_TI1FP1 = ((uint8_t)0x50),
  TIM1_TS_TI2FP2 = ((uint8_t)0x60), TIM1_TS_ETRF = ((uint8_t)0x70)
}
 TIM1 Internal Trigger Selection. More...
enum  TIM1_UpdateSource_TypeDef { TIM1_UPDATESOURCE_GLOBAL = ((uint8_t)0x00), TIM1_UPDATESOURCE_REGULAR = ((uint8_t)0x01) }
 TIM1 Update Source. More...

Define Documentation

#define IS_TIM1_AUTOMATIC_OUTPUT_STATE_OK (   STATE)
Value:

Definition at line 186 of file stm8s_tim1.h.

Referenced by TIM1_BDTRConfig().

#define IS_TIM1_BREAK_POLARITY_OK (   POLARITY)
Value:
(((POLARITY) == TIM1_BREAKPOLARITY_LOW) || \
    ((POLARITY) == TIM1_BREAKPOLARITY_HIGH))

Definition at line 176 of file stm8s_tim1.h.

Referenced by TIM1_BDTRConfig().

#define IS_TIM1_BREAK_STATE_OK (   STATE)
Value:
(((STATE) == TIM1_BREAK_ENABLE) || \
                                       ((STATE) == TIM1_BREAK_DISABLE))

Definition at line 167 of file stm8s_tim1.h.

Referenced by TIM1_BDTRConfig().

#define IS_TIM1_CHANNEL_OK (   CHANNEL)
Value:
(((CHANNEL) == TIM1_CHANNEL_1) || \
                                     ((CHANNEL) == TIM1_CHANNEL_2) || \
                                     ((CHANNEL) == TIM1_CHANNEL_3) || \
                                     ((CHANNEL) == TIM1_CHANNEL_4))

Definition at line 92 of file stm8s_tim1.h.

Referenced by TIM1_CCxCmd(), TIM1_ICInit(), and TIM1_SelectOCxM().

#define IS_TIM1_CLEAR_FLAG_OK (   FLAG)    ((((uint16_t)(FLAG) & (uint16_t)0xE100) == 0x0000) && ((FLAG) != 0x0000))

Definition at line 471 of file stm8s_tim1.h.

Referenced by TIM1_ClearFlag().

#define IS_TIM1_COMPLEMENTARY_CHANNEL_OK (   CHANNEL)
Value:
(((CHANNEL) == TIM1_CHANNEL_1) || \
    ((CHANNEL) == TIM1_CHANNEL_2) || \
    ((CHANNEL) == TIM1_CHANNEL_3))

Definition at line 100 of file stm8s_tim1.h.

Referenced by TIM1_CCxNCmd().

#define IS_TIM1_COUNTER_MODE_OK (   MODE)
Value:

Definition at line 115 of file stm8s_tim1.h.

Referenced by TIM1_CounterModeConfig(), and TIM1_TimeBaseInit().

#define IS_TIM1_ENCODER_MODE_OK (   MODE)
Value:
(((MODE) == TIM1_ENCODERMODE_TI1) || \
                                       ((MODE) == TIM1_ENCODERMODE_TI2) || \
                                       ((MODE) == TIM1_ENCODERMODE_TI12))

Definition at line 378 of file stm8s_tim1.h.

Referenced by TIM1_EncoderInterfaceConfig().

#define IS_TIM1_EVENT_SOURCE_OK (   SOURCE)    ((SOURCE) != 0x00)

Definition at line 395 of file stm8s_tim1.h.

Referenced by TIM1_GenerateEvent().

#define IS_TIM1_EXT_POLARITY_OK (   POLARITY)
Value:
(((POLARITY) == TIM1_EXTTRGPOLARITY_INVERTED) || \
    ((POLARITY) == TIM1_EXTTRGPOLARITY_NONINVERTED))

Definition at line 357 of file stm8s_tim1.h.

Referenced by TIM1_ETRClockMode1Config(), and TIM1_ETRClockMode2Config().

#define IS_TIM1_EXT_PRESCALER_OK (   PRESCALER)
Value:
(((PRESCALER) == TIM1_EXTTRGPSC_OFF) || \
    ((PRESCALER) == TIM1_EXTTRGPSC_DIV2) || \
    ((PRESCALER) == TIM1_EXTTRGPSC_DIV4) || \
    ((PRESCALER) == TIM1_EXTTRGPSC_DIV8))

Definition at line 310 of file stm8s_tim1.h.

Referenced by TIM1_ETRClockMode1Config(), and TIM1_ETRClockMode2Config().

#define IS_TIM1_EXT_TRG_FILTER_OK (   FILTER)    ((FILTER) <= 0x0F)

TIM1 External Trigger Filer Value.

Definition at line 274 of file stm8s_tim1.h.

Referenced by TIM1_ETRConfig().

#define IS_TIM1_FORCED_ACTION_OK (   ACTION)
#define IS_TIM1_GET_FLAG_OK (   FLAG)
Value:
(((FLAG) == TIM1_FLAG_UPDATE) || \
                                   ((FLAG) == TIM1_FLAG_CC1) || \
                                   ((FLAG) == TIM1_FLAG_CC2) || \
                                   ((FLAG) == TIM1_FLAG_CC3) || \
                                   ((FLAG) == TIM1_FLAG_CC4) || \
                                   ((FLAG) == TIM1_FLAG_COM) || \
                                   ((FLAG) == TIM1_FLAG_TRIGGER) || \
                                   ((FLAG) == TIM1_FLAG_BREAK) || \
                                   ((FLAG) == TIM1_FLAG_CC1OF) || \
                                   ((FLAG) == TIM1_FLAG_CC2OF) || \
                                   ((FLAG) == TIM1_FLAG_CC3OF) || \
                                   ((FLAG) == TIM1_FLAG_CC4OF))

Definition at line 458 of file stm8s_tim1.h.

Referenced by TIM1_GetFlagStatus().

#define IS_TIM1_GET_IT_OK (   IT)
Value:
(((IT) == TIM1_IT_UPDATE) || \
                               ((IT) == TIM1_IT_CC1) || \
                               ((IT) == TIM1_IT_CC2) || \
                               ((IT) == TIM1_IT_CC3) || \
                               ((IT) == TIM1_IT_CC4) || \
                               ((IT) == TIM1_IT_COM) || \
                               ((IT) == TIM1_IT_TRIGGER) || \
                               ((IT) == TIM1_IT_BREAK))

Definition at line 291 of file stm8s_tim1.h.

Referenced by TIM1_GetITStatus().

#define IS_TIM1_IC_FILTER_OK (   ICFILTER)    ((ICFILTER) <= 0x0F)

TIM1 Input Capture Filer Value.

Definition at line 271 of file stm8s_tim1.h.

Referenced by TIM1_ICInit(), and TIM1_TIxExternalClockConfig().

#define IS_TIM1_IC_POLARITY_OK (   POLARITY)
Value:
(((POLARITY) == TIM1_ICPOLARITY_RISING) || \
    ((POLARITY) == TIM1_ICPOLARITY_FALLING))

Definition at line 240 of file stm8s_tim1.h.

Referenced by TIM1_EncoderInterfaceConfig(), TIM1_ICInit(), TIM1_PWMIConfig(), and TIM1_TIxExternalClockConfig().

#define IS_TIM1_IC_PRESCALER_OK (   PRESCALER)
Value:
(((PRESCALER) == TIM1_ICPSC_DIV1) || \
    ((PRESCALER) == TIM1_ICPSC_DIV2) || \
    ((PRESCALER) == TIM1_ICPSC_DIV4) || \
    ((PRESCALER) == TIM1_ICPSC_DIV8))

Definition at line 264 of file stm8s_tim1.h.

Referenced by TIM1_ICInit(), TIM1_PWMIConfig(), TIM1_SetIC1Prescaler(), TIM1_SetIC2Prescaler(), TIM1_SetIC3Prescaler(), and TIM1_SetIC4Prescaler().

#define IS_TIM1_IC_SELECTION_OK (   SELECTION)
Value:
(((SELECTION) == TIM1_ICSELECTION_DIRECTTI) || \
    ((SELECTION) == TIM1_ICSELECTION_INDIRECTTI) || \
    ((SELECTION) == TIM1_ICSELECTION_TRGI))

Definition at line 251 of file stm8s_tim1.h.

Referenced by TIM1_ICInit(), and TIM1_PWMIConfig().

#define IS_TIM1_IT_OK (   IT)    ((IT) != 0x00)

Definition at line 289 of file stm8s_tim1.h.

Referenced by TIM1_ClearITPendingBit(), and TIM1_ITConfig().

#define IS_TIM1_LOCK_LEVEL_OK (   LEVEL)
Value:
(((LEVEL) == TIM1_LOCKLEVEL_OFF) || \
                                      ((LEVEL) == TIM1_LOCKLEVEL_1) || \
                                      ((LEVEL) == TIM1_LOCKLEVEL_2) || \
                                      ((LEVEL) == TIM1_LOCKLEVEL_3))

Definition at line 198 of file stm8s_tim1.h.

Referenced by TIM1_BDTRConfig().

#define IS_TIM1_OC_MODE_OK (   MODE)
Value:
(((MODE) ==  TIM1_OCMODE_TIMING) || \
                                  ((MODE) == TIM1_OCMODE_ACTIVE) || \
                                  ((MODE) == TIM1_OCMODE_INACTIVE) || \
                                  ((MODE) == TIM1_OCMODE_TOGGLE)|| \
                                  ((MODE) == TIM1_OCMODE_PWM1) || \
                                  ((MODE) == TIM1_OCMODE_PWM2))

Definition at line 55 of file stm8s_tim1.h.

Referenced by TIM1_OC1Init(), TIM1_OC2Init(), TIM1_OC3Init(), and TIM1_OC4Init().

#define IS_TIM1_OC_POLARITY_OK (   POLARITY)
#define IS_TIM1_OCIDLE_STATE_OK (   STATE)
Value:
(((STATE) == TIM1_OCIDLESTATE_SET) || \
                                        ((STATE) == TIM1_OCIDLESTATE_RESET))

Definition at line 220 of file stm8s_tim1.h.

Referenced by TIM1_OC1Init(), TIM1_OC2Init(), TIM1_OC3Init(), and TIM1_OC4Init().

#define IS_TIM1_OCM_OK (   MODE)
Value:
(((MODE) ==  TIM1_OCMODE_TIMING) || \
                             ((MODE) == TIM1_OCMODE_ACTIVE) || \
                             ((MODE) == TIM1_OCMODE_INACTIVE) || \
                             ((MODE) == TIM1_OCMODE_TOGGLE)|| \
                             ((MODE) == TIM1_OCMODE_PWM1) || \
                             ((MODE) == TIM1_OCMODE_PWM2) || \
                             ((MODE) == (uint8_t)TIM1_FORCEDACTION_ACTIVE) || \
                             ((MODE) == (uint8_t)TIM1_FORCEDACTION_INACTIVE))

Definition at line 62 of file stm8s_tim1.h.

Referenced by TIM1_SelectOCxM().

#define IS_TIM1_OCN_POLARITY_OK (   POLARITY)
#define IS_TIM1_OCNIDLE_STATE_OK (   STATE)
Value:
(((STATE) == TIM1_OCNIDLESTATE_SET) || \
    ((STATE) == TIM1_OCNIDLESTATE_RESET))

Definition at line 230 of file stm8s_tim1.h.

Referenced by TIM1_OC1Init(), TIM1_OC2Init(), and TIM1_OC3Init().

#define IS_TIM1_OPM_MODE_OK (   MODE)
Value:
(((MODE) == TIM1_OPMODE_SINGLE) || \
                                   ((MODE) == TIM1_OPMODE_REPETITIVE))

Definition at line 78 of file stm8s_tim1.h.

Referenced by TIM1_SelectOnePulseMode().

#define IS_TIM1_OSSI_STATE_OK (   STATE)
Value:
(((STATE) == TIM1_OSSISTATE_ENABLE) || \
                                      ((STATE) == TIM1_OSSISTATE_DISABLE))

Definition at line 210 of file stm8s_tim1.h.

Referenced by TIM1_BDTRConfig().

#define IS_TIM1_OUTPUT_STATE_OK (   STATE)
Value:
(((STATE) == TIM1_OUTPUTSTATE_DISABLE) || \
                                        ((STATE) == TIM1_OUTPUTSTATE_ENABLE))

Definition at line 148 of file stm8s_tim1.h.

Referenced by TIM1_OC1Init(), TIM1_OC2Init(), TIM1_OC3Init(), and TIM1_OC4Init().

#define IS_TIM1_OUTPUTN_STATE_OK (   STATE)
Value:
(((STATE) == TIM1_OUTPUTNSTATE_DISABLE) ||\
    ((STATE) == TIM1_OUTPUTNSTATE_ENABLE))

Definition at line 158 of file stm8s_tim1.h.

Referenced by TIM1_OC1Init(), TIM1_OC2Init(), and TIM1_OC3Init().

#define IS_TIM1_PRESCALER_RELOAD_OK (   RELOAD)
Value:
(((RELOAD) == TIM1_PSCRELOADMODE_UPDATE) || \
    ((RELOAD) == TIM1_PSCRELOADMODE_IMMEDIATE))

Definition at line 367 of file stm8s_tim1.h.

Referenced by TIM1_PrescalerConfig().

#define IS_TIM1_PWMI_CHANNEL_OK (   CHANNEL)
Value:
(((CHANNEL) == TIM1_CHANNEL_1) || \
    ((CHANNEL) == TIM1_CHANNEL_2))

Definition at line 97 of file stm8s_tim1.h.

Referenced by TIM1_PWMIConfig().

#define IS_TIM1_SLAVE_MODE_OK (   MODE)
Value:
(((MODE) == TIM1_SLAVEMODE_RESET) || \
                                     ((MODE) == TIM1_SLAVEMODE_GATED) || \
                                     ((MODE) == TIM1_SLAVEMODE_TRIGGER) || \
                                     ((MODE) == TIM1_SLAVEMODE_EXTERNAL1))

Definition at line 436 of file stm8s_tim1.h.

Referenced by TIM1_SelectSlaveMode().

#define IS_TIM1_TIX_TRIGGER_SELECTION_OK (   SELECTION)
Value:
(((SELECTION) == TIM1_TS_TI1F_ED) || \
    ((SELECTION) == TIM1_TS_TI1FP1) || \
    ((SELECTION) == TIM1_TS_TI2FP2))

Definition at line 334 of file stm8s_tim1.h.

#define IS_TIM1_TIXCLK_SOURCE_OK (   SOURCE)
Value:

Definition at line 346 of file stm8s_tim1.h.

Referenced by TIM1_TIxExternalClockConfig().

#define IS_TIM1_TRGO_SOURCE_OK (   SOURCE)
Value:
(((SOURCE) == TIM1_TRGOSOURCE_RESET) || \
                                        ((SOURCE) == TIM1_TRGOSOURCE_ENABLE) || \
                                        ((SOURCE) == TIM1_TRGOSOURCE_UPDATE) || \
                                        ((SOURCE) == TIM1_TRGOSource_OC1)  || \
                                        ((SOURCE) == TIM1_TRGOSOURCE_OC1REF) || \
                                        ((SOURCE) == TIM1_TRGOSOURCE_OC2REF) || \
                                        ((SOURCE) == TIM1_TRGOSOURCE_OC3REF))

Definition at line 419 of file stm8s_tim1.h.

Referenced by TIM1_SelectOutputTrigger().

#define IS_TIM1_TRIGGER_SELECTION_OK (   SELECTION)
Value:
(((SELECTION) == TIM1_TS_TI1F_ED) || \
    ((SELECTION) == TIM1_TS_TI1FP1) || \
    ((SELECTION) == TIM1_TS_TI2FP2) || \
    ((SELECTION) == TIM1_TS_ETRF) || \
    ((SELECTION) == TIM1_TS_TIM5) || \
    ((SELECTION) == TIM1_TS_TIM6))

Definition at line 326 of file stm8s_tim1.h.

Referenced by TIM1_SelectInputTrigger().

#define IS_TIM1_UPDATE_SOURCE_OK (   SOURCE)
Value:
(((SOURCE) == TIM1_UPDATESOURCE_GLOBAL) || \
    ((SOURCE) == TIM1_UPDATESOURCE_REGULAR))

Definition at line 404 of file stm8s_tim1.h.

Referenced by TIM1_UpdateRequestConfig().


Enumeration Type Documentation

TIM1 AOE Bit Set/Reset.

Enumerator:
TIM1_AUTOMATICOUTPUT_ENABLE 
TIM1_AUTOMATICOUTPUT_DISABLE 

Definition at line 180 of file stm8s_tim1.h.

TIM1 Break Polarity.

Enumerator:
TIM1_BREAKPOLARITY_LOW 
TIM1_BREAKPOLARITY_HIGH 

Definition at line 171 of file stm8s_tim1.h.

TIM1 Break Input enable/disable.

Enumerator:
TIM1_BREAK_ENABLE 
TIM1_BREAK_DISABLE 

Definition at line 162 of file stm8s_tim1.h.

TIM1 Channel.

Enumerator:
TIM1_CHANNEL_1 
TIM1_CHANNEL_2 
TIM1_CHANNEL_3 
TIM1_CHANNEL_4 

Definition at line 83 of file stm8s_tim1.h.

TIM1 Counter Mode.

Enumerator:
TIM1_COUNTERMODE_UP 
TIM1_COUNTERMODE_DOWN 
TIM1_COUNTERMODE_CENTERALIGNED1 
TIM1_COUNTERMODE_CENTERALIGNED2 
TIM1_COUNTERMODE_CENTERALIGNED3 

Definition at line 106 of file stm8s_tim1.h.

TIM1 Encoder Mode.

Enumerator:
TIM1_ENCODERMODE_TI1 
TIM1_ENCODERMODE_TI2 
TIM1_ENCODERMODE_TI12 

Definition at line 371 of file stm8s_tim1.h.

TIM1 Event Source.

Enumerator:
TIM1_EVENTSOURCE_UPDATE 
TIM1_EVENTSOURCE_CC1 
TIM1_EVENTSOURCE_CC2 
TIM1_EVENTSOURCE_CC3 
TIM1_EVENTSOURCE_CC4 
TIM1_EVENTSOURCE_COM 
TIM1_EVENTSOURCE_TRIGGER 
TIM1_EVENTSOURCE_BREAK 

Definition at line 383 of file stm8s_tim1.h.

TIM1 External Trigger Polarity.

Enumerator:
TIM1_EXTTRGPOLARITY_INVERTED 
TIM1_EXTTRGPOLARITY_NONINVERTED 

Definition at line 351 of file stm8s_tim1.h.

TIM1 External Trigger Prescaler.

Enumerator:
TIM1_EXTTRGPSC_OFF 
TIM1_EXTTRGPSC_DIV2 
TIM1_EXTTRGPSC_DIV4 
TIM1_EXTTRGPSC_DIV8 

Definition at line 302 of file stm8s_tim1.h.

TIM1 Flags.

Enumerator:
TIM1_FLAG_UPDATE 
TIM1_FLAG_CC1 
TIM1_FLAG_CC2 
TIM1_FLAG_CC3 
TIM1_FLAG_CC4 
TIM1_FLAG_COM 
TIM1_FLAG_TRIGGER 
TIM1_FLAG_BREAK 
TIM1_FLAG_CC1OF 
TIM1_FLAG_CC2OF 
TIM1_FLAG_CC3OF 
TIM1_FLAG_CC4OF 

Definition at line 442 of file stm8s_tim1.h.

TIM1 Forced Action.

Enumerator:
TIM1_FORCEDACTION_ACTIVE 
TIM1_FORCEDACTION_INACTIVE 

Definition at line 474 of file stm8s_tim1.h.

TIM1 Input Capture Polarity.

Enumerator:
TIM1_ICPOLARITY_RISING 
TIM1_ICPOLARITY_FALLING 

Definition at line 234 of file stm8s_tim1.h.

TIM1 Input Capture Prescaler.

Enumerator:
TIM1_ICPSC_DIV1 
TIM1_ICPSC_DIV2 
TIM1_ICPSC_DIV4 
TIM1_ICPSC_DIV8 

Definition at line 256 of file stm8s_tim1.h.

TIM1 Input Capture Selection.

Enumerator:
TIM1_ICSELECTION_DIRECTTI 
TIM1_ICSELECTION_INDIRECTTI 
TIM1_ICSELECTION_TRGI 

Definition at line 244 of file stm8s_tim1.h.

TIM1 interrupt sources.

Enumerator:
TIM1_IT_UPDATE 
TIM1_IT_CC1 
TIM1_IT_CC2 
TIM1_IT_CC3 
TIM1_IT_CC4 
TIM1_IT_COM 
TIM1_IT_TRIGGER 
TIM1_IT_BREAK 

Definition at line 277 of file stm8s_tim1.h.

TIM1 Lock levels.

Enumerator:
TIM1_LOCKLEVEL_OFF 
TIM1_LOCKLEVEL_1 
TIM1_LOCKLEVEL_2 
TIM1_LOCKLEVEL_3 

Definition at line 190 of file stm8s_tim1.h.

TIM1 Output Compare Idle State.

Enumerator:
TIM1_OCIDLESTATE_SET 
TIM1_OCIDLESTATE_RESET 

Definition at line 214 of file stm8s_tim1.h.

TIM1 Output Compare and PWM modes.

Enumerator:
TIM1_OCMODE_TIMING 
TIM1_OCMODE_ACTIVE 
TIM1_OCMODE_INACTIVE 
TIM1_OCMODE_TOGGLE 
TIM1_OCMODE_PWM1 
TIM1_OCMODE_PWM2 

Definition at line 45 of file stm8s_tim1.h.

TIM1 Output Compare N Idle State.

Enumerator:
TIM1_OCNIDLESTATE_SET 
TIM1_OCNIDLESTATE_RESET 

Definition at line 224 of file stm8s_tim1.h.

TIM1 Output Compare N Polarity.

Enumerator:
TIM1_OCNPOLARITY_HIGH 
TIM1_OCNPOLARITY_LOW 

Definition at line 132 of file stm8s_tim1.h.

TIM1 Output Compare Polarity.

Enumerator:
TIM1_OCPOLARITY_HIGH 
TIM1_OCPOLARITY_LOW 

Definition at line 122 of file stm8s_tim1.h.

TIM1 One Pulse Mode.

Enumerator:
TIM1_OPMODE_SINGLE 
TIM1_OPMODE_REPETITIVE 

Definition at line 72 of file stm8s_tim1.h.

TIM1 OSSI: Off-State Selection for Idle mode states.

Enumerator:
TIM1_OSSISTATE_ENABLE 
TIM1_OSSISTATE_DISABLE 

Definition at line 204 of file stm8s_tim1.h.

TIM1 Output Compare N States.

Enumerator:
TIM1_OUTPUTNSTATE_DISABLE 
TIM1_OUTPUTNSTATE_ENABLE 

Definition at line 152 of file stm8s_tim1.h.

TIM1 Output Compare states.

Enumerator:
TIM1_OUTPUTSTATE_DISABLE 
TIM1_OUTPUTSTATE_ENABLE 

Definition at line 142 of file stm8s_tim1.h.

TIM1 Prescaler Reload Mode.

Enumerator:
TIM1_PSCRELOADMODE_UPDATE 
TIM1_PSCRELOADMODE_IMMEDIATE 

Definition at line 361 of file stm8s_tim1.h.

TIM1 Slave Mode.

Enumerator:
TIM1_SLAVEMODE_RESET 
TIM1_SLAVEMODE_GATED 
TIM1_SLAVEMODE_TRIGGER 
TIM1_SLAVEMODE_EXTERNAL1 

Definition at line 428 of file stm8s_tim1.h.

TIM1 TIx External Clock Source.

Enumerator:
TIM1_TIXEXTERNALCLK1SOURCE_TI1ED 
TIM1_TIXEXTERNALCLK1SOURCE_TI1 
TIM1_TIXEXTERNALCLK1SOURCE_TI2 

Definition at line 339 of file stm8s_tim1.h.

TIM1 Trigger Output Source.

Enumerator:
TIM1_TRGOSOURCE_RESET 
TIM1_TRGOSOURCE_ENABLE 
TIM1_TRGOSOURCE_UPDATE 
TIM1_TRGOSource_OC1 
TIM1_TRGOSOURCE_OC1REF 
TIM1_TRGOSOURCE_OC2REF 
TIM1_TRGOSOURCE_OC3REF 

Definition at line 408 of file stm8s_tim1.h.

TIM1 Internal Trigger Selection.

Enumerator:
TIM1_TS_TIM6 

TRIG Input source = TIM6 TRIG Output

TIM1_TS_TIM5 

TRIG Input source = TIM5 TRIG Output

TIM1_TS_TI1F_ED 
TIM1_TS_TI1FP1 
TIM1_TS_TI2FP2 
TIM1_TS_ETRF 

Definition at line 316 of file stm8s_tim1.h.

TIM1 Update Source.

Enumerator:
TIM1_UPDATESOURCE_GLOBAL 
TIM1_UPDATESOURCE_REGULAR 

Definition at line 398 of file stm8s_tim1.h.

STM8 Standard Peripherals Library: Footer

 

 

 

      For complete documentation on STM8 8-bit Microcontrollers platform visit www.st.com