DIY PSU part 2 - Page 1
Forum section: electronics / beginners

author: Pirateguy
author_rank: Regular Contributor
timestamp: October 13, 2018, 11:59:32 am
content: rather then dig up the old thread i decided to start a new one.so i have drawn up a plan and with some help will be making a box to put it all in.here's my schematic:and the panel:

author: Pirateguy
author_rank: Regular Contributor
timestamp: October 13, 2018, 12:33:07 pm
content: please let me know if any of the following is retarded:ok so the plan right now is to have multiple poly switches to switch between,so i can access somewhat higher currents without removing protection altogetheror limit the current to 100ma for sensitive projects.these will be followed by an RGB LED so the colour will tell me which fuse i am set to.i think i need those diodes to keep from lighting up all leds all the time.i assume these diodes would need to be rated for at least the 6A of the heaviest poly fusethe M box represents this:https://www.ebay.com/itm/Dual-Blue-Red-Red-Red-LED-Digital-Voltmeter-Amperemeter-Panel-Amp-Volt-Gauge-DC/322982162973?ssPageName=STRK%3AMEBIDX%3AIT&var=512120455709&_trksid=p2057872.m2749.l2649meter display thingyor this one:https://www.ebay.com/itm/DC-0-30V-3-Wire-LED-Digital-Display-Panel-Volt-Meter-Voltage-Voltmeter-Car-Motor/182952047363?ssPageName=STRK%3AMEBIDX%3AIT&var=690269460764&_trksid=p2057872.m2749.l2649The load resistor will be 4R7 10watt to run at 5.3 watt, just over the minimum 5 required.a simple signal generator and relay timer will be included in the box.i was thinking of having each of them drive a relay that connects a line to ground, and thatthat way i could take any voltage and use that ground connection instead of the regular oneand i would have that voltage modulated.the third relay is simple a pushbutton and a connector in parallel so i can connect a remote button or switchor something like that. it could be used as a dead man's switch or sometimes i imagine i will want to convenientlyswitch things on and off without having to reach for the unit, or give short bursts of power to test something or other.is a relay the appropriate choice for this?the thermometer would have a switch between an internal sensor and a set of binding post so i can use it externally.i was thinking i need some thermal insulation to keep the temp inside the box from throwing off the thermometer.maybe some of that expanding insulation foam?ok so let me know if any of that doesn't make sense etc.also: any tips on how to wire this in an organized fashion?

