Can anyone help me with LED circuit layout planning?

Ask and answer questions, share tips and resources for installing lighting and other electronics in your models.

Moderators: Sparky, Moderators

Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Can anyone help me with LED circuit layout planning?

Post by Magma »

I've bought a Revell Voyager kit, and am planning to light it. I want to try to put the lighting together myself rather than get a kit, but I haven't done any electronics since making a red LED light up at school once, and once the model is sealed up then there's no going back - So I've been doing some reading up on various how-to guides including the one on this site.

I'm aware of the basics:

* Series circuits consume voltage
* Parallel circuits split the current
* The slack voltage in each series rail needs to be taken up by a resistor calculated by Ohm's law
* Stick to 1/4W rated resistors
* Use a diode to stop reverse battery connection causing damage

This is a list of all the LEDs I'm going to use:

6x 3mm red (Forward voltage 1.8-2.0v, Forward current 10-15mA)
6x 3mm green (Forward voltage 2.0-2.6v, Forward current 10-20mA)
4x 3mm yellow (Forward voltage 2.1-2.3v, Forward current 10-15mA)
4x 5mm super-bright red ( Max forward voltage 2.5v, Max forward current 30mA)
5x 5mm blue (Forward voltage 4.0-4.5v, Forward current 20-30mA)
3x 10mm white (Max forward voltage 3.3v, Max forward current 30mA)

In addition to the above, I'm planning on getting the blinking navigation lights implemented on a separate circuit with 4017 decade timers. I can't find any mention of what the additional power drain from intermittent LEDs would do to the steadiness of the illumination from the other LEDs if I powered all of them off one power source.

A number of how-to guides have conflicting advice about how to run so many LEDs economically from one power source without burning any of them out or having some not light. Some examples of the contradictory advice I've read:

* Wire each individual LED in parallel
* Stick with series
*Use series until the voltage limit is reached and then start a new parallel rail
*Make sure the parallel rails are identical arrangements of different types of LEDs or not all of the rails will light
*Make sure each parallel rail only contains one single type of LED or some LEDs on that rail won't light
* If the LEDs on a circuit don't have closely matched current requirements, some will not light
* It's okay to run identical parallel rails off one resistor
* Each rail must have its own resistor regardless of what's on it

If I were to use all these LEDs in series, I'd need a thoroughly impractical supply of 81 volts. In parallel, it would require 570mA but 28 pairs of wires (many of which would be running through the already cramped fantail section). I'd prefer to have fewer connections from the model to the PCB if possible, because I'd like to be able to detach the model from the base for ease of transport and that would require some sort of connector plug.

Ideally I'd like to power the whole thing off a standard 9V PP3 battery, or possibly a 12V A23 battery if the increased voltage helps power more LEDs in series.

I have a breadboard for prototyping, but I've avoided getting any resistors until I have a reasonable idea what values they will need to be.

Can anyone with more experience with LED circuit planning give me an idea what layouts I can safely use, and what layouts I should avoid like the plague?



Thanks in advance for any assistence rendered!
ChrisQ
Posts: 142
Joined: Fri Jul 02, 2010 11:53 pm
Location: Baltimore, MD

Post by ChrisQ »

This was one of the very first models I lit up too (just finished a couple months ago). I had a lot of trouble with the wiring from the nacelles through the flat part of the "wings", because of the 2 leds that need to be installed inside that flat part as well. I did not have a good plan for that part. The rest of the model was simple.

You may find that your exterior bulbs are way to large. I started with 3mm on my build and quickly dropped to 1.8mm. Now that it's done, I also wish I had used larger resistors as they are still extremely bright.

Also, you will be doing yourself a huge disservice if you don't get the window inserts from Outer Space Outfitters. I don't think SSM stocks his products but you can find his store on Ebay or find the item at another well known online hobby shop.

I wish I had a decent camera so I could show the window inserts in action here, but along with having a crappy camera, my skills are not up to par with most here so I have not been in a huge rush to get a better camera :)

All in all it was an enjoyable model to light up. Hope you have fun!
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

