English
Language : 

AN4277 Datasheet, PDF (17/23 Pages) STMicroelectronics – Using STM32F3 Series PWM shut-down features for motor control and digital power conversion
AN4277
Using the break function with other MCU resources
Table 5. Comparator output connected externally to break inputs,
with low break polarity
Description
Register
Bit
Configuration
TIM1/8/20 BRK polarity
TIMx_BDTR BKP
0 (active low), it means that the external signal
goes low during the fault
Comparator output polarity
TIM1/8/20 BKIN AF
COMPx_CSR COMPxPOL
GPIOxAFRL
or
-
GPIOxAFRH
0 (not inverted), comparators input connected
as shown in previous sections
AF enabled on BKIN pin selected among
available
TIM1/8/20 BRK enable
COMPx out selection
TIMX_BDTR BKE
1
COMPx_CSR
COMPxOUTSEL
0001: TIM1 BRK
0011: TIM8 BRK
1100: TIM20 BRK
Table 6. Comparator output connected externally to break inputs,
with high break polarity
Description
Register
Bit
Configuration
TIM1/8/20 BRK/BRK2 polarity TIMx_BDTR BKP or BK2P
Comparator output polarity COMPx_CSR COMPxPOL
1 (active high), it means that the external signal
goes high during the fault
0 (not inverted), comparators input connected
as shown in previous sections
TIM1/8/20 BKIN/BKIN2 AF
GPIOxAFRL
or
GPIOxAFRH
-
AF enabled on BKIN/BKIN2 pin selected among
available
TIM1/8/20 BRK/BRK2 enable TIMX_BDTR BKE or BK2E 1
COMPx out selection
0001: TIM1 BRK
0010: TIM1 BRK2
0011: TIM8 BRK
COMPx_CSR
COMPxOUTSEL
0100: TIM8 BRK2
0101: TIM1 BRK2 + TIM8 BRK2
1100: TIM20 BRK
1101: TIM20 BRK2
1110: TIM1 BRK2 + TIM8 BRK2 + TIM20 BRK2
Comparators output can be optionally enabled as alternate function on the related GPIO
pin, in push-pull or open-drain mode, for signaling to other devices or for debugging
purposes.
DocID024409 Rev 2
17/23
22