Discreet startup delay? - Page 1
Forum section: electronics / beginners

author: FlimFlam89
author_rank: Newbie
timestamp: November 21, 2018, 09:09:26 am
content: Hi!I need to make a delay for a project of mine. The delay has to keep a microcontroller disconnected at startup and after 2s it will make the power go through the micro controller. I’ve tried using a PNP but I don’t know how to make the delay...Could anybody enlighten me?

author: The March Hare
author_rank: Contributor
timestamp: November 21, 2018, 01:42:30 pm
content: First though would be why can't the micro be powered as opposed to simply delaying it's intended function with code?Simple R/C delay might work for you (for example, charge a cap connected to a reset pin through a resistor .. though at the threshold voltage of the pin, depending on the pin, sometimes hairy results can happen, possibly requiring a Schmitt solution). The good old 555 can be implemented as well. A jelly bean comarator and two resistors. There are literally hundreds of ways to do this, the solution usually a matter of what's on your bench, board real estate, power requirements, and dollars (The latter, there are two lead thermal delays available - but they're somewhat exotic and expensive).Jimbo.

author: FlimFlam89
author_rank: Newbie
timestamp: November 21, 2018, 03:05:39 pm
content: The thing is that this is all connected to a 4-20mA current loop and the instrument will not work unless it can start up on its own without having the micro attached. Once it’s booted up it can run without a problem regardless if a micro is in line with it.Since this is a current loop I want to drag as little power as possible, this is a school project/ one off so cost isn’t an issue but id like to keep it "jelly bean"!

author: The March Hare
author_rank: Contributor
timestamp: November 21, 2018, 09:01:10 pm
content: How many lines on your data loop? And I assume the micro has it's own supply? If you don't mind moving parts you could put a small relay in series with your data line and use one of the micro outputs to hold it open until your delay is satisfied via code - if you happen to have a low powered reed on hand could be a one component solution.Not really certain what you're up to but keep in mind you're not going to want a chip unpowered with data on I/O pins. Your micro won't tri-state?Otherwise, if it's a matter of just holding an interrupt I'd probably either charge a capacitor through a resistor on the front of whatever comparator you have at hand configured as a Schmitt trigger - 5 components total I think - or a stand alone 555 which may or may not then need a signal transistor to satisfy the interrupt logic.

author: MiDi
author_rank: Frequent Contributor
timestamp: November 21, 2018, 10:07:22 pm
content: If little power is of concern and it does not matter if it is delayed 2s or 5s, a p-channel mosfet in 12V line could fit.The threshold voltage of particular mosfet is starting point for calculation of RC network rise time.The maximum resistance should not exceed 1Mohm, depending on particular gate and capacitor leakage current.Now you can calculate the capacitor out of the results.The threshold is temperature dependent, so calculate for worst case high temperature of mosfet and capacitor.The formula to calculate (you have to solve it to RxC):Where:Vc is the voltage across the capacitor = threshold of mosfetVs is the supply voltage = 12Vt is the elapsed time since the application of the supply voltage >= 2sRC is the time constant of the RC charging circuitsourceThere is a problem with this circuit when turning off the powersupply, but there is a simple solution

author: spec
author_rank: Frequent Contributor
timestamp: November 22, 2018, 07:06:55 pm
content: Hi FlimFlam89,How do you want to do this: transistors, resistors, capacitor diode. logic chip, resistor capacitor diode opamp/comparator resistors, capacitor, diodeBy the way, #2 is the best

author: rhb
author_rank: Super Contributor
timestamp: November 23, 2018, 01:10:21 am
content: Don't beat your head against a wall. Use a 555 and move on to the next problem.

author: spec
author_rank: Frequent Contributor
timestamp: November 23, 2018, 06:42:08 am
content: Quote from: rhb on November 23, 2018, 01:10:21 amCould you post a schematic. I have never been able to get a satisfactory startup delay circuit with a 555.

author: Zero999
author_rank: Super Contributor
timestamp: November 23, 2018, 11:20:27 am
content: Quote from: spec on November 23, 2018, 06:42:08 amPost a schematic of what you've already tried and we might be able to suggest where you've gone wrong.Going back a bit:Quote from: FlimFlam89 on November 21, 2018, 03:05:39 pmDo you know why?Perhaps that should be fixed, rather than adding a separate timer circuit.

author: spec
author_rank: Frequent Contributor
timestamp: November 24, 2018, 12:57:40 am
content: Quote from: Hero999 on November 23, 2018, 11:20:27 amI have already asked rhb for a satisfactory 555 circuit, so I cannot see the purpose of your rather patronizing statement. If you posted a satisfactory circuit that would be a much more constructive way to illustrate where I have gone wrong.

