Setting up STM32 timer for UART IDLE detection
Just in case anybody tries to follow AN3109, here is what I did wrong:


forgot to configure TIM1 clock source as TIM_CLOCKSOURCE_INTERNAL;
did not enable TIM1 update interrupt in NVIC (it is not necessary for IDLE detection but required for this test);


In the end everything works as expected. Well... I'd expect HAL to support HW IDLE flag  but that is probably to much to ask.