my mosfet not fully off

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
Lets play SPICE.
Never let a transistor turn on with a capacitor load. If you have to have a capacitor then this is how.
I added L1 so M1 will turn on into a inductor not a capacitor. C1 is across the motor like you want.
I speed up the PWM by 10:1 from your circuit to keep L1 small.
View attachment 223311
When C1 connects to M1 you had 24A and 20V at the same time on M1. HOT
Now with L1 added M1 turns on with very little current.
thank you for your reply really thank you

i think it's kind of too faraway from my thought.

my circuit is about motor control speed circuit (24v 3a 3800rpm)

i found a lot of circuits, and i tried most of all.

i read datasheets and i learn to calculate NPN base, FET gate resistors

finally i made circuit and through the "RPM to Hz calculation" 3800rpm motor PWM signal start with 120hz.

60khz working good. but fet gets too hot (over 50 degree)

20khz working good. but still fet gets too hot (over 45 degree)

300hz workng good. but there is a ripple.(turn on/off speed like "Car turn indicators")

i tried decrease gate resistor and base resistor.

according to my calculation
2n2222a base R -> 460<R<1K
IRLR024N gate R -> 46<R<460
(time for fully turn off)

so i used heatsink, but everyone says that 24v 3A is not a high voltage so i can do this without heatsink

so i tried add C1 in my circuit, it works good
(not fully off problem was in my code)

i know pwm signal in graph is like rectangle(bolcks)

"make that graph smooth using cap will good" this was my idea.
(between turn on and turn off fill to capacitor)

this is why i'm using C1 in my motor.
it works good but, now i know cap is over charging(20A).

i thought decrease cap value -> decrease cap charging

so i just buy to cap (100uF/50V)

666.jpg
 

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
Lets play SPICE.
Never let a transistor turn on with a capacitor load. If you have to have a capacitor then this is how.
I added L1 so M1 will turn on into a inductor not a capacitor. C1 is across the motor like you want.
I speed up the PWM by 10:1 from your circuit to keep L1 small.
View attachment 223311
When C1 connects to M1 you had 24A and 20V at the same time on M1. HOT
Now with L1 added M1 turns on with very little current.
i found calculation for capacitor

1. Q = C * V

2. 1C= 1A * 1sec

1. Q = V * C
Q = 24v * 1000uF
= 24000uC (0.024C)

2. 1C= 1A * 1sec
0.024C = A * 1sec
A=24A ?

so, C = 470uF
Q=2400uC(0.24C)
A=2.4A

right?
 

Bordodynov

Joined May 20, 2015
3,431
The motor has an inductive component in addition to the active resistance. I am surprised at the persistence of a bad solution - the capacitor is parallel to the motor.
I have painted a new solution without a capacitor. Current filtration is achieved by motor inductance and a high PWM frequency of 20 kHz. At this frequency you will not hear a beep. For a more accurate calculation it is necessary to know (measure) the motor inductance. I have made a parametric calculation of motor currents. Filling ratio of the pulse (at me it is a parameter "p") I changed from 0 to 1 with 0.1 step. Also I plotted the transistor power dependence on "p".
2020-11-25_13-10-32.png2020-11-25_13-12-24.png2020-11-25_13-23-44.png2020-11-25_13-25-08.png
 

Attachments

Wolframore

Joined Jan 21, 2019
2,619
Do you see the difference between these caps and yours? Your caps go across the Motor parallel with it creating a tank. The ones in your example are parallel with the power source enhancing the power and filtering out noise. Note that the caps are going to V+ and Ground.

5471C311-46B4-4E4B-B6F2-EADE738CF0FB.jpeg
 
Last edited:

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
The motor has an inductive component in addition to the active resistance. I am surprised at the persistence of a bad solution - the capacitor is parallel to the motor.
I have painted a new solution without a capacitor. Current filtration is achieved by motor inductance and a high PWM frequency of 20 kHz. At this frequency you will not hear a beep. For a more accurate calculation it is necessary to know (measure) the motor inductance. I have made a parametric calculation of motor currents. Filling ratio of the pulse (at me it is a parameter "p") I changed from 0 to 1 with 0.1 step. Also I plotted the transistor power dependence on "p".
View attachment 223340View attachment 223341View attachment 223342View attachment 223343
really thank you i'll try that!