author: KL27x
author_rank: Super Contributor
timestamp: November 24, 2018, 02:44:08 am
content: What kind of micro is it?I'd maybe ponder letting the micro boot up, first, with a low speed internal oscillator and all I/O configured to draw next to nothing... Then have the micro switch the power to the other thing with a transistor. Then go about business. Maybe simply by letting the micro boot first by a millisecond or 10 might solve your problem without jumping thru any additional hoops? (I.e., maybe it's the initial "capacitance" draw of the micro when power is switched on that is causing the other chip to not power up successfully, rather than the quiescent current draw; e.g., try letting them take turns, micro first.) I'm sure you know it, already, but the ramp up of voltage has to be stiff enough and stable enough to get the oscillator in your other IC started... and the micro and it turning on at the same time can cause problems... which your micro would seemingly be handling better (most modern micros have some built in power-good hold/reset circuitry).For 555, google 555 + one shot and you will find schematics. The 555 comes in CMOS variant with a lower quiescent current than the originals. But honestly, it's dumb for this, because this doesn't need to be very precise. I'd use the LC circuit to bias a FET. Just reading the datasheet and wiring up the 555 and external components (whether by hand or in CAD) would take more time that it's worth. And it will have a startup draw of some magnitude, itself, on top of that quiescent draw. Maybe it is just as bad as the microcontroller.

author: spec
author_rank: Frequent Contributor
timestamp: November 24, 2018, 08:07:43 am
content: Quote from: KL27x on November 24, 2018, 02:44:08 amThose are exactly the unsatisfactory 555 delay circuits I was talking about. The 555 is a great chip, but it has a couple of missing features that make it unsuitable for quite a few applications. That is why I would like to see the schematic.I think for pretty much any question you could reply with, "search the internet""dumb" is a sweeping statement and meaningless"start-up draw" ?"Quiescent current" ?

author: Zero999
author_rank: Super Contributor
timestamp: November 24, 2018, 07:59:53 pm
content: Quote from: spec on November 24, 2018, 12:57:40 amI apologise. I thought I was responding to the original poster. I didn't read it properly. I thought he'd already tried a 555 circuit and was having problems with it, but wouldn't post the schematic.Yes, a 555 circuit is one way to achieve a delayed power on, but I think it's a hack. I believe this relates to a different project with lots of things connected together and a current surge or grounding problem is most likely to blame.https://www.eevblog.com/forum/beginners/4-20ma-loop-powered-application/msg1961933/#msg1961933

author: spec
author_rank: Frequent Contributor
timestamp: November 25, 2018, 05:43:24 am
content: Thanks for the reply H99.I have tried many times to make a decent delay timer from a 555, but the only way to get the function is to use a differentiating capacitor from the supply line, and that is a complete no no for obvious reasons.I recon the simplest approach is to use an 74HC14 hex Schmidt, capacitor, resistor, and diode.First person to post the schematic gets the cigar.

author: Zero999
author_rank: Super Contributor
timestamp: November 25, 2018, 09:20:11 pm
content: Why not simply configure the 555 timer as a Schmitt trigger?

author: spec
author_rank: Frequent Contributor
timestamp: November 26, 2018, 06:40:53 am
content: Quote from: Hero999 on November 25, 2018, 09:20:11 pmNice version, The integrating capacitor referenced to 0V is the way.But the circuit uses nine components (including the mandatory 555 decoupling capacitor across the supply line).By the way, as you no doubt know, the CMOS 555 would probably be better: no transition supply-line current glitches and very low quiescent current. Also a smaller capacitor and bigger charging resistor can be used.I am not a big fan of using electrolytic capacitors for timing, except possibly tantalum, because they are lifed and have a relatively large leakage current. Much better to use a film capacitor.To be a real smart-arse, I would suggest that a low leakage schottky diode could be used to improve the capacitor discharge at turn off.The BJT will give a comparatively large voltage drop (CEsat). A MOSFET would fix that issue.There is also an indeterminate state as the power line ramps up: Q1 base may be at 0V, which will turn the PNP transistor on momentarily before the 555 sorts itself out. This is being picky of course, but it is the kind of thing that can cause odd effects.And in safety-critical applications, it would not get past the first post because of the transistors dependency on the supply line to be off (the safe condition). In general for SC, the only dependency you can have is 0V (the no power condition).As you may have guessed, I have had many problems with power on reset (POR) and delay power on (DPO) circuits.In one instance a quite complex equipment with all sorts of fancy circuits got through the tests, except for a silly little DPO function which nobody thought twice about.Having said all that, your circuit is well thought out (and drawn) and would be quite suitable for most home electronic projects. The parts are dirt cheap too.

