2021-09-22 12:37 PM
Hi, i`m having an issue driving a mosfet(irfz44n n channel---it`s a boost converter from 12v to 42v dc), the thing is that i`m usnig a PWM signal of the stm32f103c8tx, when it`s a %50 duty cycle i`ve got around 1.6v aprox, it`s not enough to power the gate properly, so i added a totem pole config with an extra npn transistor driving them, but the problem persists, i`ve been reading and find out about the open drain mode, so the pin pb10 is in GPIO_MODE_AF_OD but when i generate the pwm the 3.3v shows up, does anybody have an idea on how to doi it? .. I`m using cubemx.
The circuit is working cause i can reach 60vdc at the output, but i need to change the duty cycle to control the 42vdc.
Since i can`t figure it out, i`ve been thinking on a smaller mosfet to level the tension to 5v, with the 2n7000 or bs170. 11
Sorry for al the text, thanks!!
2021-09-24 12:17 PM
If you initialize it as a GPIO OD output, can you drive the circuit? If so, the problem is in how you're using the timer.
Might be easier to explain with a schematic.
2021-09-24 10:34 PM
Hi, yes, actually the problem was that, what i did now is that i set the pin as GPIO_MODE_AF_OD and then i set the timer2 channel 3 as pwm generation no output, with a pull up resistor to 5v, and the square wave is correct, inverted but ok, just change the way that generates it, so it`s working good right now.