I know that at correct scale the lights should be only 1mm across, but I think I'll stick with 3mm. It shouldn't look too bad at this scale.

How did you organise the LED wiring layout?

I have the paragrafix kit for adding corrected details, and plan to make small perspex boxes out of a CD case for inside the larger windows. I can print the room plans onto OHP acetate and fix them in place so they hang back from the windows but still get lit adequately. I may even try putting a little ready room table in there :)
ChrisQ
Posts: 142
Joined: Fri Jul 02, 2010 11:53 pm
Location: Baltimore, MD

Post by ChrisQ »

I run all my led wiring in parallel. Otherwise when one bulb dies it takes the entire circuit with it, correct?

As for a schematic, I am not the one to ask. I can barely read a simple one much less draw one for you to read. I couldn't find any decent walk-throughs by other modelers when planning mine so I just jumped in and started doing it (hence the problems I had when I got to the pylons).

I will say this - if you haven't read about it already, I would suggest using the straw trick for your nacelles rather than just sticking exposed leds in there. And instead of 3 or 5mm with a straw, I would roll my own using .10mm white styrene and 10mm leds. Much brighter and more even glow. However, YMMV.
User avatar
tetsujin
Posts: 2353
Joined: Mon Feb 28, 2005 6:08 pm
Contact:

Post by tetsujin »

ChrisQ wrote:I run all my led wiring in parallel. Otherwise when one bulb dies it takes the entire circuit with it, correct?
I have heard that when LEDs die, they turn into short-circuits. That would mean the opposite is true - a series chain would survive the death of an LED (as long as the other LEDs didn't wind up getting too much current and also burning out) but a parallel chain would be shorted out (which would still probably be OK, if each LED has a series resistor.)

Personally I don't plan for LED burn-outs. I mean, if an LED did burn out I'd want to replace it - I wouldn't want some section of my model to be mysteriously dark while the rest is lit up. But generally I feel like arranging to make all my wiring accessible is usually too much work, so I accept that LED burnout, if it occurs, is probably the end for the model's lighting.
---GEC (三面図流の初段)
There are no rats.
The skulls eat them.
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

So presumably if I did them all in parallel, I'd put a resistor on each according to V=IR, taking their usual operating current and the voltage of the battery minus each LEDs operating voltage (not their max rated), and wire them all into a stripboard connected to a common positive and negative rail?

So that will make 28 resistors in the range of 190-720 Ohms.

If the currents are additive in parallel arrangements, that makes 430 mA. If a typical PP3 9V battery is 400-500 mAh as noted on Wikipedia, wouldn't that mean the lights would barely last an hour? Also, with such a high current, is there an issue with overheating in the common rails and battery leads? I'm new at this, so I'm probably being overcautious - I don't want my model to melt from the inside out :)

I have also tried grouping LEDs together into sets of like rated currents, with voltages not exceeding 9V, which results in 10 parallel sets of LEDs requiring 10 resistors between 50-250 Ohms, and should only draw a combined current of 180mA.

I'm not beyond making the thing run off a mains-powered supply. I think these might be adequate: http://www.maplin.co.uk/ac-dc-fixed-vol ... lies-48484. Might it then be better to go as far as 12V series chains? In theory would that not drop the current requirements even further? If the draw is 430mA (and bearing in mind I haven't even started plannning the blinking circuit), then the 9V 2.2A supply should be adequate, assuming that overheating isn't going to be a problem.

And yes I have heard of the white straw trick, and plan to implement it :)
ChrisQ
Posts: 142
Joined: Fri Jul 02, 2010 11:53 pm
Location: Baltimore, MD

Post by ChrisQ »

I have not done any computations for batteries. I modified an ATX power supply to put out 6V and I use it to power all the models.

I am watching this thread carefully now to see if I should start wiring in series where possible.
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

I've just done some more calculations:

Putting as many in series as possible, it should draw a total current of 180mA and the resistors will be soaking a total of 0.373 Watts of power.

With every LED in parallel, the circuit draws 430mA and the resistors soak a total of 2.7 Watts of power.