author: Zero999
author_rank: Super Contributor
timestamp: November 26, 2018, 09:22:28 am
content: I agree a Schmitt trigger IC such as the 74HC14 or 74HC1G14 to save space and a MOSFET would be a better option. It would probably be cheaper too. The downsides of the Schmitt trigger IC, compared to the 555 are the threshold voltages aren't so tightly controlled and it's only rated to work off up to 6V.Yes the dv/dt of the power supply is important for any of these simple circuits to work properly. It's also why I didn't include a supply decoupling capacitor, as I'm not convinced it would do much to help and could be a hindrance, as much as anything. I wouldn't use any of these circuits in a safety critical application: I'd buy a safety relay with a timer function.

author: spec
author_rank: Frequent Contributor
timestamp: November 27, 2018, 05:38:35 am
content: Nice

author: spec
author_rank: Frequent Contributor
timestamp: November 27, 2018, 01:16:22 pm
content: UPDATE (2018_11_28): This schematic is now obsolete: see reply #23 for revised schematicBelow is my latest attempt:There are no transitions on the output during start-up and there are no dependencies on anything other than 0V... at least that is the intention.All components are elementary and can be simply analyzed and simulated.Quiescent current consumption is around 20uA with a 5V input supply.Turn on is held off until the input supply has reached at least 3.1V which is probably a good compromise for a 5V input supply, but the hold off voltage could be adjusted to suit other input supply voltages by changing D3 accordingly.

author: MiDi
author_rank: Frequent Contributor
timestamp: November 28, 2018, 11:30:13 am
content: Quote from: spec on November 27, 2018, 01:16:22 pmI suggest that this would not work properly, the leakage of Q1ce could lead to uncontrolled turn on of mosfet.A <=1M resistor from Q1c to Vi+ would fix this.For improved stability I would add some couple of nF between Q3gs.

author: spec
author_rank: Frequent Contributor
timestamp: November 28, 2018, 12:59:36 pm
content: Quote from: MiDi on November 28, 2018, 11:30:13 amThank you for your observations- very helpfulI agree with the reason for the 1M resistor between Q2eb, and it is also good design practice.But can't understand adding a capacitor Q3gs, because there is already a relatively large parasitic capacitor there by virtue of the PMOSFETs characteristics. Also, it is quite important to turn the PMOSFET on as fast as possible to keep it in the linear region for as short a time as possible.In fact, I am not altogether happy with the rather long turn-on time constant at the gate of Q3 in the version of the circuit for over 7V supply operation.Decoupling capacitors etc are not shown so this is not a production circuit, but it is hopefully not far off.By the way, there is a cigar for anyone who can find a PMOSFET to replace the PMOSFET shown with a VGSmax of 20V or greater, still with a VGth of 1V or less.And there is a box of cigars for anyone who can find a PMOSFET with the following characteristics:IDmax: 10A or moreRDss at 3VGS: 5mR or lessVDSmax: 30V or moreVGS: 30V or more (not essential)Anyone had any experience of these new Nitride MOSFETs?

author: Zero999
author_rank: Super Contributor
timestamp: November 28, 2018, 01:22:38 pm
content: Using a zener means the delay will be dependant on the supply voltage, which may or may not be an issue.Why not replace D3, R4, Q1 and Q2 with the TL431 and add a resistor between the output and C1, to provide the snap-on action and prevent oscillation?

author: spec
author_rank: Frequent Contributor
timestamp: November 28, 2018, 02:23:47 pm
content: Quote from: Hero999 on November 28, 2018, 01:22:38 pmThat's true of most POD circuits I have seen posted. The solution would be to fit a constant current generator. Most POD circuits are configured to suit the supply line voltage to be used and that is the intention here. But in general, I would prefer comments that are peculiar to this circuit, rather than wade through POD design in general.Quote from: Hero999 on November 28, 2018, 01:22:38 pmThe OP asked for a discrete POD circuit, and, anyway, a complementary transistor bi stable snaps on very fast. Nonetheless, using a T431 is an interesting idea. I have looked at the TL431 before, but the circuit would be less deterministic then. The TL431's relatively large input bias current is also an embarrassment Not sure if the TL431 approach would satisfy the 0V only dependency either. Would the TL431 still have a max 20uA Iq? Never mention oscillations and TL431 in the same sentence: the damn things oscillate for a pass time.All the same, why don't you do a TL431 POD circuit so I can have a rest and admire your work.By the way, I thought your idea of using a relay-based POD circuit for safety-critical applications was excellent- I made a note of that.

author: spec
author_rank: Frequent Contributor
timestamp: November 28, 2018, 02:37:05 pm
content: Attached is the POD#4 (issue 03) schematic incorporating MiDi's 1M resistor modification

author: MiDi
author_rank: Frequent Contributor
timestamp: November 28, 2018, 09:42:08 pm
content: Quote from: spec on November 28, 2018, 12:59:36 pmCapacitor between Q3gs improves dv/dt rating and slows down switching (better emi), think it is not really a concern in this application, but with this high impedance at the gate, me would feel better.Slow switching would be a problem if you get out of the soa, NDP6020P is capable of DC operation with at least 1A@Vdsmax with appropriate heatsinkVGSmax of 20V or greater, still with a VGth of 1V or less - would claim it near impossible.Maybe there are exots, but even then you would not pay the price for this application.There is nothing bad on clamping a logic level mosfet, protection is always good idea.If "a pmosfet" includes paralleling of devices, then I now own a box of cigarsYou mean GaN Mosfets? Think they are used for low voltage high power rf applications.

author: spec
author_rank: Frequent Contributor
timestamp: November 29, 2018, 12:42:23 am
content: Quote from: MiDi on November 28, 2018, 09:42:08 pmThere is already a fair amount of capacitance at the gate as stated.Quote from: MiDi on November 28, 2018, 09:42:08 pmYou're raising a flag and saluting it. The main reason for a fast switch-on is to get the PMOSFET through the linear region fast to avoid potential oscillations: nothing to do with SOA or TJmax. With an application like this you have no idea what will be connected to the drain of the PMOSFET- could be inductive, capacitive, negative resistance or a combination of all of these and others.Quote from: MiDi on November 28, 2018, 09:42:08 pmNot very helpful and a sweeping statementThe Vishay Si8497db is almost there with a 30VDSmax and a 1.1VGT. I feel sure that a compliant PMOSFET can be found.Quote from: MiDi on November 28, 2018, 09:42:08 pmWho said there was anything bad per se- you are missing the point that the clamping method uses two extra components and puts the gate negative drive impedance up radically. It also increases the quiescent current. You must look at the complete design before making judgements and giving advice.Quote from: MiDi on November 28, 2018, 09:42:08 pmIf you are saying that you can do the job with two PMOSFETS you would only get half a box of cigars, but you would have to at least name the devices.Quote from: MiDi on November 28, 2018, 09:42:08 pmI know for a fact that that they are used in normal applications. I asked if anyone had any experience of using them.By the way, and I mean this genuinely, why don't you have a go at designing a POD circuit- the more the merrier.

author: MiDi
author_rank: Frequent Contributor
timestamp: November 29, 2018, 09:08:56 am
content: My apologies that the response does not satisfy your expectations, but for several reasons I do not want to dive deeper into it.Indeed I designed, built and tested PODs many years ago, but it seems my knowledge and experience has gone by to many format c: parties...To be honest, I feel an undertone in your posts, which does not motivate me.

author: spec
author_rank: Frequent Contributor
timestamp: November 29, 2018, 11:51:55 am
content: Quote from: MiDi on November 29, 2018, 09:08:56 amPlease do not take anything personally- just focus on the technical side. Didn't you like my first post to you?

author: Zero999
author_rank: Super Contributor
timestamp: November 29, 2018, 03:27:56 pm
content: Here's the TL431 circuit. It will not work very well if the load resistance is high, but there are ways round that.

author: MiDi
author_rank: Frequent Contributor
timestamp: November 30, 2018, 06:32:16 am
content: I am wondering how this magic circuit works without having the minimum cathode current on TL431.Could you enlighten me, please?

author: Zero999
author_rank: Super Contributor
timestamp: November 30, 2018, 09:58:47 am
content: Quote from: MiDi on November 30, 2018, 06:32:16 amIt doesn't. I put R4 in the wrong place. It should go between the gate and source.

author: MiDi
author_rank: Frequent Contributor
timestamp: November 30, 2018, 10:46:20 am
content: There are special TL431 with much lower minimum cathode current, could worth a look at

author: MiDi
author_rank: Frequent Contributor
timestamp: December 01, 2018, 08:23:14 am
content: E.g.TI has an advanced tl431with minimum cathode current of 35uA.