STM8L15x Standard Peripherals Drivers
|
RI configuration. More...
Functions | |
void | SYSCFG_RIAnalogSwitchConfig (RI_AnalogSwitch_TypeDef RI_AnalogSwitch, FunctionalState NewState) |
Enables or disables the Routing Interface Analog switch. | |
void | SYSCFG_RIDeInit (void) |
Deinitializes the RI registers to their default reset values. | |
void | SYSCFG_RIIOSwitchConfig (RI_IOSwitch_TypeDef RI_IOSwitch, FunctionalState NewState) |
Closes or Opens the routing interface Input Output switches. | |
void | SYSCFG_RIResistorConfig (RI_Resistor_TypeDef RI_Resistor, FunctionalState NewState) |
Configures the Pull-up and Pull-down Resistors. | |
void | SYSCFG_RITIMInputCaptureConfig (RI_InputCapture_TypeDef RI_InputCapture, RI_InputCaptureRouting_TypeDef RI_InputCaptureRouting) |
Configures the routing interface to select which Input Output pin to be routed to TIM1 Input Capture. |
Detailed Description
RI configuration.
=============================================================================== RI configuration functions =============================================================================== =================================================================== SYSCFG Driver: how to configure RI =================================================================== 1. By default, TIM1 Input Capture channels 2 and 3 are connected to the I/O port assigned in the datasheet pinout (default routing). TIM1 Input Capture channels 2 and 3 can be routed by calling SYSCFG_RITIMInputCaptureConfig() Refer to the device reference manual for more details about TIM1 input capture routing 2. For more details about using SYSCFG_RIIOSwitchConfig() and SYSCFG_RIAnalogSwitchConfig() with COMP1 and COMP2, refer to comparators driver 3. To output the Internal reference voltage VREFINT, configure corresponding GPIO pin in input mode using GPIO_Init() then use SYSCFG_RIIOSwitchConfig() 4. To use the internal Pull-up and Pull-down resistors call SYSCFG_RIResistorConfig()
Function Documentation
void SYSCFG_RIAnalogSwitchConfig | ( | RI_AnalogSwitch_TypeDef | RI_AnalogSwitch, |
FunctionalState | NewState | ||
) |
Enables or disables the Routing Interface Analog switch.
Definition at line 177 of file stm8l15x_syscfg.c.
References DISABLE, IS_FUNCTIONAL_STATE, IS_RI_ANALOGSWITCH, and RI.
void SYSCFG_RIDeInit | ( | void | ) |
Deinitializes the RI registers to their default reset values.
< Set RI->ICR1 to reset value
< Set RI->ICR2 to reset value
< Set RI->IOSR1 to reset value
< Set RI->IOSR2 to reset value
< Set RI->IOSR3 to reset value
< Set RI->IOSR3 to reset value
< Set RI->ASCR1 to reset value
< Set RI->ASCR2 to reset value
< Set RI->RCR to reset value
Definition at line 112 of file stm8l15x_syscfg.c.
References RI, RI_ASCR1_RESET_VALUE, RI_ASCR2_RESET_VALUE, RI_ICR1_RESET_VALUE, RI_ICR2_RESET_VALUE, RI_IOSR1_RESET_VALUE, RI_IOSR2_RESET_VALUE, RI_IOSR3_RESET_VALUE, RI_IOSR4_RESET_VALUE, and RI_RCR_RESET_VALUE.
void SYSCFG_RIIOSwitchConfig | ( | RI_IOSwitch_TypeDef | RI_IOSwitch, |
FunctionalState | NewState | ||
) |
Closes or Opens the routing interface Input Output switches.
Definition at line 227 of file stm8l15x_syscfg.c.
References DISABLE, IS_FUNCTIONAL_STATE, IS_RI_IOSWITCH, and RI.
void SYSCFG_RIResistorConfig | ( | RI_Resistor_TypeDef | RI_Resistor, |
FunctionalState | NewState | ||
) |
Configures the Pull-up and Pull-down Resistors.
Definition at line 313 of file stm8l15x_syscfg.c.
References DISABLE, IS_FUNCTIONAL_STATE, IS_RI_RESISTOR, and RI.
void SYSCFG_RITIMInputCaptureConfig | ( | RI_InputCapture_TypeDef | RI_InputCapture, |
RI_InputCaptureRouting_TypeDef | RI_InputCaptureRouting | ||
) |
Configures the routing interface to select which Input Output pin to be routed to TIM1 Input Capture.
Definition at line 135 of file stm8l15x_syscfg.c.
References IS_RI_INPUTCAPTURE, IS_RI_INPUTCAPTUREROUTING, RI, and RI_InputCapture_IC2.