Hello. Dear forum users, help to understand the problem of the incorrect operation of the PWM control program. I'm writing on HAL in KEIL v5 environment, the signals are monitored by the analyzer. The problem is this: I generate the bursts of pulses with the help of PWM (for IR-diode) _ has set the TIM14 (PWM) and TIM16 (pulse length) timer, the number of pulses and pauses by logic. At start-up, pulses and pauses (fuzzy errors) are formed not of the same duration, but the PWM (see Fig.) Is also switched on during the pause. I'm applying a picture from the analyzer: the upper pulses are the output from port A0, so to say the additional transmission control to the infrared. Originally planned to do this on IRTIM when receiving from UART (it is very necessary) but there does not start at all. For a long time I am suffering and I can not write to the forum, I tried to transfer the code to stm32f103c8t6, too, I ask not to kick stm, I recently do it - before this spike). The code is below (only the form packs and with the button on port A6). I understand that somewhere my jamb, but where? Thank you in advance.