12V stepup regulator

Started by snorp, March 25, 2016, 04:45:43 PM

snorp

Anyone have a good suggestion for a 12V step-up regulator? I am planning to use the Moteino to control a 12V 250mA stepper motor, and it's working fine right now using a wall wart 12V supply. I want to end up using AA batteries, though, and 8 is a little much. 4xAA@6V is more reasonable and probably makes the Moteino regulator a little happier, but I need a step-up for the stepper (heh). I am considering http://www.digikey.com/product-detail/en/texas-instruments/TPS6734IP/296-3226-5-ND/370118 but wondered if anyone else had a favorite. The TPS6734IP includes a logic-level switch to control whether the regulator is enabled or not, which is nice since I use a FET for that currently.

TomWS

Quote from: snorp on March 25, 2016, 04:45:43 PM
Anyone have a good suggestion for a 12V step-up regulator? I am planning to use the Moteino to control a 12V 250mA stepper motor, and it's working fine right now using a wall wart 12V supply. I want to end up using AA batteries, though, and 8 is a little much. 4xAA@6V is more reasonable and probably makes the Moteino regulator a little happier, but I need a step-up for the stepper (heh). I am considering http://www.digikey.com/product-detail/en/texas-instruments/TPS6734IP/296-3226-5-ND/370118 but wondered if anyone else had a favorite. The TPS6734IP includes a logic-level switch to control whether the regulator is enabled or not, which is nice since I use a FET for that currently.
Since Mother Nature is such a 'b***h', if you want to get 12V 250mA out of your 3V 3000mAH AA, you will need to produce something in the order of 250mA x 12V/3V /0.8eff or 1.250A @ 3V for as long as you are stepping the motor at full power.  It will work, but not for very long.   

What duration to you need to run it and what is the interval between running it and sleeping?

Tom

perky

Any boost regulator will need to be able to handle at least 3.75W of power to get 250mA at 12V (assuming 80% efficiency), the TPS6734IP you quoted isn't really close. Those regulator datasheets with internal FETs can be misleading, often the limit current is quotes as a typical value but you need minimum values, and those tend to be significantly less than typical values. I'd suggest using TI's web based Webbench Designer to select a suitable part  e.g. LM3488, which uses an external FET. Also there can be peaks of current with any motor when starting from a stopped position (rather like a stall condition) so make sure your power supply can handle those peaks.

Mark.

snorp

Quote from: TomWS on March 26, 2016, 04:48:46 PM
Quote from: snorp on March 25, 2016, 04:45:43 PM
Anyone have a good suggestion for a 12V step-up regulator? I am planning to use the Moteino to control a 12V 250mA stepper motor, and it's working fine right now using a wall wart 12V supply. I want to end up using AA batteries, though, and 8 is a little much. 4xAA@6V is more reasonable and probably makes the Moteino regulator a little happier, but I need a step-up for the stepper (heh). I am considering http://www.digikey.com/product-detail/en/texas-instruments/TPS6734IP/296-3226-5-ND/370118 but wondered if anyone else had a favorite. The TPS6734IP includes a logic-level switch to control whether the regulator is enabled or not, which is nice since I use a FET for that currently.
Since Mother Nature is such a 'b***h', if you want to get 12V 250mA out of your 3V 3000mAH AA, you will need to produce something in the order of 250mA x 12V/3V /0.8eff or 1.250A @ 3V for as long as you are stepping the motor at full power.  It will work, but not for very long.

Ah, I wasn't really sure how to calculate what the supply current would end up being, so that's good to know. I want to use 4 AA, though, so presumably that would be 12V/6V/0.8 or 625mA. That's a little easier to stomach.

Quote
What duration to you need to run it and what is the interval between running it and sleeping?

I only need to run it for 5s twice a day, and the Moteino will be in low power listen mode otherwise. I figure I should be able to get a couple years out of the 4xAA with that kind of usage. Choosing a component for this regulator is a PITA, though. The datasheets are often not very clear about maximum load, though I guess I should take a hint when the typical load listed is like 120mA.

snorp

Quote from: perky on March 26, 2016, 06:37:35 PM
Any boost regulator will need to be able to handle at least 3.75W of power to get 250mA at 12V (assuming 80% efficiency), the TPS6734IP you quoted isn't really close. Those regulator datasheets with internal FETs can be misleading, often the limit current is quotes as a typical value but you need minimum values, and those tend to be significantly less than typical values. I'd suggest using TI's web based Webbench Designer to select a suitable part  e.g. LM3488, which uses an external FET.

Thanks. I agree the datasheets seem pretty misleading. Even the LM3488 you reference only mentions a peak current (< 10us) of 1A, and no mention of what a nominal maximum is. Frustrating. I need a through-hole package anyway.

Quote
Also there can be peaks of current with any motor when starting from a stopped position (rather like a stall condition) so make sure your power supply can handle those peaks.

