How to connect my transformer to mains power properly - Page 1
Forum section: electronics / beginners

author: mkelly09
author_rank: Newbie
timestamp: May 19, 2011, 01:25:35 pm
content: Hello everyone,I've just started undertaking a DIY bench power supply design based on this one here:http://electronics-diy.com/electronic_schematic.php?id=787Schematic here:http://electronics-diy.com/schematics/787/Bench_Supply_Schematic.pdfBefore i get into this i would like to mention that I have read up on the threads here regarding mains safety and will be very careful when doing this project. I realize that it can be dangerous, but at the same time, I am doing this to learn as much as i can. I feel that i will learn more by actually using a transformer vs. using a wall wartSo far, the features that I know I want( a bit different than the project linked):-3 outputs: +15V, -15V (for op-amps) and one variable output 0-15(or 20, 25 but really no need for this much)-1A output (flexible i guess)-LCD displaying the voltage and current for my variable output-pot for voltage adjustment, on/off switch connected to shut off mains, on/off switch for the +15 and -15 outputs(one switch for both), and one last switch for the variable output-probably some LEDS to indicate power on for my outputs(or i could get those lighted switches)-2A fuse connected on mains before switch-some form of current limiting circuitHere's the transformer i've bought:http://parts.digikey.com/ca/1/621291-xfrmr-pwr-115-230v-17vac-2-8a-lp-34-1400.htmlits datasheet is located here:http://www.signaltransformer.com/sites/all/pdf/LP.pdfMy question is how do i connect this transformer correctly, as there are four pins on each side. Is there an easy way to tell which side of the transformer is the primary side(one is marked signal, the other something else- i don't have it in front of me ATM)From digi-key:Series Output Voltage @ Current 34 VAC @ 1.4AParallel Output Voltage @ Current 17 VAC @ 2.8AI figure i'd like the series output voltage.Also, while i'm here, whats the best option to do with the green(earth) wire? I plan on mounting this in a wood case, should i just snip it back and heat shrink it?

author: bilko
author_rank: Frequent Contributor
timestamp: May 19, 2011, 01:48:10 pm
content: The transformer you selected won't allow you to load up the supplies. The maximum current is 1.4A, this is for all the outputs combined. If this is OK for you, I would fuse the secondary with a 2A fuse to protect the transformer.The ground wire from the mains should be connected to the frame of the transformer. You can use one of the mounting bolts with a tag soldered onto the ground wire.

author: Psi
author_rank: Super Contributor
timestamp: May 19, 2011, 01:57:53 pm
content: In the picture it looks to have numbering on the label to show you which pin is what.From the datasheet pins 1,2,3,4 are the primary.It has two 115V coils which can be connected in parallel for 115v operation or in series if you have 230vFor 230V you would connect pins 2 and 3 together and feed 230V between pins 1 and 4For 115V you would connect pins 1 and 3 together and this would be one 115v input. The other would be pins 2 and 4 (connected together)If there is no label on your one then there is a trick you can do to work it out, but it requires wiring up 110/230v so beware of safety issues.There is probably a safer way to do it, but this is how i do it.Pick one side and connect it to mains as above (for 110 or 230V)butput a 110/220v light bulb inserieswith it. That way, if it's a dead short you don't blow up anything. Instead the lightbulb will just light up and tell you you have it connected wrong.Make sure the other side of the transformer is leftunconnected, if it turns out to be the 230v side it will have230von it!This works because when a transformer is connected correctly and there is no load it should draw no current. No current means the lightbulb will stay off.Of course to do this you need to have a 110/230v lightbulb holder and you have to be very careful to not touch anything when the power is on. Only work on it when the power is off and its unplugged from the wall.Safety first!

author: Unknown
author_rank: Unknown
timestamp: May 19, 2011, 02:03:32 pm
content: Quote from: mkelly09 on May 19, 2011, 01:25:35 pmNot being rude, but this question screams to me that your not quite ready to be building mains powered projects unassisted just yet.Any exposed metallic parts of your project should be securely earthed as an absolute minimum.I'd suggest you look at some more detailed projects for some clues about securing mains cords, chassis and frame earthing etc.The transformer you've selected is a PCB mounting type, how did you intend on mounting it?I don't want to dampen your enthusiasm, but maybe the wall-wart approach would be better for a first project.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 19, 2011, 02:13:30 pm
content: safer way without messing with mains, use a dmm, even the cheapo will happily do. check the ohm at each pin. the connection with almost 0 ohm is secondary. primary will have more resistance like 10-200 ohm.you can get away without earth wire. earth wire is meant to tunnel any stray current (from life) back to earth safely. so if your design has no leak, your system will run without fault. but in case life wire leaks/connected to gnd part of the circuit or equipment metalic housing, with earth wire connected, you will not risk touching the housing and the stray current running through you back to earth. but certainly earth wire is not meant to be connected to wood, it will not conduct current anywhere.