author: PointyOintment
author_rank: Frequent Contributor
timestamp: October 15, 2018, 03:25:49 pm
content: Quote from: Pirateguy on October 13, 2018, 11:59:32 amI had todig up the old threadbecause I couldn't understand this fully without it. It seems that this machine will be based on an ATX power supply.QuoteYour schematic is both messy and cramped. It's more cramped than it is messy (IMO), so it shouldn't be that hard to clean up. But you should also make more use of named nodes so you don't have lines going all over each other. Also, the components should be labeled with reference designators. They make the circuit much easier to talk about, so people would be more willing to help you.In the schematic, you have USB type-B sockets, whereas on the panel you have type-A (which is what you want).The third of the four panels with switchable polyfuses has only two current options, not three. I presume this is because the 7809 can't supply 6 A. In the old thread, there was much talk of pass transistors, so I know you already know that's an option if you want more current from that channel.For the modules on the right, why not put switches on their power inputs if you want to be able to turn them off? The switches in series with the output relays seem strange.QuoteLet me see if I can understand your front panel. Labels would help. You might not need them yourself, but maybe a friend will use this power supply at some point, or maybe you'll put it away when you get a better one, and pull it out years later to use for something, and not remember what does what. I would understandnoneof the front panel if I couldn't look at the schematic simultaneously, and I would only understand 75% of it if I hadn't read through your old thread fully.Anyway, here's how I interpret it. Everything I don't understand or get wrong in my interpretation is probably something you need to correct.Column 1:Power Good LEDmaster power switchbutton for manual relay outputLED that isn't in the schematicexternal control input for manual relay output (the "unspecified 2-pole connector")manual relay output switched ground terminal—see below on using relays to switch groundpointless LEDs that will always be onUSB portsColumn 2:4 pairs of RGB LED and switch for the switchable current-limiting polyfuses for the 4 switchable-current-limit positive channelsColumn 3:4 voltage/current displays for the 4 switchable-current-limit positive channelsColumn 4:4 positive terminals for the 4 switchable-current-limit positive channelsColumn 5:4 ground terminals shared between the 4 switchable-current-limit positive channels and the three negative channels (all grounds common, but one per row for convenience)Column 6:2 yellow terminals together for the thermometer's external input3 yellow terminals for the negative channelsColumn 7:LED that isn't in the schematicThermometer internal/external switchThermometer displayThree voltmeters for the negative channelsThree LEDs to indicate polyfuse statesColumn 8:DPS moduleRelay timer module4–20 mA semi-arbitrary waveform generator (a strange choice)Column 9:Switch that isn't in the schematicGround terminal—where's the positive output terminal of the DPS module as shown in the schematic?Switch for the relay timerSwitched ground terminal from the relay timer—see below on using relays to switch groundSwitch for the function generatorSwitched ground terminal from the semi-arbitrary waveform generator—see below on using relays to switch ground and on using a relay on the output of the function generatorWhy do you have voltmeters when the voltages should not vary by a large enough amount to register on them? (Do you think you need them to know which channel has which voltage because you don't know the concept of labels?)Quote from: Pirateguy on October 13, 2018, 12:33:07 pmUsing switchable polyfuses for current limiting is strange, but it could work. (I would find this power supply inadequate for testing LEDs, though. For those, I usually set a current limit of 20 mA and a voltage around 4 V and hook up the LED in both directions until it lights up (because I can never remember the polarity indicators). When I figure out the correct polarity, it runs in CC mode at 20 mA (which is a safe current level for most LEDs). I set the voltage to 4 V so that when I hook up the LED in reverse, I don't exceed its reverse breakdown voltage and destroy it.)QuoteYes and yes. On the 100 mA polyfuse, won't the LED take up a significant amount of that current?QuoteA relay is fine for that, but you've connected its switch to ground. When you press the button, the relay output will be connected to ground. When you release the button, the relay output will be unconnected (floating). I initially assumed that this is not what you want. Then I realized it probably is. You're probably planning to connect your load between whatever positive voltage terminal you want and this switchable ground terminal. This seems unwise—it will leave your whole load floating at the positive voltage when the relay output is off. If a grounded part of the load touches a grounded object on the bench, it will still be powered when the relay output is "off".QuoteA relay isnotfine for that.In fact, that's probably the worst possible thing you could do there.Thefunction generator that you linked to in the other threadis actually an arbitrary waveform generator, which would seem like a good thing, but it's actually anextremelylimited one. It's meant for testing PLCs by simulating a sensor that provides a 4–20 mA proportional output (which is anindustrial de facto standard for that stuff). Also, it can only do 9 linear segments of a function (though that would be enough for you most of the time).I can't tell whether it pushes the set amount of current through the current loop, or just allows the set amount of current through itself under an externally applied voltage (which would come from the PLC, in its intended application).I can't figure out what the hookup diagram on the product page means, either. And the textual description of how you operate it makes it sound like it will be extremely frustrating to operate.Anyway, assuming you can hook it up and get it to work, it will give a current output, not a voltage output. The current will vary between 4 and 20 mA. This is probably not suitable for driving a relay, but you haven't provided a part number or datasheet for the relay, so I don't know how much current its coil needs.Also, are you aware that relays are either on or off, and cannot provide a proportional output? Knowing that, it makes no sense to use one as an output stage for a function generator. If the function generator could drive the relay, most of its purpose would be wasted because the relay could not reproduce the proportional output of the function.Also, the relay has hysteresis: it requires some level of coil current to close the switch, but then when the coil current decreases, the switch doesn't open again until the coil current reaches some much lower level. This will distort the timings of the function as well.Also, switching a relay rapidly will wear it out quickly. However, this doesn't apply to your unwisely chosen function generator because its minimum time per segment is 1 second.A much better output stage for this function generator would be a transistor. Either a BJT or a MOSFET could reasonably be made to work. However, if you want to do that, post the schematic for review before you build it!QuoteHuh? What's the purpose of the internal thermometer? If it's to measure the internal case temperature of the power supply (to check whether it's overheating), just put it in there, probably in the exhaust air stream. If it's to measure the room temperature, put it in the intake air stream. Insulation would just make its readings meaningless.QuoteMaybe make a wiring diagram first. But before you can do that, you'll need a schematic that's correct and ideally also easy to read. Dave has a video on that:

author: Pirateguy
author_rank: Regular Contributor
timestamp: October 16, 2018, 04:00:52 am
content: lol yeah sorry about that, ADD got the better of me there.All of your interpretations are correct.some clarifications:Quotethe led not in the schematic would be in series with the button, not sure if i will include the button on the unit itself.the point of the LEDs is to confirm the usb ports are active.Quoteindicates thermometer switch stateQuoteit's the cheapest one that comes as a panel unit like that.Quotethats a booboo, the switch is supposed to be the missing positive terminal.Quotecheap ebay module, and it looks sexyQuoteright, i have gotten into the habit of using a 2032 coin cell for testing leds.i made a little holder with breadboard leads and a female header for this purpose.the poly switches aren't really for control, i have the DPS for specific needs, but rather to set a general safety level.originally they were just 1 fuse, but i figured it might as well do it like this, in case i want to use more power then the fuse allows.maybe a 1A, 6A and unfused connection might be more practical?Quotewell since it is only an indicator led, i plan to run it at 2ma or so. certainly no more then 5.would u recommend i run it through a transistor off the 5v rail?Quotegood point.so i should do it the other way around, have an in and out terminal and use a jumper wire between that in and the voltage i want to use.Quoteyeah the func gen and relay timer thing are mostly there to fill the space. ill have to experiment some before i decide if i actually include them.anyway the idea is to provide a PWM signal to drive motors and that kinda thing.this whole right end of the thing i plan to work on over time with upgrades n stuff.i shouldn't have added that to the circuit, as i plan to work that as a separate project after finishing the rest of it,but i wanted to know about the relay n if this idea made sense outside of my own headi think i will start another thread for this part once i get around to it.Quotethe idea is to display the internal temp of the unit. mostly just to have something relevant on the display when i'm not using the external.the isolation would be around the unit itself so that the sensor picks up the temperature, but when disconnected the unit itself, and the remaining wirefrom the sensor do not pick up temp from the psu when i am using the external.the external of course is for measuring temperature in projects.not sure if ill ever have a need for that, but if there is no practical issue with having a switch like this, i figured why not.

author: PointyOintment
author_rank: Frequent Contributor
timestamp: October 16, 2018, 08:54:57 pm
content: Quote from: Pirateguy on October 16, 2018, 04:00:52 amI realized after I'd posted and put away my computer that you could just use the DPS for LED testing and other low-current stuff, so I guess having only the three polyfuse levels is fine.QuoteNo, that's probably fine. You're not going to get any good trip current precision out of the polyfuses anyway.QuoteThat's probably how I'd do it.QuoteThe internal thermometer doesn't get disconnected when you use the external one? That seems like it would prevent accurate reading of the external thermometer except when the two happen to be at the same temperature.

author: glarsson
author_rank: Frequent Contributor
timestamp: October 16, 2018, 09:09:46 pm
content: In the schematics you only show one type of voltmeter, but on the illustration you show both one type for voltage only and one type for both current and voltage. The schematics doesn't show connections that enables current measurements.The current passes through a fuse, a diode and (perhaps) through a current meter on its way to the binding post. A lot of voltage is lost here. The 5V will not be 5V... The output voltages will also vary with the current. Not very stable.Also, some of the diodes will require quite a lot of cooling.

author: janoc
author_rank: Super Contributor
timestamp: October 16, 2018, 09:22:04 pm
content: Quote from: Pirateguy on October 16, 2018, 04:00:52 amWell, that will certainly not work with that. You cannot use a relay for PWM! Moreover, that generator is not actually outputting any PWM signal neither, it is for testing current loops.This is, IMO, a very strange thing to put in a power supply. A PWM driver for testing a motor will require an output stage with e.g. some beefy mosfets and variable voltage because otherwise you won't be able to test much else than tiny DC motors. And then such "tester" could easily be the size of the power supply itself (the mosfets will likely need cooling too!).I strongly suggest that you build what you actuallyneedand not a Star Trek control panel full of blinky LEDs and pointless switches and meters. Otherwise I can pretty much guarantee you that you will never use half of the stuff in that box and the other half will never have enough amps/volts/heatsinking/whatever to be actually useful while working on some projects.I would toss all that crap and rather build a good linear power supply (switching noise is a big problem in a lab supply!) and mainly make sure that it has current limiting! Polyfuses are fine, but they only protect the supply from catching fire, they won't save your device under test from destruction if you have a wiring error somewhere.Or, at the very least, use two of those DPS modules (assuming they have floating outputs) and make a dual supply with them. That will be way more useful than this Hollywood-style nonsense.

author: Pirateguy
author_rank: Regular Contributor
timestamp: October 16, 2018, 10:47:55 pm
content: Quotewell technically there is no external thermometer, just the probe would be external.i have one of those PC sensors and a stick one that came with a multimeter that has a thermometer in it.the thermometer is inside the display module, that's why i am worried it will be influenced by the ambient temp in the box,even when the internal sensor is disconnected.Quoteyeah i was gonna just do voltage for the negative rails, but then i decided to go with all the same dual displays for looks.Quotei want the display to read what is actually happening at the binding post though, don't i?Quotewhat if i have overpowered diodes on there?i have some 1000v 10A ones on the way...Quoteyeah i expected as much, but wasn't sure what to use in it's place.ima have to do some more homework on that bit.that's why i have put that off and will come back to it as a separate project.Quotewell i am happy with having simply the one DPS and a couple of fixed outputs.current limiting seems a bit advanced for me at the moment. i figured i would use the DPS for sensitive things, and suffer the burns otherwise.as a beginning hobbyist i kind of expect a little smoke here and thereanyhoo, i redid the circuit diagram a bit:

author: glarsson
author_rank: Frequent Contributor
timestamp: October 17, 2018, 06:17:19 am
content: You do want to know what happens on the output post, but that does not help when the 5V output in reality is only 4V.For the diodes it does not matter how many amps it can conduct, you still need to handle the loss of up to 1V times the number of amps, i.e. 10W for 10A.Also, the volt/amp meters will not measure any current the way you have connected them in the latest schematics. The current must pass through the meter.Frankly, there is a reason why commercial lab power supplies isn't designed like this.

author: Pirateguy
author_rank: Regular Contributor
timestamp: October 17, 2018, 11:19:58 am
content: so, if the fuses only protect the psu, there is no real point in having more then 1, is there?

author: janoc
author_rank: Super Contributor
timestamp: October 17, 2018, 03:20:50 pm
content: Quote from: Pirateguy on October 17, 2018, 11:19:58 amThe problem with a polyfuse (or even a normal fuse) is that it is too slow to protect semiconductors from overcurrent. Furthermore, when bringing up a new circuit you want to set the current limit as low as possible to limit the current that can flow through the circuit in case there is some mistake. Only when you are reasonably sure that everything is working as intended you start raising that limit. E.g. I am commonly using 10-20mA current limit when bringing up a new circuit - that's so low that even if I goof it won't destroy most components.If your only current limiting device is a polyfuse then that limits your current choices a lot. Your polyfuses are much bigger than 20mA, I believe. That's why I wrote that a polyfuse is a good thing to protect against a fire (I assume you want to use an ATX supply to power this contraption - those can deliver 20A like nothing, whichwillset things on fire if there is a problem) and destroying the power supply (even though they do have short circuit and overload protections). However, it will not do so much for your device under test - even the smallest polyfuse you put there will likely allow enough current to fry your circuit if there is a problem.

author: PointyOintment
author_rank: Frequent Contributor
timestamp: October 17, 2018, 09:12:30 pm
content: Quote from: Pirateguy on October 16, 2018, 10:47:55 pmOh—you're worried about the temperature of the cold junction. Does your thermometer module lack cold junction compensation?

author: Pirateguy
author_rank: Regular Contributor
timestamp: October 17, 2018, 10:50:54 pm
content: Quote from: PointyOintment on October 17, 2018, 09:12:30 pmwell it's the cheapest one i could find on ebay, i don't expect any luxuries lol.https://www.ebay.com/itm/New-Digital-LCD-Thermometer-Temperature-Meter-Gauge-Molex-Panel-Mount-C-F-PC-MOD/122513357209?ssPageName=STRK%3AMEBIDX%3AIT&_trksid=p2057872.m2749.l2649