Author Topic: N-MOSFET level shift and PWM driver  (Read 10698 times)

0 Members and 1 Guest are viewing this topic.

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
N-MOSFET level shift and PWM driver
« on: May 11, 2014, 02:59:59 pm »
Hi All,

I've been toying with a MOSFET driven motor and some PWM off of a Raspberry Pi. The PI is putting out 3.3v and the motor is a 12-28V DC with at least 10A draw. I choose the FQP30N06L (https://www.sparkfun.com/products/10213) for the logic level gate and high drain-source current. However, I was having difficulty (blue smoke) using a single MOSFET with a high side load and powering the motor at 28V. Researching lead me to believe that the MOSFET might be in the linear region with a higher than anticipate Rdson - which jived with my burnt fingers (was using hefty heat sink and thermal paste).

I decided the fix was a level shifter to get firmly in the active region. However, I was also impatient and figured using another MOSFET I could achieve basically the same end. See link for pic.



Using the first to switch in the voltage divided 28V source (should be around 10V, exact value shouldn't matter). Checking the circuit I connected the 3.3V in and GND lines to effectively shut of the first stage and 'full on' the second. The fluke shows ~10V at the R1 R2 junction, however, the second transistor doesn't seem to come fully on at all. In fact, the total draw (as referenced from my bench supply) is only about 0.8A and the motor doesn't budge. Another curious output was the D-S voltage (with 10V G-S) was like 600V (probably a fluke Fluke?).

Being NOT an EE I turn to you all for some quick insight. Where did I go wrong and how do I drive this large(ish) motor? Bonus points for solutions including only the referenced MOSFET and resistors...as that is what I have on hand today!
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 8177
  • Country: de
  • A qualified hobbyist ;)
Re: N-MOSFET level shift and PWM driver
« Reply #1 on: May 11, 2014, 03:25:57 pm »
Could you please also post your original circuit. Based on the datasheet the MOSFET should pass 20A with a V_GS of 3.3V.
 

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
Re: N-MOSFET level shift and PWM driver
« Reply #2 on: May 11, 2014, 03:34:48 pm »

This circuit would drive the motor correctly below 28V (around 12V with some excessive heating).  Only a few seconds at 28V would burn the MOSFET (shorts on all leads, and either full on or open).





 

Offline retrolefty

  • Super Contributor
  • ***
  • Posts: 1648
  • Country: us
  • measurement changes behavior
Re: N-MOSFET level shift and PWM driver
« Reply #3 on: May 11, 2014, 03:40:06 pm »
R1 being such a large value will really slow down the switching time from off to on but not sure if that explains the static current level you are reading, unless you are using PWM at some intermediate value?
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: N-MOSFET level shift and PWM driver
« Reply #4 on: May 11, 2014, 03:45:26 pm »
Quote
with at least 10A draw.

It is not possible to design for such a load. You should understand the upper end of the current draw before you can start somewhere.

================================
https://dannyelectronics.wordpress.com/
 

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
Re: N-MOSFET level shift and PWM driver
« Reply #5 on: May 11, 2014, 03:55:49 pm »
Quote
with at least 10A draw.

It is not possible to design for such a load. You should understand the upper end of the current draw before you can start somewhere.

Could you elaborate?  Tests with the motor starting from 0 speed to full showed peaks in the 7-9A range.  The MOSFET datasheet says 32A allowed at around 5V Vgs.  Did I miss something else?
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: N-MOSFET level shift and PWM driver
« Reply #6 on: May 11, 2014, 03:57:50 pm »
Quote
Could you elaborate?

If the motor draws at least 10a, how much current can the motor draw?
================================
https://dannyelectronics.wordpress.com/
 

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
Re: N-MOSFET level shift and PWM driver
« Reply #7 on: May 11, 2014, 03:58:58 pm »
R1 being such a large value will really slow down the switching time from off to on but not sure if that explains the static current level you are reading, unless you are using PWM at some intermediate value?

I see that now.  However, in my test case should it have mattered (short 3.3v lead to GND) should be a steady state case.
 

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
Re: N-MOSFET level shift and PWM driver
« Reply #8 on: May 11, 2014, 04:01:36 pm »
Quote
Could you elaborate?

If the motor draws at least 10a, how much current can the motor draw?

Sorry, I suppose I meant at most.  Design criteria is at least 10A load.
 

Offline retrolefty

  • Super Contributor
  • ***
  • Posts: 1648
  • Country: us
  • measurement changes behavior
Re: N-MOSFET level shift and PWM driver
« Reply #9 on: May 11, 2014, 04:08:28 pm »
R1 being such a large value will really slow down the switching time from off to on but not sure if that explains the static current level you are reading, unless you are using PWM at some intermediate value?

I see that now.  However, in my test case should it have mattered (short 3.3v lead to GND) should be a steady state case.

 My guess is that 3.3 is just not enough to saturate the device. The sparkfun datasheet for the shows the maximum threshold voltage of as high as 2.5 for just some microamps of current, so 3.3 my be just not enough, plus your R3/R4 form a voltage divider so the applied gate voltage will be slightly less then 3.3, not the direction you want to go for on gate drive.

 While your in a test mode can you just increase the gate voltage some and see if your load current doesn't 'snap up' as you increase it.
 

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
Re: N-MOSFET level shift and PWM driver
« Reply #10 on: May 11, 2014, 04:14:28 pm »
While your in a test mode can you just increase the gate voltage some and see if your load current doesn't 'snap up' as you increase it.

