2013-10-25 01:06 AM
Hi to everybody,
I'm new to STM32F303, my ploblem is I'm not able to found a valid example on where is showen how to configure two timers in the way to use the first one to acquire an encoder's pulses and the second one to measure the encoder's pulses. Can someone post a snippet of code? I think the STM32F30x's reference manual is very poor in explanation about how to cascade timers. Thank you, Giuseppe2013-10-25 03:37 AM
TIM2 is 32-bit, use that for the encoder?
The master/slave cascading of timers is complicated, there are perhaps some examples in the other firmware libraries, suggest you review those and see if they are enlightening.2013-10-25 04:03 AM
Hi Clive,
thank you for the quick response. I think to have checked all the examples I know, about cascading timers, but unfortunately I wasn't able to find a understable diagram on how to do it. From my point of view I'd like to use the TIM3 in encoder mode, and TIM2 as input capture mode. I really not understand how to configure TIM3 in order to set a trigger to TIM2 every edge of the XORed CH1,CH2 inputs. Does exist an example about how to config that TIMs in the way I described? Regards, Giuseppe