Do steppers behave similarly to a traditional DC motor wrt inrush, though? My understanding was that they do not, but maybe it still makes sense to spec a regulator with some head room.

perky

#5
You're right, steppers have a resistance per phase which can be used to calculate the current. Assuming this is 250mA at 12V maybe you could use an LM2577T-12/NOPB, this is a TO-220 formed lead through-hole package but has a 3A internal switch rather than the lower 1.5A from DIL devices. There's an application circuit showing 12V out at 800mA from 5V input:

http://www.farnell.com/datasheets/1992141.pdf

Mark.


TomWS

Quote from: perky on March 27, 2016, 04:35:27 PM
You're right, steppers have a resistance per phase which can be used to calculate the current. Assuming this is 250mA at 12V maybe you could use an LM2577T-12/NOPB, this is a TO-220 formed lead through-hole package but has a 3A internal switch rather than the lower 1.5A from DIL devices. There's an application circuit showing 12V out at 800mA from 5V input:

http://www.farnell.com/datasheets/1992141.pdf

Mark.
This is a good choice except that it doesn't have an enable input.  However, if you power it from a load switch then you'll be able to completely turn it off when you're not using it.  Good suggestion perky.

What kind of stepper driver are you using?  The Allegro A4988 will drive this motor directly and comes in a wide variety of breakout boards.  With this driver the current is ramped up so that you won't have any inrush issues.  These are selling on eBay for about $1.50.

Tom



perky

Thanks Tom. With most boost regulators there's a DC path from the input through the inductor and diode to the output, so even if they have an enable pin the output can never go below a diode drop of the input voltage. It's best to use a high side load switch (i.e. a P channel FET) on its input voltage if you want to isolate the circuit from taking any current.
Mark.

TomWS

Quote from: perky on March 27, 2016, 07:19:41 PM
With most boost regulators there's a DC path from the input through the inductor and diode to the output, so even if they have an enable pin the output can never go below a diode drop of the input voltage. It's best to use a high side load switch (i.e. a P channel FET) on its input voltage if you want to isolate the circuit from taking any current.
Mark.
Mark, Good observation.  Thanks.

@snorp, a 'back of the napkin' calculation tells me that your optimum setup would be three Lithium AA batteries giving you a nominal voltage of 5.4V, Mark's Boost Circuit (which will probably give you about 70% efficiency), and your Moteino running an average current of about 60uA.  Obviously improving on anything will help.  Ex: getting better than 60uA current on your Moteino (which is fairly easy if you follow good practices, hard to do if you don't) will allow a more optimum solution with a higher voltage battery pack.  However, this mix should give you over a year and a half of battery life.

Tom

snorp

Quote from: TomWS on March 27, 2016, 06:01:33 PM
Quote from: perky on March 27, 2016, 04:35:27 PM
You're right, steppers have a resistance per phase which can be used to calculate the current. Assuming this is 250mA at 12V maybe you could use an LM2577T-12/NOPB, this is a TO-220 formed lead through-hole package but has a 3A internal switch rather than the lower 1.5A from DIL devices. There's an application circuit showing 12V out at 800mA from 5V input:

http://www.farnell.com/datasheets/1992141.pdf

Mark.
This is a good choice except that it doesn't have an enable input.  However, if you power it from a load switch then you'll be able to completely turn it off when you're not using it.  Good suggestion perky.

Yeah, and at $6.50 a piece + the cost of a FET to switch, it's kind of expensive. Will consider, though.

Quote
What kind of stepper driver are you using?  The Allegro A4988 will drive this motor directly and comes in a wide variety of breakout boards.  With this driver the current is ramped up so that you won't have any inrush issues.  These are selling on eBay for about $1.50.

I'm using one of those ultra-cheap 28BYJ that come with a board containing a ULN2003A. The ULN2003A is in a DIP socket that I can easily remove and slap into my own PCB. Since the 28BYJ is unipolar, I don't need a H-bridge or anything.

There are 5V versions of the 28BYJ, but it doesn't seem to have enough torque to do the job. There are so many variations of this motor, though, who knows what I really got. The 12V 1/64 I have works well, though, so I'm going with that.

snorp

#10
Quote from: TomWS on March 28, 2016, 06:35:54 AM

@snorp, a 'back of the napkin' calculation tells me that your optimum setup would be three Lithium AA batteries giving you a nominal voltage of 5.4V, Mark's Boost Circuit (which will probably give you about 70% efficiency), and your Moteino running an average current of about 60uA.

Hmm, Google and forum search aren't finding anything for Mark's Boost Circuit. Do you have a link? (EDIT: perky is Mark, whoops)

Right now the Moteino uses about 100uA while in listen mode (~1000ms idle with ~4ms rx, and I have a pullup enabled for a button). I could probably improve that some more. It's possible a 2ms rx may work which would let me keep the responsiveness. BTW, Tom, I've done a lot of work on RFM69_WL to expose more listen mode stuff. It chooses the closest coefficient and resolution for any listen/rx values you want. I'll send that to you at some point soon-ish.