Do you see the difference between these caps and yours? Your caps go across the Motor parallel with it creating a tank. The ones in your example are parallel with the power source enhancing the power and filtering out noise. Note that the caps are going to V+ and Ground.

View attachment 223349
oh i see. i'm sorry my mistake.
i wote reply and i tried. and i realize my cap is MOTOR's +,-
 

Wolframore

Joined Jan 21, 2019
2,619
There are a few other issues with your interpretation. A BJT does not need a pull down it’s a current controlled device unlike a MOSFET. All that does is waste power. D1 is unnecessary. R4 is unnecessary. It’s really a simple switch circuit in saturation you’ve overcomplicated and caused issues. First you've misinterpreted placement and function and then you mixed BJT with a photointerrupter. Why do you drive the MOSFET with a BJT? MOSFETs are more efficient on their own.
 

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
There are a few other issues with your interpretation. A BJT does not need a pull down it’s a current controlled device unlike a MOSFET. All that does is waste power. D1 is unnecessary. R4 is unnecessary. It’s really a simple switch circuit in saturation you’ve overcomplicated and caused issues. First you've misinterpreted placement and function and then you mixed BJT with a photointerrupter. Why do you drive the MOSFET with a BJT? MOSFETs are more efficient on their own.
oh you mean like this?
optocoupler.png
i searched link hear

tomorrow
i'll try remove 2n2222a (not), C1
 

Wolframore

Joined Jan 21, 2019
2,619
Becareful with what you find on the internet. Why not learn about how they work instead of just copying bad designs anyone can post. You’re just finding something online and guessing.

some issues with this latest find...

1. uC pins can only source so much current, I would not want to source 20mA on one so poor design there but at least this can work.

2. R6 and D2 - what’s their purpose?

3. this is a resistive load so not like your motor at all

4. mosfet is short to current sink when it’s on, also N Channel should be low side switch to work correctly...

anyhow it’s bad without doing deep analysis... not worth it. Learn how things work instead of copy bad ideas.
 

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
Becareful with what you find on the internet. Why not learn about how they work instead of just copying bad designs anyone can post. You’re just finding something online and guessing.

some issues with this latest find...

1. uC pins can only source so much current, I would not want to source 20mA on one so poor design there but at least this can work.

2. R6 and D2 - what’s their purpose?

3. this is a resistive load so not like your motor at all

4. mosfet is short to current sink when it’s on, also N Channel should be low side switch to work correctly...

anyhow it’s bad without doing deep analysis... not worth it. Learn how things work instead of copy bad ideas.
thank you for your advice!

i think i tried go only the easy way it's my fault. It is embrassing.

so far, main issue on my project.

low frequency -> ripple
high frequency -> heat

my first mistake is i was completely misunderstand between "ripple", "noise"

so i tried bad ideas.

