Transient voltage spikes with PWM mosfet

Introduction and miscellaneous that we haven't created categories for, yet
Post Reply
jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Transient voltage spikes with PWM mosfet

Post by jon volk »

On a somewhat unrelated project I have a very simple mosfet PWM circuit to drive a solenoid in pick and hold fashion. Function works as expected with a 50% duty dropping current as expected. However, when putting a scope on the power input, Im still seeing what appears to be somewhat random transient voltage spikes of around 50v. Im using an SS29FA Schottky as a flyback diode. Initial full voltage hit is around 3amps, but holding current shows to be around 1.4. Recovery time is only 7ns, so that seemingly should be fine even at the 20khz frequency. Is there something glaringly obvious that my noobie self is missing here? Running the higher frequency to avoid audible noise while in holding current mode.
Attachments
PWM.pdf
(15.78 KiB) Downloaded 67 times
IMG_3654.jpg
Formerly 92 E30 BMW Cabrio with Tesla power
User avatar
Peter
Posts: 310
Joined: Fri Dec 14, 2018 9:07 pm
Location: North West Lancs, UK
Been thanked: 8 times

Re: Transient voltage spikes with PWM mosfet

Post by Peter »

If you send the circuit we can take a look and maybe advise. Peter
User avatar
johu
Site Admin
Posts: 5769
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 157 times
Been thanked: 1010 times
Contact:

Re: Transient voltage spikes with PWM mosfet

Post by johu »

Can you put a cap between 24V and GND?
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Re: Transient voltage spikes with PWM mosfet

Post by jon volk »

johu wrote: Tue Jun 15, 2021 9:35 am Can you put a cap between 24V and GND?
I can certainly try it. Any rule of thumb for selecting value? General interwebz searching yields values or selection criteria all over the map.

I also tested a smaller load under 1a and that did not appear to show any spikes back to the supply voltage.
Formerly 92 E30 BMW Cabrio with Tesla power
jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Re: Transient voltage spikes with PWM mosfet

Post by jon volk »

Peter wrote: Tue Jun 15, 2021 9:20 am If you send the circuit we can take a look and maybe advise. Peter
It’s shown in the pdf attachment
Formerly 92 E30 BMW Cabrio with Tesla power
User avatar
bexander
Posts: 835
Joined: Tue Jun 16, 2020 6:00 pm
Location: Gothenburg, Sweden
Has thanked: 63 times
Been thanked: 89 times

Re: Transient voltage spikes with PWM mosfet

Post by bexander »

How is the scope probe grounded?
Do you still pickup the disturbance if you leave the probe unconnected (only ground connected) in the air close by?
I'm thinking, it is the switch noise you are picking up. You have a very high time division of 1s/div so really hard to tell.
What is the result from the same measurement with a time base of 50us/div?
jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Re: Transient voltage spikes with PWM mosfet

Post by jon volk »

Ill need to get another capture on a slower time scale, I had zoomed out since the nature of the events was inconsistent to capture a greater number on one screen. Ill need to try with just the ground connected as I did not attempt such a test.

The BNC probe is simply connected to 24v in and the ground clip to the return ground lead of the power supply. The leads from the power supply to the pwm circuit are around 12-14" long.
Formerly 92 E30 BMW Cabrio with Tesla power
User avatar
bexander
Posts: 835
Joined: Tue Jun 16, 2020 6:00 pm
Location: Gothenburg, Sweden
Has thanked: 63 times
Been thanked: 89 times

Re: Transient voltage spikes with PWM mosfet

Post by bexander »

Might be a good idea with a capacitor as johu suggests. Perhaps 100nF ceramic in parallel with 10-100uF electrolytic capacitor. Values are not that important to see if it has desired effect.
jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Re: Transient voltage spikes with PWM mosfet

Post by jon volk »

Thanks guys. Ill give that a shot and see what shakes out.
Formerly 92 E30 BMW Cabrio with Tesla power
SRFirefox
Posts: 28
Joined: Thu Jun 25, 2020 2:28 am

Re: Transient voltage spikes with PWM mosfet

Post by SRFirefox »

I assume you have a two layer board this is laid out on. If you just have a mosfet and some wires etc or just a couple thin traces on a board, then the inductance in your leads/traces is ringing up with your fast rise/fall times. Especially if you have a very small gate charge and fast switching mosfet, the switching edges can be incredibly sharp. In addition to the cap on your +24V supply, make sure it's as close to the +24V connection of your diode/inductor as possible. Additionally, make sure you have a ground plane under these components if you can, which will reduce the stray inductance energized by the switching edges.

Finally, if those work but don't remove it entirely, you can intentionally increase the gate-source capacitance of your mosfet to reduce its switching speed. This does increase switching losses, so it's a balance between reducing switching noise and increasing switching losses, but works in case all else fails. If you're running a relatively low frequency, an increase of switching losses will be negligible.
jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Re: Transient voltage spikes with PWM mosfet

Post by jon volk »

Great info. The PCB is only 25mmx25mm and utilizes planes for 24v and ground. The only thin traces are for signals.

I added a 100nf ceramic capacitor across the input pins since it was most accessible location and that knocked the magnitude of the voltage spikes from almost 40v down to 9v max. Perhaps slightly better performance can be had moving that next to my flyback diode, but its a drastic improvement with a minimal change.
Formerly 92 E30 BMW Cabrio with Tesla power
Post Reply