You mean on the single MOSFET circuit? I'll have to re-tool the circuit and try driving it directly - give me a few.
 

Offline retrolefty

  • Super Contributor
  • ***
  • Posts: 1648
  • Country: us
  • measurement changes behavior
Re: N-MOSFET level shift and PWM driver
« Reply #11 on: May 11, 2014, 04:25:44 pm »
While your in a test mode can you just increase the gate voltage some and see if your load current doesn't 'snap up' as you increase it.

You mean on the single MOSFET circuit? I'll have to re-tool the circuit and try driving it directly - give me a few.

Well it would apply to either circuit where your input voltage is applied to the gate, in simple switching application it is generally desirable that the device is driven into full saturation (for bjt) or minimum Ron (for mosfet).

 

Offline madires

  • Super Contributor
  • ***
  • Posts: 8177
  • Country: de
  • A qualified hobbyist ;)
Re: N-MOSFET level shift and PWM driver
« Reply #12 on: May 11, 2014, 04:30:58 pm »
You could build a simple totem pole driver with a NPN and a PNP BJT, and use a zener (with a current limiting resistor and a buffer cap) to get around 5-10V for the driver.
 

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
Re: N-MOSFET level shift and PWM driver
« Reply #13 on: May 11, 2014, 04:52:21 pm »
You could build a simple totem pole driver with a NPN and a PNP BJT, and use a zener (with a current limiting resistor and a buffer cap) to get around 5-10V for the driver.

With the inverting level shift I feel like I'm getting the same result, is there a distinct advantage to the totem pole?  Also, I would still need to add a voltage divider somewhere since I only have the 28V rail  to play with, correct?

I'll try to re-tool the voltage divider in the original as well to correct the low amps to the gate.

Also, is it typical that the heat sink of the MOSFET is tied to any part of the device? I currently have both MOSFET on the same heat sink - would that cause an issue?
 

Offline retrolefty

  • Super Contributor
  • ***
  • Posts: 1648
  • Country: us
  • measurement changes behavior
Re: N-MOSFET level shift and PWM driver
« Reply #14 on: May 11, 2014, 05:01:22 pm »
Typically mounting tab is also drain terminal so you can't have both on same heatsink without insulating the mounting tabs from the heat sink, a good idea even if only using one. It's too easy to touch something that is ground to a big old heat sink.
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 8177
  • Country: de
  • A qualified hobbyist ;)
Re: N-MOSFET level shift and PWM driver
« Reply #15 on: May 11, 2014, 05:13:07 pm »
With the inverting level shift I feel like I'm getting the same result, is there a distinct advantage to the totem pole?  Also, I would still need to add a voltage divider somewhere since I only have the 28V rail  to play with, correct?

Your level shifter has a small problem, the MOSFET is "on" by default. It's better to have the MOSFET "off" by default, especially when driving motors.

I'd go for the zener regulated driver voltage because the 28V could break down if the motor sinks a lot of current and the PSU isn't able to deliver that. A simple voltage divider would change it's voltage too and don't forget that the MOSFET's gate is a load (see loaded voltage divider).

Quote
Also, is it typical that the heat sink of the MOSFET is tied to any part of the device? I currently have both MOSFET on the same heat sink - would that cause an issue?

Yes and yes. Therefore the best practice is to mount the MOSFETs isolated (silpad or mica, and an isolation washer for the screw).
« Last Edit: May 11, 2014, 05:18:51 pm by madires »
 

Offline dannyf

  • Super Contributor
  • ***
  • Posts: 8221
  • Country: 00
Re: N-MOSFET level shift and PWM driver
« Reply #16 on: May 11, 2014, 06:47:31 pm »
Quote
Design criteria is at least 10A load.

The device has an Rds(on) of around 40mohm. At 10a, the power dissipation during the on-state is about (10amp)^2*40mohm=4w. That means a fairly heafty heatsink and some derating.

That's not counting the switching losses. If you switch fast, that can be substantial.

Your new design has an added issue of slower turn-on -> more switching losses.

The original circuit can be made to work, you just need to know the parameters of your design to work out the numbers first.
================================
https://dannyelectronics.wordpress.com/
 

Offline sixdollarburgerTopic starter

  • Newbie
  • Posts: 8
Re: N-MOSFET level shift and PWM driver
« Reply #17 on: May 13, 2014, 12:37:27 am »
Alrighty.

I stuck with the two MOSFET design, though I am confident I could have run the single without issue with the new fixes.  I changed a few things and it seems to work fine now (now having an interment problem with overloading my power supply to start the motor from standstill to full speed).

1.) Isolated the two MOSFETs (moved the first to a different heat sink)
2.) Changed PWM carrier to 100Hz (from like 8k 'balanced') wave which significantly lowered the heating.
3.) Changed the resistors from 1/4W to 25W and dropped the ohm-age (47.0 and 30.0) to significantly add to the charge rate to the gates.

Thanks for the help, all!
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf