Bidirectional break mode not working with short pulses
Description
The TIM_BKIN and TIM_BKIN2 I/Os can be configured in bidirectional mode using the BKBID and BK2BID bits in the TIMx_BDTR register, to be forced to 0 when a break/break2 event occurs. The bidirectional break/break2 mode is not functional when the pulse width on break/break2 input is lower than two tim_ker_clk periods.
This limitation is also valid when software break events are generated (the break event is correctly generated internally but not reflected on break inputs).
Workaround
None.
For applications that can afford some latency in bidirectional break mode, the break interrupt can eventually be enabled, for the CPU to verify the break input state and force it to zero when a break/break2 event occurred.
Unexpected PWM output when using ocref_clr
Description
In combined PWM mode 1, asymmetric PWM mode 1, or asymmetric PWM mode 2, using ocref_clr can cause the tim_ocxrefc output to be unexpectedly re-enabled or disabled. This behavior depends on the timing of when ocref_clr is activated and deactivated.
Workaround
None.
Timer connection to USB SOF might not work properly
Description
USB SOF signal might not be properly synchronized with TIM2 and TIM5 ITR12.
Workaround
Connect externally USB SOF (PA8) and the timer ETR input pin.
LPTIM
Device may remain stuck in LPTIM interrupt when entering Stop mode
Description
This limitation occurs when disabling the low-power timer (LPTIM).
When the user application clears the ENABLE bit in the LPTIM_CR register within a small time window around one LPTIM interrupt occurrence, then the LPTIM interrupt signal used to wake up the device from Stop mode may be frozen in active state. Consequently, when trying to enter Stop mode, this limitation prevents the device from entering low-power mode and the firmware remains stuck in the LPTIM interrupt routine.
This limitation applies to all Stop modes and to all instances of the LPTIM. Note that the occurrence of this issue is very low.Workaround
In order to disable a low power timer (LPTIMx) peripheral, do not clear its ENABLE bit in its respective LPTIM_CR register. Instead, reset the whole LPTIMx peripheral via the RCC controller by setting and resetting its respective LPTIMxRST bit in the relevant RCC register.
ARRM and CMPM flags are not set when APB clock is slower than kernel clock
Description
When LPTIM is configured in one shot mode and APB clock is lower than kernel clock, there is a chance that ARRM and CMPM flags are not set at the end of the counting cycle defined by the repetition value REP[7:0]. This issue can only occur when the repetition counter is configured with an odd repetition value.
Workaround
To avoid this issue, the following formula must be respected:{ARR, CMP} ≥ KER_CLK / (2* APB_CLK),
where APB_CLK is the LPTIM APB clock frequency, and KER_CLK is the LPTIM kernel clock frequency. ARR and CMP are expressed in decimal value.
Example: The following example illustrates a configuration where the issue can occur:- APB clock source (MSI) = 1 MHz, kernel clock source (HSI) = 16 MHz
- The repetition counter is set with REP[7:0] = 0x3 (odd value)
{CMP, ARR} ≥ 16 MHz / (2 * 1 MHz)
→ ARR must be ≥ 8 and CMP must be ≥ 8REP set to 0x3 means that effective repetition is REP+1 (= 4) but the user must consider the parity of the value loaded in the LPTIM_RCR register (=3, odd) to assess the risk of issue.
Interrupt status flag is cleared by hardware upon writing its corresponding bit in LPTIM_DIER register
Description
When any interrupt bit of the LPTIM_DIER register is modified, the corresponding flag of the LPTIM_ISR register is cleared by hardware.
Workaround
None.
PLL2 output cannot be used as LPTIM clock source
Description
When pll2_p_ck is selected as LPTIMx clock source by setting LPTIMxSEL[2:0] bitfield of the RCC_CCIPR2 register to 0b001, LPTIMx does not receive its kernel clock, and does not properly operate.
Workaround
Avoid selecting pll2_p_ck as clock source for LPTIMx.
Select any other clock source by programming LPTIMxSEL[2:0] to a value different from 0b001. Refer to the device reference manual for the list of possible values.
IWDG
Independent watchdog does not wake up the system from Stop mode
Description
The independent watchdog early wakeup interrupt does not wake up the system from Stop mode.
Workaround
None.RTC
Alarm flag may be repeatedly set when the core is stopped in debug
Description
When the core is stopped in debug mode, the clock is supplied to subsecond RTC alarm downcounter even when the device is configured to stop the RTC in debug.
As a consequence, when the subsecond counter is used for alarm condition (the MASKSS[3:0] bitfield of the RTC_ALRMASSR and/or RTC_ALRMBSSR register set to a non-zero value) and the alarm condition is met just before entering a breakpoint or printf, the ALRAF and/or ALRBF flag of the RTC_SR register is repeatedly set by hardware during the breakpoint or printf, which makes any attempt to clear the flag(s) ineffective.
Workaround
None.RTC wrong calendar read value through shadow registers
Description
When the BYPSHAD control bit in the RTC_CR register is cleared, reading the RTC calendar registers (RTC_SSR, RTC_TR, and RTC_DR) may seldom produce incorrect values. This issue occurs because internal timing can cause the asynchronous RTC calendar registers to be copied into their shadow registers during a transition of the asynchronous registers.
Since this copying process occurs every RTC kernel clock cycle, any erroneous value persists for only one RTC kernel clock cycle. The likelihood of this failure is very low and depends on several factors, including:
- RTC software configuration, such as the RTC kernel clock source, asynchronous prescaler factor, and calibration settings.
- APB clock frequency.
- Operating voltage and temperature.
- The timing of the register read operation.
Additionally, process variations may cause timing differences between samples, which can also influence the probability of this failure.
Workaround
To eliminate the risk of failure, set the BYPSHAD control bit to 1 (bypassing the shadow registers) and read the registers twice. Then, compare the two readings. If the values differ, repeat the process until matching results are obtained. Refer to the reference manual section Reading the calendar - When the BYPSHAD control bit is set in the RTC_CR register (bypass shadow registers) for more details.
Timestamp flag unexpectedly raised when disabling timestamp
Description
- timestamp negative edge detection is requested, and
- no edge has occurred
The other detection configurations are not impacted.
Workaround
- in polling mode, wait for 7 ms to allow the TSF flag to be set. Then clear it.
- in interrupt mode: clear the TSF flag as soon as it is set.