author: Psi
author_rank: Super Contributor
timestamp: May 19, 2011, 02:22:05 pm
content: Quote from: Mechatrommer on May 19, 2011, 02:13:30 pmI've encountered a few transformers where that method gives values that are a bit too close together for me to feel safe trusting them. eg 6R on the 230v primary and 3R on the 12V secondary.It's definitely a much safer method for checking, but only if it gives you the right answer

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 19, 2011, 03:01:35 pm
content: Quote from: Psi on May 19, 2011, 02:22:05 pmthats big transformer i believe. my rule of thumb for checking transformer:1) the least resistance goes to secondary2) thinner wire (in the winding) is the primary3) more winding is the primary (step down transformer)but your method could be a tip as well, but i never try them. i suspect the bulb can also lit if you connect it either side, esp the big transformer like you said.

author: vk6zgo
author_rank: Super Contributor
timestamp: May 19, 2011, 03:11:00 pm
content: Quote from: Uncle Vernon on May 19, 2011, 02:03:32 pmI agree wholeheartedly,particularly with the comment about looking at more detailed projects for clues on mainsconnections, etc.Another suggestion is to look at how it is done in modern commercially made equipment.One way to check which side is which,is to get a source of low voltage AC (If you have some old unusedwallwarts,some may be AC output),& connect it to one of the windings,check what voltage appears across that winding,thencheck,very carefully, across the other windings.(1) If you see a fairly high voltage across one of the other windings,you knowthatwinding is a primary winding.( With this transformer you will see two windings with fairly high voltages)(2) If all the other windings show lower voltages than the one your low voltage ac source is connected to,then thedriven winding is one of the primary windings.In this case, connect your source across one of the ones that now appear to be secondaries,& check for a highervoltage onthe winding you just disconnected it from.(as in (1) ).(Again,as this transformer has 2 primaries,you will see 2 windings with a high voltage)If you are at all unsure,see if you can should some help from someone with more experience in your local area.VK6ZGO

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 19, 2011, 03:25:54 pm
content: Quote from: yachtronics on May 19, 2011, 01:48:10 pmif its rated to 1.4A max, then installing 2A fuse will not do any good. even if you short the secondary, it will not even reach 2A, there must be techy explanation for that which i still dont know, maybe saturation?. the only thing you have to care about if you have to use max rating of a transformer is the heat generated, which will cause damage to the transformer itself.lets not discourage the OP shall we? he maybe like me a long time ago, alone tinkering this stuff with my $3 DMM. thats why he's asking here, and thats why we are here for. to guide him. all he need is just a lil bit of 50Hz tingling sensation to do it correctly

author: Psi
author_rank: Super Contributor
timestamp: May 19, 2011, 03:41:47 pm
content: Quote from: Mechatrommer on May 19, 2011, 03:25:54 pmtransformers are pretty robust, even if its only rated for 1.4A shorting it out will draw many times that. It wouldnt surprise me at all if a 1.4A transformer could blow a 4A fuse.That being said, a 1.5A fuse would be a better choice than a 2A one.

