2021-08-21 04:25 PM
Hi All,
I'm playing around with the Timers at the moment on a STM32F303 and currently have TIM2 and TIM6 generating an output pulse on every OC event (different frequency ranges).
Those Timer based output toggles are of course somewhat locked to certain pins on the MCU via the GPIO alternate function set up.
I would like to duplicate the output pulses on other pins.
So for example I have TIM2_CH1 output compare toggle assigned to GPIOA Port 0, is the only way I could duplicate that pulse on another pin (say PA1) would be to do something like this. When the TIM2 Interrupt happens, read the PA0 pin state (which the Timer just toggled) and duplicate that on PA1 just by toggling that pin directly through the GPIO BSRR register? Easy enough to do that but it also defeats the advantage of having the timer generate the output toggle directly.
The reason I want to duplicate the pulse from each timer is because I need to drive two digital FET's (FDV301N) for each pulse output, but I am not sure if I can tie the gates of two FET's to the same output pin on the MCU. If I can do that without any issues then that solution would work just fine.
Thanks.
Solved! Go to Solution.
2021-08-21 04:46 PM
> I am not sure if I can tie the gates of two FET's to the same output pin on the MCU. If I can do that without any issues then that solution would work just fine.
Compare the output current capability of given pin (from the STM32 datasheet) to input current requirement of the FET.
The latter is statically probably orders of magnitude lower than the former, but then there's also the requirement to charge/discharge the FET's gate capacitance quickly enough.
JW
2021-08-21 04:46 PM
> I am not sure if I can tie the gates of two FET's to the same output pin on the MCU. If I can do that without any issues then that solution would work just fine.
Compare the output current capability of given pin (from the STM32 datasheet) to input current requirement of the FET.
The latter is statically probably orders of magnitude lower than the former, but then there's also the requirement to charge/discharge the FET's gate capacitance quickly enough.
JW