In neither configuration does any resistor exceed the 1/4 Watt limit that most resistors are rated to handle, but I think I'll try the series connection first.

Is there any way to work out how hot 2.7 Watts of thermal energy is? As it's being absorbed by resistors it's going to be given off as heat.
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

I've found an elegant implementation of daisy-chained 4017 decade timers at http://www.bowdenshobbycircuits.info and made some modifications to reproduce something that closely approximates Voyager's light sequences (despite the fact that they vary from CGI/physical model and from episode to episode).

Modified circuit diagram below:

Image

It just happens that the circuit's 555 timer should theoretically output at intervals of 0.208 seconds, which is perfect for this application.

In theory, the above circuit should:

Flash the 5 main lights for 0.2 seconds
Flash the under-hull light for 0.2 seconds
Flash the over-shuttlebay light for 0.2 seconds
Pause for 1.2 seconds
Flash the 5 main lights for 0.2 seconds
Flash the under-hull light for 0.2 seconds
Flash the over-shuttlebay light for 0.2 seconds, off for 0.2 seconds, on for 0.2 seconds
Pause for 0.8 seconds

Extending the 12V and GND rails out a little bit should enable me to connect the other LEDs in series/parallel blocks, and hopefully when the whole thing is prototyped the flashing lights won't adversely affect the brightness of the always-on lights...
Last edited by Magma on Sat Feb 18, 2012 9:42 am, edited 1 time in total.
vixr
Posts: 20
Joined: Thu Feb 02, 2012 9:52 pm
Location: North Florida

Post by vixr »

...can you post a schematic?
Last edited by vixr on Thu Feb 16, 2012 3:00 pm, edited 1 time in total.
my God...its full of stars
Ant
Posts: 521
Joined: Tue Nov 19, 2002 8:02 am
Location: Oxford UK
Contact:

Post by Ant »

A few helpful (hopefully!) comments

In 30+ years of hobby electronics, I've never had an LED die in a correctly configured circuit. As long as it's operating within its spec, spontaneous death is _extremely_ rare and not something you need to factor into assembly. What is more likely is death from incorrect operation, or simple mechanical failure (solder / wire breaks from movement)

My favoured power supply is 3 or 4 AA cells giving 4.5 or 6v at a much greater capacity than a PP3, and also at a much lower voltage, so you need to waste much less to get down to the LEDs forward voltage. (And remember that waste = heat. Nothing should ever get warm in a typical LED circuit).

If AA's still aren't enough and you have the space, move up to C cells.

A great current saving trick is to just underpower superbright LEDs - you can get the same brightness of a 200mcd led at 20mA from an 800mcd LED at 5mA. One thing to watch is that many superbright types have a very narrow angle of view, and you may be looking for a more diffused effect.
User avatar
MillenniumFalsehood
Posts: 17033
Joined: Tue Nov 16, 2004 5:23 pm
Location: Wichita, KS, USA
Contact:

Post by MillenniumFalsehood »

If you want to diffuse a superbright LED to get that effect, the simplest way is to rub sandpaper on the surface. You can also chuck it into a drill press and drill an indentation on the tip, which will act like a combination reflector/splitter and spread light to the sides while simultaneously letting light pass. You'll want to polish it up to get maximum brightness.
If a redhead works at a bakery, does that make him a gingerbread man?

Ponies defeat a Star Trek villain? Give them a Star Wars award ceremony!
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

Thanks for the tips - I've read about the sanding trick, and I read about the drillbit dimple trick in my father's latest model engineering magazine. I'll probably use sanding for the window lights (a 10mm white LED for the saucer, and another for engineering) and the dimple for the bussard collectors, depending on how the tests go. Interior compartments painted bright white should help with a bit of diffusion.

I couldn't find any white straws that weren't striped, but Tesco did have a big box of opaque straws in mixed colours, snug fit on 5mm LEDs. I have enough blue straws now to outfit all of Starfleet, and enough green ones to kit out the Romulans too If I so wished.