Quote
Obviously improving on anything will help.  Ex: getting better than 60uA current on your Moteino (which is fairly easy if you follow good practices, hard to do if you don't) will allow a more optimum solution with a higher voltage battery pack.  However, this mix should give you over a year and a half of battery life.

Hmm, I'm totally off on my battery life math somehow. 3 x Energizer L91 should be 5.1V (3 * 1.7) and at least 3Ah per battery for a total of 9Ah total according to the datasheet here[0]. If we estimate 840mA for the motor (12 / 5.1 / .7 * 250), we have about 100uA to run it for 10s (10 / 86400 * 840). Add to that the 60uA for the Moteino and we're at about 160uA total average consumption, so 9000 / .16 = 56250 hours or 6.4 years! That's...slightly different than your estimate of 1.5 years. What did I do wrong?

If I do find some way to use 8xAA to get 12V to both the motor and Moteino, do you see any major problems with that? Obviously the motor is happy, but driving the Moteino at 12V? The datasheet says it should be fine, but Felix has warned before that anything above 9V will generate some heat. How much heat exactly, and how much energy is wasted? I am not having a good time with the MCP1703 data sheet there. I think it will need to dissipate ~500mW which seems like a lot...

Thanks Tom and perky for your help, I really appreciate it.

(0) http://data.energizer.com/PDFs/l91.pdf

perky

OK, another (significantly cheaper) suggestion, the MC33063APE4 which has a quoted max switch current of 1.5A. This is probably still too low to get 250mA out at 12V though, so it can be boosted with a cheap NPN transistor.

http://www.farnell.com/datasheets/1974516.pdf

Mark.

snorp

Quote from: perky on March 28, 2016, 11:47:14 AM
OK, another (significantly cheaper) suggestion, the MC33063APE4 which has a quoted max switch current of 1.5A. This is probably still too low to get 250mA out at 12V though, so it can be boosted with a cheap NPN transistor.

http://www.farnell.com/datasheets/1974516.pdf

That does look significantly cheaper. I'm confused about why 1.5A switching isn't enough, though, if Vin is ~6V (4xAA). Even at 70% efficiency (might be a little worse than that with this regulator?) that's only 715mA. Sorry if I'm being thick, just trying to better understand how to spec something like this.

perky

#13
Let's say for arguments sake you were converting 6V to 12V and you need 250mA output current. This means the inductor will be ramping up from 0 to Ipeak for the first half of a cycle, then ramping down from Ipeak back to 0 for the second half as it dumps it's current to the output. Note that the inductor only supplies current to the output for the second half of the cycle, that's important later.

Now the average current from the source, multiplied by the source voltage, is the power. If we assume 100% efficiency that's the same as the output power. The input current has to be double the output current in this example, so the average input current has to be 500mA. That's the average across the whole cycle.

The current waveform in the first half of the cycle looks like a saw tooth, it ramps up linearly from zero to Ipeak. The average of this is Ipeak/2. Similarly the output current ramps down from Ipeak to 0. The average of this is also Ipeak/2 , but since the inductor only provides current to the output in the second half of the cycle the Ipeak actually has to be *four* times our average output current, in our case that's 1A. This also works with the input as this supplies current over the whole cycle, and it's average is Ipeak/2 which is 500mA.

So on the face of it we should in theory get satisfaction with this. Efficiencies and component tolerances will eat into this, and you'll need some design margin, but I've changed my mind - this is probably going to be OK without an external NPN transistor.

Edit: Just to confirm that thinking, look at section 9.2.2.2 on page 14 of the MC33063 datasheet where you'll find some equations for a step up regulator. The ratio of ramp up to ramp down is ton/toff, and assuming Vin(min)=6, Vf=0 and Vsat=0 this gives 1:1. The equation for Ipk(switch) is 2*Iout(max)*((ton/toff)+1), i.e. 4*Iout.

damonb

Quote from: snorp on March 28, 2016, 11:39:07 AM
Hmm, I'm totally off on my battery life math somehow. 3 x Energizer L91 should be 5.1V (3 * 1.7) and at least 3Ah per battery for a total of 9Ah total according to the datasheet here[0]. If we estimate 840mA for the motor (12 / 5.1 / .7 * 250), we have about 100uA to run it for 10s (10 / 86400 * 840). Add to that the 60uA for the Moteino and we're at about 160uA total average consumption, so 9000 / .16 = 56250 hours or 6.4 years! That's...slightly different than your estimate of 1.5 years. What did I do wrong?

If your batteries are in series to add voltage, you don't get to add their charge (Ah) as well. You can have your 5.1V @ 3Ah, or in theory 9Ah @ 1.7V (parallel - not recommended), but not both.