my second mistake is i was completely misunderstand BJT TR, FET
so i tried copy some other circuits.
(main power is 24v->5v lm7805, so if i don't use TR to FET gate, lm7805 gets hot)

finally i figure out what i have to know.

1. fet with PWM control need rapidly charge and discharge
so BJT TR is wrong choice (especially high frequency)
2. know about diode
using FR diode

this is my conclusion.

thank you all!
 

Wolframore

Joined Jan 21, 2019
2,619
7805 is a linear regulator, using it with 24V to produce 5v means you have to burn off the difference which when you consider the power formula increase with current. This is why it’s so hot and inefficient. You’re also at the limit of the LM7805 which can work up to 25v input so a small spike may burn it out. If you don’t care about efficiency it’s meh... you may have been pushing original mosfet incorrectly which caused the regulator to heat up if you have no issue with regulator now. Using mosfet for switching should be possible to do it more efficient not less n
 

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
7805 is a linear regulator, using it with 24V to produce 5v means you have to burn off the difference which when you consider the power formula increase with current. This is why it’s so hot and inefficient. You’re also at the limit of the LM7805 which can work up to 25v input so a small spike may burn it out. If you don’t care about efficiency it’s meh... you may have been pushing original mosfet incorrectly which caused the regulator to heat up if you have no issue with regulator now. Using mosfet for switching should be possible to do it more efficient not less n
yes your right

i need power just turn on MCU, 2digit-segment.

so i use simple circuit with lm7805 instead lm2576

i used electronical cap, shotkey diode to stabilize lm7805.

i know if i use lm2576 (output 3A) very easy to motor speed control

but i want pwm controlling way...
 

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
final_circuit.png
this is my final circuit!

PWM 50Khz with no noise fet gets little warm (about 30 degree)
i think it's fine.

main issue was in my BJT. i remove all and change diode to FR diode

it works good but i have a little problem.

i controlling PWM with 10K potentialmeter.

PWM duty is 20, 50, 70, 90 4step.

when i decrease duty, 90 -> 20 rapidly FET gets toooooo hot and damaged to MCU.

do i have to add capacitor somewhere? (i think gate is not a right place)

or add FET shortkey diode?
 

ScottWang

Joined Aug 23, 2012
7,501
this is my final circuit!
I already mentioned this in post #15, but you just ingnored it, probably you want to learn something from errors.

when i decrease duty, 90 -> 20 rapidly FET gets toooooo hot and damaged to MCU.
When you take the bjt away then you also need to change the program, because the orignal duty cycle is inverts with no bjt, plesse go back to check my post.
 

Thread Starter

Kim-JiHoon

Joined May 3, 2020
133
I already mentioned this in post #15, but you just ingnored it, probably you want to learn something from errors.


When you take the bjt away then you also need to change the program, because the orignal duty cycle is inverts with no bjt, plesse go back to check my post.
OMG i'm sorry, i just read your post #15 !

i know i have to change the program, and i changed.

i mean i'm controlling PWM with potentialmeter(VR).

if i change the VR high to low fast. my MCU and FET die.
not always. sometimes.

i changed my program add delay.
but i think i should something more protecting.

like add capacitor for 'changing motor speed slow'
 

ronsimpson

Joined Oct 7, 2019
4,690
Post #32 FET too hot.
3A motor? Is the motor really pulling 3A? The current very much is related to load and RPM.
What is the Gate voltage. It needs to be at least 5V.

Assuming Gate voltage = 5V, Motor current 3A, MOSFET = 0.1 ohms internal resistance, 3A X 0.1V = 0.3V across the transistor, = 0.9 watts. The part will get a little hot. Now if the Gate voltage is only 4V the heat will be up 1.4X.

Gate resistor is a little large. So the part is switching slow which will increase the heat some.
 

Wolframore

Joined Jan 21, 2019
2,619
What’s the PWM source? Microcontrollers have a max current on output pin of 20-40mA. Be careful going smaller, 100 Ohms is pushing it. I’m sure it’s a power supply issue or poorly specd NMOS. What is too hot? @3A assuming it’s as the spec you’re dissipating 1/3 watts at the MOSFET. Its going to get hot. Brownout are probably power supply issues. Could be your source or your cruddy 7805 Did you decouple the regulator?
 

eetech00

Joined Jun 8, 2013
4,705
As mentioned in post 37, the gate resistor could be smaller, so less voltage drop, and higher voltage at the gate. In addition, a pull down resistor should be connected from gate to ground to ensure the mosfet turns off with no signal from MCU (gpio will also float at boot-up or reset).
 

ScottWang

Joined Aug 23, 2012
7,501
when i decrease duty, 90 -> 20 rapidly FET gets toooooo hot and damaged to MCU.
I'm thinking a method to protects the MCU and that is to use a diode as 1n4001 or maybe 1n4148 to replace the R1, and in papallel with a 2.2K for Vgs.

Edit : 2.2K is designed to discharge the Cgs and provides Vg a low level when the MCU output low, so the values need to try, specially when the input frequency up to 50 Khz.
 
Top