Stm32 Encoder Mode