# High-Frequency PWM-Driven Motor Driver Via "Switch" ...?

#### jeffchrisope

Joined Jul 29, 2017
6
Howdy AAC! My virgin post. Be easy on me.
I'm taking a semiconductors class that has spent a lot of time on the underlying physics around semiconductors in general, and diodes and MOSFETs in particular. As a final project, we have the assignment to create a brushed DC motor driving circuit, with the following specs:

We build an oscillator (using 555 is fine) to generate a sawtooth, which feeds into the ...
• PWM modulator, using a voltage comparator, to generate a spec'd 0-5V PWM signal at 10kHz frequency
• A "switch" then should be implemented to make that PWM vary the speed of our wee DC motors, from at least 10%-90% duty cycle, and preferably 2%-98%
• DC brushed motor is 8-15V motor, draws 100mA with no-load (and indeed, there won't be any loads for this assignment). Driven off of pure DC from our power supplies yields an active range all the way down to 0.5V, however.
• The main portion of the grade is on whether the thing works, but "works" includes the full PWM range actually working properly, AND power efficiency being relatively decent (don't have the switch consuming an additional 5W, for instance). We also have to produce a "cost" of our switch, but frankly, this matters less to me if everything else works really well.

My task is the "switch" portion of this, so I immediately thought "hey, use a MOSFET, since that's what we're learning about" ... and thus did I find out why most folks use dedicated MOSFET-driver chips, especially once the frequencies get "high" - and no, we can't use such a chip in this assignment.

So, my initial attempt was simply trying various MOSFET models with an appropriate PWM piped in from a signal generator. Models included BS-170 and 2N7000 jelly beans, an MTP3055 power MOSFET, as well as a "logic level" RFP30N06LE power MOSFET. In all cases, when the PWM signal was applied directly to the gate of the MOSFETs, the issue we'd have was a) top speed was considerably lower than "true" 100% voltage at 100% duty cycle (we were using 12V for Vmtr), but much worse, b) the motor would stall out and die at *35%* duty cycle, as if it were only "seeing" 0.5V effective input. Oddly, this 35% fall-off point didn't change much across the different MOSFETs.

So ... I did some (actually, lots of) reading and have learned a lot about various aspects of the gotchas here. My main theory became that the gate wasn't getting turned "on all the way" - we were kicking around in the triode/linear region, and burning off a lot of power (and yes, the MOSFETs generally getting quite hot). The two possible issues that seemed possible were a) insufficient current to completely activate the MOS capacitance in the MOSFET gate, and b) Vgs not set right to ever turn on.

Therefore, I conducted an experiment: for each MOSFET, use the same setup, but try varying either the PWM frequency, or the PWM max voltage (again, using the signal generator for this). What did I find? Going from 10kHz PWM to 1kHz PWM frequency brought the motor die-off point from 35% to 12% duty, and going to a whopping 100Hz for the PWM frequency yielded a PWM duty cycle floor of 2%. Great! The PWM voltage tests, on the other hand - where I boosted Vgs up closer to 10V (except on the logic-level FET) yielded NO change in the duty cycle floor - it stayed at 35% or so.

Next, I found a number of sources on the web that deal with parts of this problem, of course, but unfortunately, many solutions I found collapse fairly quickly to "and this is why we use MOSFET driver chips". I did, however, find Syed Tahmid's excellent blog post on low-side MOSFET drivers, and after studying the schematics so I thought I knew what was going on, we went with "Fig. 4":

I started with big 10k's for R28/R29, and used simple S8050/8550's for the BJTs. After a few false starts where I learned that I don't pay enough attention to what the heck I'm doing when breadboarding, resulting in the sad deaths of several BJTs, I got the circuit working properly ...

... except: the motor died off around the 35% duty cycle mark. &*^^^&***((%\$###!!!

I have a few operating theories on issues. R28/R29 are awfully large, but dropping them to 5k didn't seem to help, but I wasn't confident in the change and it might have been when I was still cleaning up my previous mis-connection mess(es). I know from some Multisim runs that dropping R28/29 TOO low yields badness, both transistors end up being on at the same time, which yields sadness ... but I'm not clear on what my true range is here, knowing that I need to achieve 10kHz gate open/close rates.

Hence, this post to all you knowledgeable folks: any ideas on what to do now? Am I missing something incredibly basic here? Is there a true "single component" option (a perfectly selected MOSFET or ???) that would actually fulfill most of the requirements, and we're just making this complicated? Or am I barking up the right tree but the components I've used just aren't right yet?

So sorry for the length of this thing, but I wanted to get all the info out there initially so folks inclined to help don't have to ask me a bunch of follow-on questions just to figure out what the heck I'm trying to do.

Thanks in advance for any help!!!!!!
Jeff

#### bertus

Joined Apr 5, 2008
20,756
Hello,

What are the voltages for V_DRIVE and V_LOAD?
Do you use a back-EMF diode accross the motor?

Bertus

#### jeffchrisope

Joined Jul 29, 2017
6
Sorry, yes ... V_DRIVE varies depending on which FET I have in place, but it's usually about 10V. V_LOAD is splat in the middle of the motor range, 12V. And nope, I don't have any diode across the motor at the moment. Is the back-EMF diode different than a "flyback" or "snubber" diode, or are they the same things?

#### Alec_t

Joined Sep 17, 2013
11,641
Welcome to AAC!
A nicely explained first post.
The back-emf/flyback/snubber diodes are indeed the same thing here.
Are you obliged by the terms of the project to use a 10kHz PWM frequency?

#### jeffchrisope

Joined Jul 29, 2017
6
Sadly, yep - 10kHz is one of the few hard-n-fast spec requirements, which is slightly odd IMHO as we don't get to talking about the time-dependent parts of MOSFET behavior, or BJT's in their entirety, until the next course in the sequence. Sigh.

#### Alec_t

Joined Sep 17, 2013
11,641
If your motor draws 100mA at no-load speed it will draw a much higher current at low speed (e.g. during start-up) because its back-emf will be lower. It may be that the motor inductance is preventing the current from building up to the required level for slow running when a 10kHz PWM frequency is used.

#### ebeowulf17

Joined Aug 12, 2014
3,274
And nope, I don't have any diode across the motor at the moment. Is the back-EMF diode different than a "flyback" or "snubber" diode, or are they the same things?
Way out of my league here as far as true understanding of back-EMF behavior or high speed MOSFET characteristics, but if I were you, I'd add the appropriate diode before doing anything else. At a minimum it'll help protect your MOSFET, and it *might* also have an impact on your duty cycle issues, although I don't know about that second part.

#### ebeowulf17

Joined Aug 12, 2014
3,274
Another option that might be worth considering is a Darlington transistor. Since there's no (or at least negligible) capacitance at the input, I believe there's less time spent in the linear region during switching transitions and more time fully saturated on or off. The obvious disadvantage is the larger voltage drop, representing heat dissipation and inefficiency. I have no idea how that wasted energy compares to the energy lost in potentially slower MOSFET switching times. My guess is that MOSFETs are the default choice in these situations for good reasons and that you'll be better off sticking with them, but I thought it was worth raising the question.

FWIW, I'm in the midst of a big PWM solenoid driver project and Darlingtons have been working great in my particular application.

#### crutschow

Joined Mar 14, 2008
25,416
Try interchanging Q11 and Q12 to make them emitter followers (connected emitter to emitter).
Their low output impedance will give better drive for the MOSFET gate capacitance.
With that you don't need (or want) R28 and R29.

And be sure to add a diode across the motor (cathode to plus side) as it's necessary for proper PWM operation.
Not only does it protect the MOSFET from inductive spikes, it provides a path for the motor current when the PWM signal is off, and likely will help your PWM duty-cycle problem.

#### jeffchrisope

Joined Jul 29, 2017
6
Try interchanging Q11 and Q12 to make them emitter followers (connected emitter to emitter).
Their low output impedance will give better drive for the MOSFET gate capacitance.
With that you don't need (or want) R28 and R29.

And be sure to add a diode across the motor (cathode to plus side) as it's necessary for proper PWM operation.
Not only does it protect the MOSFET from inductive spikes, it provides a path for the motor current when the PWM signal is off, and likely will help your PWM duty-cycle problem.
Okay, I'll definitely give a shot at adding some fast diode before doing anything else. I don't quite understand how the BJT would work in that interchanged config, lemme ponder that one a bit.

I did use my new Peak LCR45 to give a read on the motor - 1.7mH and impedance at 15kHz (presumably by just calculating it internally in the tester, I doubt it is actually generating that signal ... but could be pleasantly surprised) of 75 + j185 ohms ... which seems kinda high, to be honest, but I don't really have much to compare it to. I WILL give a go at swapping out the motor with another couple tests at the lab tomorrow and see if I somehow have a bum one.

Thanks for the suggestions, folks! I'll let you know how those changes/tests work!

#### crutschow

Joined Mar 14, 2008
25,416
Okay, I'll definitely give a shot at adding some fast diode before doing anything else. I don't quite understand how the BJT would work in that interchanged config, lemme ponder that one a bit.
Schottky diodes are good for that purpose as they are fast and have a low forward drop to maximize efficiency.

Here's the driver configuration I was referring to:
Q1 and Q2 are acting as emitter followers to rapidly charge and discharge the MOSFET gate capacitance.

#### jeffchrisope

Joined Jul 29, 2017
6
Here's the driver configuration I was referring to:
Q1 and Q2 are acting as emitter followers to rapidly charge and discharge the MOSFET gate capacitance.

View attachment 131960
And here my BJT understanding - or lack thereof - shows through. I don't really see how this suggestion differs from what I have, other than the output is inverted now from the input (which is fine in and of itself). I'll throw it in Multisim and see if I can wrap my head around it.

#### crutschow

Joined Mar 14, 2008
25,416
And here my BJT understanding - or lack thereof - shows through. I don't really see how this suggestion differs from what I have
The emitter follower has a much lower output impedance, which more rapidly charges and discharges the MOSFET capacitance.

#### GopherT

Joined Nov 23, 2012
8,012
And here my BJT understanding - or lack thereof - shows through. I don't really see how this suggestion differs from what I have, other than the output is inverted now from the input (which is fine in and of itself). I'll throw it in Multisim and see if I can wrap my head around it.
Think about what happens during each high/low transistion in your current circuit. You said it yourself in post #1...

...both transistors end up being on at the same time, which yields sadness ..
There is no way to avoid it by simply changing resistor values in your circuit. Every Transition yields shootthrough.

The real way to avoid it, and avoid it like a boss, is to use @crutschow 's advice and swap the non/pnp in your push/pull modest driver.

Also, get rid of R27, it is not doing anything valuable if your input is a 555 timer.

In fact, use the mosfet driver circuit suggested by crutschow in post 11 - your base resistors are too high and can be eliminated. By using the post 11 design.

#### jeffchrisope

Joined Jul 29, 2017
6
Okay, well, I wanted to circle back with y'all, after all the great advice, and let you know where we ended up.

Main lesson for me: always cover the basics before getting (or theorizing about getting) fancy. The bulk of the improvement we achieved was by simply adding the flyback diode. Not any diode, of course - some of the slow ones we had sitting around only dug 4-5% into the 35% duty cycle floor we were seeing. But then we stuffed a 5819 Schottky in and voila, now our new duty cycle floor was about 6%! This was well within the specs for the assignment, so my team ended up going with this simple setup - no low-side driver circuit of any kind, just the PWM coming off of the pull-up out of the voltage comparator generating our waveform, a flyback diode, and a 2N7000. So, initial mission accomplished - thanks to suggestions from folks here!!! Thanks so much.

I did want to see how much further down towards 1% duty cycle we could go, however, so I ended up setting up the emitter follower design and played with it. It indeed did knock off maybe 2% from the floor, bringing us to 4%, but no amount of fussing around beyond that lowered it further. Also, for some reason, my nice new lovely signal generator does some obnoxious stuff when you change the duty cycle while the output is active - it goes to 100% in long pulses for a while, so as I played around near the motor's cutoff point it kept surging, then almost stopping, over and over ... until suddenly it stuck on full throttle with the wild abandon of a torched transistor somewhere. Sure enough, the 2N7000 wasn't amused apparently and is now a diode with decorative third terminal.

So all in all, a very educational experience! Thanks so much for the help, folks!!

#### crutschow

Joined Mar 14, 2008
25,416
A 2N7000 has a high on-resistance of about 6 ohms.
You might want to use one with a lower resistance.