Parts ordered now, so I should be able to prototype the circuit in a few weeks and see if it works. If not, I may have to fall back on a simpler sequence using just one 4017 or even just a 555 timer circuit slightly rewired to give a <50% duty cycle.
Dezmond76
Posts: 9
Joined: Thu Oct 27, 2011 6:59 am

Post by Dezmond76 »

Hello.
I suggest to use diodes to avoid a short circuit situation between outputs like in this circuit:
Image
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

I think you're probably right on that one - Although it seems the primary reason for the diodes in the above application is to ensure the LEDs switch on correctly to form the right pattern of lights for a die roll (I assume from the general appearance that it is an electronic d6), I have looked over some other diagrams such as the traffic lights on http://www.doctronics.co.uk/4017.htm and they do indeed have diodes on every output.

Blast. I've already ordered and received everything else. There goes my free postage on orders over £30 then.

So basically I need to get 7 more 1N914/1N4148 diodes (I understand that they are basically the same thing). They're pretty cheap, so it all comes down to whichever out of Maplins or Rapidonline has the lowest postage...

EDIT:

...or maybe not. Turns out that the diodes cost so much more from Maplins, that if you are buying more than 5 then it's more expensive from them, even though they have £2 cheaper postage.

I've gone for 20 of them, so I'll have a good excess. I think I'll put one on each parallel LED run to make sure there's no chance of reverse polarity damage.

New circuit diagram showing diode positioning:

Image
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

Today is a nice day of firsts. I have made an LED light up, then made an LED flash through the output of the 555 timer, then after a lot of headscratching and translating of plans into the real world, managed to do this:

http://www.youtube.com/watch?v=44bguq7xMzE

The strobe circuit works flawlessly.

I have 1 jump lead left. I need to get a few more before I can test if the circuit plays nicely with the always-on lights in parallel to it.
Dezmond76
Posts: 9
Joined: Thu Oct 27, 2011 6:59 am

Post by Dezmond76 »

Will you make the green and red nav lights blink?
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

No. I've seen a number of models that do this, but I've been watching the TV series and at no point that I'm aware of do any lights other than the white ones blink (except when the ship is intermittently losing power). I'm halfway through Season 4 at the moment, speeding through the episodes that are light on action and heavy on dialogue.

I've received my other jumper leads and connected the always-on LEDs. I've made made nine series chains of forward-current-matched LEDs, where the total forward voltage of the LEDs in each chain is not allowed to exceed the supply of 12V, and with a resistor in series of appropriate resistance and power dissipation. These chains are connected in parallel to the connectors supplying power to the blinking circuit. Everything works. I've left it running for 8 hours and it was working when I came back. The blinking lights do not visibly affect the stability of the always-on lights.

I may need to get more white LEDs to light the inside bright enough, because I don't think one 10mm LED for the saucer and one for the engineering section will be good enough. Even sanded down to diffuse them a bit, there's not enough side-scatter to do the job evenly. I'll probably have 2 in each arranged in an X pattern so the light is more evenly distributed. I'll put a perspex oblong into the fantail to act as a light pipe to take light from the engineering section and illuminate the rear observation window. I'm only using 280mA of the 1000mA that the AC supply can provide, so there's plenty of extra capacity to add more chains in parallel where necessary.
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

Well this is a pain. I've built the circuit in Fritzing (A great open-source circuit design program I've found) but it seems there is no way to put it on single-sided PCB without at least 7 unconnectable broken links (and a dizzying number of jumper wires to boot).

It can be made quite compact on a double-sided PCB, but that's going to be more complicated to make myself - I may need to get it done professionally which doesn't look like it's going to cost much less than £50.
User avatar
Mr. Engineer
Posts: 440
Joined: Mon Dec 10, 2007 6:01 am
Location: Malaysia
Contact:

Post by Mr. Engineer »

Just saw your video and I am very confident it can be done in in a single side PCB. If you want, you can email me your circuit and I try them on the Eagle software, but please do give me the measurement on how big/small you want your board to . I just want to keep my mind 'busy' since I am out of job recently.

