can I drive a 3.3V voltage regulator from a picaxe pin?

srnet

Senior Member
I dont see why not.

But why do it anyway, there are quite a few regulators out there that have a shutdown pin already .........
 

geoff07

Senior Member
If your current draw is less than 20mA and you use the right reg, then why the transistors? And as srnet says, you can simply control a reg from the Picaxe even if the draw is too high so it has to be connected to Vcc. Take a look at LP2985 and similar devices.
 

Dicky Mint

Senior Member
Well firstly I've designed the rest of the circuit to be leaded technology and the LP2985 is an SMD style device
Although this doesn't exclude the use of the SMD reg, I'd prefer to use leaded parts.
I've also got a couple of leaded 100mA 3.3V voltage regulators on order
I'm looking at a ball-park figure of 50mA so out of range of the PICAXE pin
Thanks for your input
 

nekomatic

Member
In US stock at Farnell... 44p for the chip, £16 for delivery!

I can't see anything wrong with the two-transistor circuit, but is there any reason you need the NPN - why not just have the PICAXE pin driving the PNP, and set the pin low to turn the load on?
 

AllyCat

Senior Member
Hi,

A Programmable voltage version seems to be about 64p each (inc VAT) from CPC (Farnell) with free shipping for internet orders over £5.

But yes, if the PICaxe is also powered from the "+5V" rail, then I'd just use a single PNP transistor. However, IMHO 10k for "R2" is a little high, I'd use around 2k2 to properly saturate a BC558 at 50 mA.

Cheers, Alan.
 

womai

Senior Member
I'm looking at a ball-park figure of 50mA so out of range of the PICAXE pin
The Picaxe outputs use FETs so you should be able to parallel them without ill effects. Each pin can drive ~20mA, so three of them driving the regulator would suffice. (Total current out of all Picaxe pins may not exceed ~100mA however!). That way the Picaxe could supply the regulator directly. No need for transistors etc.

What is the dropout voltage of your regulator? In your proposed circuit it would have to be an LDO because there isn't a whole of room left: 5V - 3.3V = 1.7V, and from that the transistor will eat up yet a another portion.
 

womai

Senior Member
In a perfect world, with no possibility of program error, I would agree.
I don't think this is the most difficult task imaginable ;) And of course you would test it with open outputs before hooking up the regulator and attempting to draw maximum current.

Something along the lines of

let pins = outpins or 0b00000111 (to turn them on)

and

let pins = outpins and 0b11111000 (to turn them off)

will do. (Have to admit I haven't looked up the exact syntax and it has been a while since I last used a Picaxe). That will ensure the three pins switch simultaneously (in my experience, within a fraction of a nanosecond to each other).

Of course one can build something complicated with a lot of bells and whistles and all kinds of fail-proof features, but it seems to me Dicky Mint is after something as simple and small as possible.
 

AllyCat

Senior Member
Hi,

The OP hasn't said which PICaxe he's planning to use, nor if there are any spare pins. But personally, I'd Keep It Simple and Safe with a single PNP transistor. That should drop no more than a few hundred mV (hFE = 20). But we also haven't been told the LDO type, nor if the "5 V" rail is regulated, or just a typical "3 x AAs" PICaxe supply.

Two issues worry me about parallelling PICaxe pins. First, bear in mind that the M2s "remap" their port pins, so the PICaxe "virtual" Port B (and C) actually uses the base PIC Ports A and C (and maybe B as well), so they may not switch at exactly the same time. Not that I'd expect it to damage the chip, but it might cause an unexpected reset.

The second factor depends on how pessimistic you consider the Microchip specifications to be. The base data sheet (for the 14/20M2s) only "guarantees" a pull-up current of 3.5 mA with a 700 mV drop (from a 5 volt Vdd rail). That would need a lot of output pins for 50 mA !

Cheers, Alan.
 

srnet

Senior Member
But personally, I'd Keep It Simple and Safe with a single PNP transistor.
Yep, the only sensible way to go.

The OP did not say what the absolute maxiumum current the regulator had to provide was, only gave a 'ball park' figure of 50mA, so could be less, could be a (lot) more.

So, yes, KISS.
 
Top