author: mkelly09
author_rank: Newbie
timestamp: May 19, 2011, 04:04:07 pm
content: Thank you very much to everyone who replied.To those who mentioned I may not be ready to work with mains, you may be correct and i appreciate your concern... but again, there's only one way to learn. I certainly plan on doing more research on how to safely go about this.. i'm not going to be plugging things up and 'hoping for the best'. Like the last poster mentioned, it is why I am here asking questions.As far as test equipment goes, i picked up a used Fluke 87V for cheap on ebay. I do not have an oscilloscope, but have access to them in my universities labs(going into 3rd year EE @ uOttawa this fall). I figured since this was my first project it doesn't have to be precise, i'll use it for a bit until it no longer fits my needs(then i'll modify it so it does!)Quote from: yachtronics on May 19, 2011, 01:48:10 pmI thought that to start with, 1.4A would be enough.. Over the next few months i will mainly be working with micro controllers like the arduino, possibly messing around with some op-amps like the LM741. I don't really know exactly what ill be using the supply for in the future, but i'm guessing i can always change the transformer later if I need more current down the line.If i used the parallel output i could get 17V with 2.8 A max current. Would i still be able to create 15V dc out of this?(I know i lose some voltage in the bridge rectifier, is there anywhere else?)Like i said, i plan on mounting this in a wooden enclosure. So is soldering the earth wire directly to the frame of the metal transformer sufficient?Quote from: Uncle Vernon on May 19, 2011, 02:03:32 pmFor mounting the transformer I was planning on keeping the transformer section of the project separate from the PCB that i'll be making(first time ill be making a pcb) to house the bridge rectifier, filter caps, voltage regulators and essentially having heat shrinked wires running from the secondary side of the transformer into the PCB.For physically mounting the transformer into the project I have a few ideas and haven't really decided yet, but since i'd like to have an on/off switch and a fuse, it will probably require its own PCB or perfboard.I'm going to do some more research on mains powered projects before I dive in with this. I'll have to take a look around, but in the meantime- does anybody have any suggestions or good starting places to begin looking?Thanks again everyone.

author: bilko
author_rank: Frequent Contributor
timestamp: May 19, 2011, 05:55:02 pm
content: Quote from: Mechatrommer on May 19, 2011, 03:25:54 pmThe reply was not meant in any way to discourage the OP. It was to give the OP some knowledge and to make him aware of the limitations of the set up. In the original schematic, there is no fuse in the secondary. Loading each of the outputs up to the regulator limit would draw a load in excess of the maximum the transformer could deliver. The transformer would get extremely hot, possibly fail or cause a fire.The OP probably didn't know this, is it best that I didn't mention it and let him find out himself ?Regarding the 2A secondary fuse, this is a protection measure to prevent the above from happening, maybe a 1.5A would be better but certainly if all regulator outputs were loaded the 2A would blow.The ground wire should be connected to the transformer mounting because in case of a short circuit to the frame the 2A primary fuse would blow, else what is the purpose of the primary fuse ? The supply would have to draw in excess of 500W to blow it.Quote from: mkelly09 on May 19, 2011, 04:04:07 pmIf you parallel the secondary windings you would get twice the current and still get 15V. The variable voltage would be limited to around 15V too.Good luck, at least you are asking the right questions

author: Zero999
author_rank: Super Contributor
timestamp: May 19, 2011, 06:08:11 pm
content: Quote from: Mechatrommer on May 19, 2011, 03:25:54 pmQuote from: yachtronics on May 19, 2011, 05:55:02 pmUsing a 1.5A fuse would be a bad idea because it would cause nuisance tripping.A fuse is just there as a last resort. It should be higher than the current rating but the short circuit current must be high enough to cause it to blow. The transformer will definitely allow more than 2A to flow when short circuited. I estimate around 15A, going from calculations using figures for a datasheet for a 50VA twin 18V secondary transformer with both its secondaries connected in series to give 36V, see the calculations below.http://docs-europe.electrocomponents.com/webdocs/0b9f/0900766b80b9f16f.pdfPrimary and secondary resistances:RP= 44RRS= 0.64 + 0.64 = 1.28RTurns ratio, calculated using the open circuit voltage.10% regulationVOC= 36 + 36*0.1 = 36 + 3.9 = 39.6VN = 230/39.6 = 5.81The actual resistance seen on the secondary when the transformer is connected to the mains is equal to the actual secondary resistance, plus reflected series resistance of the primary.Calculate the reflected primary resistance:RPR= RP/N2= 44/5.812= 1.3RCalculate the total effective secondary resistance:RT= 1.3 + 1.28 = 2.58RThe short circuit current can be now calculated using Ohm's law:IS= VOC/RT= 39.6/2.58 = 15.3AThe figures will be very similar for a 48VA 17V transformer. A quick way to roughly estimate the short circuit current is to divide the current rating by the regulation 1.39A/0.1 = 13.9A. The above calculations won't be 100% accurate because they don't take into account the leakage inductance and core losses which are unknown.

author: bilko
author_rank: Frequent Contributor
timestamp: May 19, 2011, 06:25:12 pm
content: Quote from: yachtronics on May 19, 2011, 05:55:02 pmFurther comment, I would use a 2A resettable DC circuit breaker or a polyfuse in preference to a standard glass fuse on the secondary as it is likely to trip often when the supply is overloaded

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 19, 2011, 06:40:25 pm
content: ok thats about the right value and math.

author: mkelly09
author_rank: Newbie
timestamp: May 19, 2011, 06:49:21 pm
content: Quote from: yachtronics on May 19, 2011, 05:55:02 pmThanks for your response. I will parallel the secondary windings to get twice the current, as i don't mind if my variable voltage is limited to 15V.Looking around, i found this online:http://www.hammondmfg.com/5CHook.htmAm I correct in assuming that, since I am in Canada, I should parallel the primary connections as well as the secondary connections as shown in the link above?(Figures 2 & 4). Inspecting these diagrams shows a discrepency between these and my datasheet(in my datasheet the dot to indicate like polarity is placed differently) is this cause for concern?

author: bilko
author_rank: Frequent Contributor
timestamp: May 19, 2011, 07:07:06 pm
content: Quote from: Psi on May 19, 2011, 01:57:53 pmFrom PSI's reply above.If your utility voltage is 115V connect in parallel, if it is 220V connect in series

author: Unknown
author_rank: Unknown
timestamp: May 19, 2011, 10:04:24 pm
content: Quote from: mkelly09 on May 19, 2011, 04:04:07 pmThere is always more than one way to learn, I commend that you are asking questions and trying to do things correctly. For something that is basically a very simple part of most projects, mains supply does require a lot of care and consideration. It is the bit that is usually capable of the biggest bang.QuoteA good multimeter like your Fluke will be all the test equipment you should need to test, troubleshoot and set-up a linear supply.Quote1.4A is quite a useful amount for your intended purpose. What you need to consider is what is the outcome if you inadvertently or accidentally overload your supply. Your other projects are likely to survive a misadventure better with a smaller supply.QuoteYou will actually gain some voltage with a full wave bridge but you need to consider the dropout characteristics of the regulators. You will need a few volts above your intended output to ensure it remains regulated at all times. 17V would be sailing very close to the wind at best for a 15V output.Check the specs of your intended regulator to be sure.QuoteTimber is a curious choice but it is after all your choice. Good luck on effectively soldering a solid bond onto that transformer. A better practice would be to solder a ring lug onto the earth wire and to affix that via a bolt and nut with star and shake-proof washers ensuring you remove sufficient paint or enamel to ensure a low ohm connection. Mounting bolts can be used good practice being to use another lock not to ensure the bond cannot work loose. This is why I recommended looking at some kit projects, even if the kits don't meet your needs the instructions for many will cover such aspects in detail. Are you considering metallic front or back panels or even metal carry handles? All of these must be securely earthed also.QuoteQuite right to avoid mains wiring on a first time PCB. I still think however that you may have created a lot of work for yourself by not selecting a chassis mount transformer which would have been a lot better fit in your timber cabinet. Good luck getting transformer pin to fit/align with perfboard. Then of course you have ratings and adequate track spacing to consider. Timber may well prove a curse again when it come time to mount suitable fuse-holders switches etc. Most will be designed for mounting through a thin metal or rigid plastic surface.QuoteHave a look at some of the mains powered projects in Silicon Chip or Elektor, the projects do not have to be powers supplies. These magazine article usually go into considerable detail on good practice for mains wiring.

author: Zero999
author_rank: Super Contributor
timestamp: May 19, 2011, 10:25:40 pm
content: Quote from: yachtronics on May 19, 2011, 06:25:12 pmYes do that, a polyfuse also has s longer time constant so won't be so prone to nuisance tripping and you're more likely to be able to get away with 1.5A although the voltage loss will be slightly higher.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 20, 2011, 12:37:10 am
content: ooh. as hero calculated it, 15A is the max current. if you are into hacking project, you can harness that 15A, maybe not to the max 15A, like 10A or such. just put a fan to cool that thing down. at least that what i did to my unknown unspecified transformer, i can put anything up to a bare copper on the output, just mak sure the rectifier diodes can handle that current

author: Psi
author_rank: Super Contributor
timestamp: May 20, 2011, 12:52:04 am
content: yeah, you can over spec transformers quite a bit, as long as they don't overheat.Ya probably wouldn't want to do it in a professional product but for a hobby project it's normally fine.

author: Zero999
author_rank: Super Contributor
timestamp: May 20, 2011, 04:47:04 pm
content: Quote from: Mechatrommer on May 20, 2011, 12:37:10 amNo I calculated the expected short circuit current. You'll only get 15A when the secondary voltage is near zero.When short circuited the transformer will be dissipating around 600W when is only designed to dissipate less than 100th of that so it will either smoke and catch fire or the thermal fuse will blow rendering it useless. You can exceed the power rating for short periods of time and a fan will help but doing so too much for long periods will destroy it. If the power rating is exceeded, the extra voltage drop should also be accounted for in the calculations.