cancel
Showing results for 
Search instead for 
Did you mean: 

INPUT CAPTURE for timer 3 and timer 13

yang hong
Associate II
Posted on May 07, 2018 at 20:54

Hello, 

I have one input channel for timer. I notice PA6 either for TIM3-CH1 or TIM13-CH1. So it is possible to map pin for both of timers (3 and 13).  if I can do it, how to set them?

Regards,

7 REPLIES 7
Posted on May 07, 2018 at 21:06

it is possible to map pin for both of timers

Unless it's a 'F1xx, no.

JW

Posted on May 07, 2018 at 21:10

I need one input signal for two timers for different task. I am using f429zi. Do you have some suggestion? 

Posted on May 07, 2018 at 21:14

Easy three steps:

1. Assign two pins, one for each of the two timers.

2. Wire the two pins together 

3. Sit back and enjoy your work.

Posted on May 07, 2018 at 21:33

I know I can use 2 pins for this features, but I just want to save one pin for that, and also it looks 2 resources now even 2 pins comes from the same resource. one of timer will do slow work and check frequency features including frequency, pulse width, another timer is high resolution timer for different test task, when frequency disappears slow timer will issue a error flag and let high resolution timer stop test. 

I can use exti_gpio to have trigger event for this digital input pin even I connect it to one of the timer, external frequency is low, something 50 to 60 Hz, so is it possible to use exti event to estimate pulse width?  

Regards,

Posted on May 07, 2018 at 21:53

In TIM3, you could use the CH1 as source for TRGO (by setting TIM3_CR2.MMS=0b011), and then you'll have one edge of that signal available at some other timer as TRGI, if your STM32 model (which you still did not tell us) has such a link (IMO most of them have).

This may or may not be suitable for your purpose - it's upon you to judge this.

JW

Posted on May 07, 2018 at 21:55

Hello, 

I forget my model, NUCLEO-F429ZI

Posted on May 07, 2018 at 23:07

Hard to tell, as you didn't specify your design environment.

I think it is less helpful to ask people how to do a specific thing. Instead, tell people your goal, and how you intend to achieve it. That allows people to offer you alternative solutions that may get to your goal faster.