2012-10-30 03:43 AM
Hi guys,
Does someone knows how to configure TIM4 in counter mode for counting any slope on TI2 for SMT32L152xxx ? any help appreciated, Tom ;).2012-10-30 04:06 AM
In TIM4_SMCR, select TI1F_ED in TS bits, and External clock mode 1 in SMS bits.
JW2012-10-30 05:38 AM
Thx, but ..this does not work for TI2
tom2012-10-30 06:19 AM
Hi @all,
I've found out this works for TI2 (I did not set the CCER properly for both edges...) : TIM4->SMCR = 0x00000067; TIM4->CCMR1 = 0x00000000; TIM4->CCER = 0x000000a0; TIM4->CR1 = 0x00000001; Txh for everyone reading, Tom.