I have not explored this since my Voyager Kit was eaten by termites in '05 (a polythene bag with lots of mushy gunk inside, like holding a dead cat by its skin)

Right now, I am taking a break from soldering all the wires for my Board, which I intent to sell soon.

http://www.youtube.com/watch?v=W0siMtg10vM
What can I take apart today?

https://www.facebook.com/PisceanWorks
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

The circuit schematic is identical to the above colour-coded diagram I posted earlier (the one that also appears in the youtube clip). The only modification is the addition of 8 connectors that tie directly into the +12V and GND lines so the always-on lights can be attached in parallel.

Unfortunately the Fritzing program doesn't seem to have any easy way to transfer schematic designs to Eagle. I've had a tinker with Eagle and I have to say it is a lot harder to use than Fritzing. When I finally found how to unhide IC pins with the Invoke command, I managed to construct half the circuit (without the transistors and LED outputs) but even Eagle could only manage 86% single-layer routing after the final round.

Here is an image of what Fritzing has routed on a 2-layer PCB.

Image

I've tried to optimise it by keeping the output diodes and LEDs grouped in the order of the transistors they are connected to, and that keeps clutter away down that end. However, the maze of overlapping connections between the 4017s and the diode logic gates are what are creating the biggest problem.

I'm aiming for <12cm in length and <6cm in width so I can tack it under the big flat plate on the lower saucer section where it won't be seen. This will also have the added advantage that I can put the power connector in the bottom of the hull and route the power supply plug up into the display stand to make it deconstructible and easily flat-packed in a storage box. Any bigger than that and I'm going to have to make a bigger display stand to hide it in.
User avatar
Mr. Engineer
Posts: 440
Joined: Mon Dec 10, 2007 6:01 am
Location: Malaysia
Contact:

Post by Mr. Engineer »

Hi,

OK, 12cm by 6cm is a good start. I will try to make the board as small as possible without having to go into SMD, and you can use the eagle software to resize it to your own 12cm by 6cm later on.

Unfortunately, I cannot see the image you posted. So, can I use that circuit in YouTube? Its going to take some time because I need to go out to buy the component and to reconstruct the circuit from my side to make sure its working before I do the design.
What can I take apart today?

https://www.facebook.com/PisceanWorks
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

Yes, it's the same. I've uploaded it here for the time being. You should be able to grab it from there hopefully.

I used 0.4W resistors all round but really I only needed them on the LEDs because of the voltage drop needed. The LEDs were 3mm daylight-white to match the ship. I haven't labelled the transistors, which were 2N3904 NPN type. I've also not put on the extra rails to accomodate the 8 parallel chains of always-on lights because at the time I did not know for sure that the blinking would not interfere with the stability of the other lights.

If you're under financial constraints at the moment, please don't get the materials for prototyping for my benefit. I wouldn't want to make your life more difficult for my own personal convenience. If you plan to build it as a proof of concept to use for your own purposes as well, then that's perfectly fine by me but I can afford to pay a company to get this professionally etched and drilled if absolutely necessary. Fritzing seems to be better than most with a cost of about £40 for the double-layered PCB, as they charge by the square centimetre and are set up to process individual PCBs for the hobbyist.
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

I think I've solved it. Turns out autorouting is no substitute for sitting down for 4 hours and meticulously repositioning components to weave the tracks around each other.

I needed to use 10 jumpers, but they are all in sensible places and I've got the PCB down to 10cm x 6cm. Single sided.

Image

Next job is to print that out and check every connection between components matches the theoretical layout. If that works, I have the facilities to photoetch the thing now I don't have the added difficulty of having to align two layers.
User avatar
Mr. Engineer
Posts: 440
Joined: Mon Dec 10, 2007 6:01 am
Location: Malaysia
Contact:

Post by Mr. Engineer »

OK, based on your circuit, I have done the board using the free Eagle software but did not test it on my prototype board as I don't have the 4017 and the 2N2904 transistors during the weekend. The final size of the single-sided PCB is 8cm x 5.7cm but you need to solder two wire links:

1. Pin 14 of the first 4017
2. Pins15 for the both 4017 ICs.

I have also put in the tracks for the 8 parallel LEDs that needs to be constantly lit. But this cannot be connected to the output of a 12volt voltage regulator (If you wish to put one in, that is)

You can see the board here. Please PM me your email and I will send the Eagle file to you so you can continue/modify it further. But you must also check the design manually since I do not use auto-routing.

http://2.bp.blogspot.com/-_qBtQgcWJBI/T ... %2BCCT.png[/url]
What can I take apart today?

https://www.facebook.com/PisceanWorks
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

That certainly looks like a more efficient organisation than my second attempt. I've traced the PCB against the layout diagram and it looks perfect except for one positioning error where the anode track supplying the three transistors' collectors shorts against the cathode legs of the LEDs below it, but it looks like there's space enough for it to be dragged down a bit and out of the way.

I feel that Fritzing is a lot more intuitive for the novice (i.e. me) to use than Eagle - the breadboard construction system does seem like a more practical top-down approach and you can actually see all the libraries organised into sensible categories. However it does not seem to support routing between IC legs for some reason. I think if it did, it might not generate so many untraceable connections. It is still technically in Beta though so I suppose there's room for improvement. I've got Eagle installed still, so I'll try and figure it out.

By voltage regulator, do you mean one of those 3-pin ICs with the heatsink on the back? I'm using an AC to DC adapter with a constant-voltage regulated 12V output. Presumably there is a difference between having a voltage regulator on the PCB and having a regulated power supply? Everything seems to work fine powered from it. What damage would a voltage regulator do?
User avatar
Mr. Engineer
Posts: 440
Joined: Mon Dec 10, 2007 6:01 am
Location: Malaysia
Contact:

Post by Mr. Engineer »

Well, if you're using a AC-DC adapter with a regulated output, it should be OK. The 555 and CMOS IC use powers from 4.5v DC to about 15V DC.

This is a tough question as personally, I always prefer a Voltage regulator in the circuit just for the silly excuse of "In case I plugged in the wrong DC voltage". But actually, its because I need exactly 5 volts for my PIC microcontrollers. So, the habit tends to flow over to my other designs.
What can I take apart today?

https://www.facebook.com/PisceanWorks
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

Just watched "Waking Moments" from season 4, and one scene showed the ship with the red/green navigation lights on the nacelles blinking...

The other 4 red/green lights are permanently on, but for the sake of one scene which is unsupported by any other scene in the episode (or the last 3 seasons), I'm not changing anything. Too late, Voyager - this lighting circuit is planned and ready to make :)
User avatar
Mr. Engineer
Posts: 440
Joined: Mon Dec 10, 2007 6:01 am
Location: Malaysia
Contact:

Post by Mr. Engineer »

It is these kinds of 'things' which convince me to go into the microcontroller path even though I am still a beginner in that area. The chip would allow me the flexibility to reprogram or change the sequence without having the need to get more components.

But for your case, just like me in the beginning, this is the first step to electronics design....

Anyway, will be watching your Voyager progress. She's going to be a beauty! :)
What can I take apart today?

https://www.facebook.com/PisceanWorks
Magma
Posts: 17
Joined: Mon Feb 13, 2012 5:30 am

Post by Magma »

Actually, a little bit of rewiring and I can have those flashing as well. The nacelle navigation lights can be wired onto the same line as the ventral flashing light and the navigation lights will flash immediately after the main 5 strobes. This is exactly the behaviour of the "new" pattern displayed on the physical model prop, which I have seen a couple of times in the next few episodes.

By the way, I did try simply swapping the ventral light and the nacelle lights so the latter strobed and the former was always on (Which it is often in the show) - But as I suspected the resistor on the ventral light started getting pretty damn hot. I could patch the ventral light into another rail with spare voltage, but I think just patching the nacelle lights in to flash as well is the best overall thing to do.

After all, if the creators of the show can change their mind at a whim, why can't I? :P
Post Reply