A very simple LED question

Discussion in 'Other Electronic Interfaces' started by York Paul, Mar 7, 2021.

  1. York Paul

    York Paul Staff Member Moderator

    Messages:
    5,827
    Likes Received:
    6,909
    Joined:
    Aug 20, 2017
    As it says I need a bit of advice concerning where to put the resistor on a red / white LED, its simple to some folk here but not me as I've very little experience or should I say no experience when it comes to duel LED applications. These are 3mm from DCC and will be fitted to my Eastbuild parcels unit... basically the plan is for two white lights illuminated when going forward with one red showing at the rear, then the same again when the unit is running in t'other direction. I also have the plain DCC Prototype White LEDs without the red.

    So my question is on the red /white LED which prong does the resistor go on ? and can some kind person draw me a very basic simple to understand diagram which I can work from please?


    [​IMG]

    For running in testing the Cravens Parcel unit will be provisionally fitted as DC but when run in converted to DCC and a sound chip added.
     
  2. Walkingthedog

    Walkingthedog Full Member

    Messages:
    991
    Likes Received:
    1,001
    Joined:
    Jul 30, 2020
    Resistor goes on the middle longer common positive 'prong'.
     
    York Paul likes this.
  3. gormo

    gormo Staff Member Administrator

    Messages:
    6,036
    Likes Received:
    4,245
    Joined:
    Dec 5, 2015
    G`day Paul,
    Have not used these, but the obvious choice is the long one in the centre. As the resistor will need to be common in order to operate either red or white, the centre leg would be the logical choice. LED`s have a simple logic to them whereby the longer leg will always be the positive and the shorter leg will be the negative. In this case you will have one positive and two negatives.
    I am replying remotely at the moment so it is difficult to supply diagrams etc.......however the other two legs, right and left of centre will feed either the white or the red.
    If you can connect a suitable resistor to the centre leg and a temporary feed to one or other of the other legs you will be able to determine which leg feeds what colour.
    You will notice the other two legs have different length legs in order to help identify them.
    Hope this helps
    Cheers Gormo
     
    York Paul likes this.
  4. Keith M

    Keith M Staff Member Moderator

    Messages:
    4,460
    Likes Received:
    2,911
    Joined:
    Dec 16, 2015
    You will need a resistor for each LED Paul, as stated connected in line (series) with the centre connection of the three wires on the LED. All 4 of your LED centre connections will be 'commoned' via resistors together to the Blue output wire of the Decoder. When you've ascertained which is the White wire for the forward end LED's, connect the 2 to the White output wire of the decoder, together with your choice of which Red rear LED connection.
    Then conversely at the rear end, the 2 White LED connections and your choice of which Red LED connection at the front go to the Yellow decoder output wire. A 1k (1000 ohm) resistor gives what is probably a bit too bright illumination but that's an individual choice, you might try a 2k (or 2x1k in series so you'll need 8 in total). If you are unsure about connecting a decoder, it's safer (and cheaper) to wire in a basic non-sound decoder first as a trial, better to knacker a cheapo £10 LaisDCC one than a £100 ESU or Zimo.
    Unfortunately I have no idea how to draw a diagram on a computer (I use an iMac anyway), hopefully someone will come along and help out.
    Best to use a 1.5 volt battery (AA or similar) to test the LED connections, no more than 3 volts though otherwise you'll knacker it. Keith.
     
    Andy_Sollis likes this.
  5. York Paul

    York Paul Staff Member Moderator

    Messages:
    5,827
    Likes Received:
    6,909
    Joined:
    Aug 20, 2017
    Thanks for all the advice chaps... I'll have a crack experimenting.:thumbs:
     
    Andy_Sollis likes this.
  6. Andy_Sollis

    Andy_Sollis Staff Member Moderator

    Messages:
    3,957
    Likes Received:
    3,743
    Joined:
    Aug 4, 2018
    The decoder will send a DC signal back to the motor and LED’s, so you have no need to worry about DCC as such.

    I know you asked me a while back and never came back to you.
    How do you want it to work?
    Headlights on and tail at other
    Do you want an option for reds on at both ends? (When parked up)

    DCC decoders have a number of options on functions, so will vary.
    8 pin plugs can often have 9 wires (one is loose as goes to lights.

    Red and Black go to track (pickup)
    Orange and grey go the other way (motor)
    Green, yellow, white and blue are for lights and purple will be the ninth wire. (I need to look which is the return wire for lights - I think it’s blue off the top of my head)
    53465921-0791-4316-BE9D-35EB871882BB.png

    What I’m concerned about is that blue is the common.. I can’t remember which way round the power goes and will have to test one. Normally we would put the commons together, but with the LED you have it may cause issues as the pos and neg are reversed as such.
     
    York Paul likes this.
  7. paul_l

    paul_l Staff Member Administrator

    Messages:
    9,866
    Likes Received:
    5,929
    Joined:
    Dec 5, 2015
    Blue is a common positive.

    You will need to run a Yellow, White and blue wire to both ends.

    Connect a 1K resistor minimum to one leg of each LED - It doesn't really matter as you are doing this for ALL LEDs. The 3 pin connect a resistor to the 2 outer legs.

    Front end

    Connect White wire to the Short leg of the White LED
    Connect Yellow wire to the Short leg of the Red LED
    Connect Blue wire the Long leg of all the LEDs

    Rear end

    Connect White wire to the Short leg of the Red LED
    Connect Yellow wire to the Short leg of the White LED
    Connect Blue wire the Long leg of all the LEDs

    The way the 2 to 4 Function DCC decoders work (Andy's diagram above shows a 3 Function decoder F1, Front and Rear lights- an 8 pin 4 function decoder will have an additional purple unterminated wire).
    When you turn the lights on, depending on the direction of travel the decoder will activate one of the Light outputs. So if you are travelling forward, the Front Light - White will be active, and the Rear Light - Yellow will be off. When you change direction they will swap over.

    There are decoders with more functions available, and are often used to independantly switch off the Red LED, useful if you have a loco pulling stock, you don't want the loco rear lamp on. A little bit of fiddling and F1 &/or F4 couuld be used to do this.

    Now onto the 1K resistor, depends if you want to photograph the loco.
    Human eyes are very good at dimming down the LED brightness, camera's on the other hand don't and will give very bright burnt out images in this case a 10K or even 100K resistor look far better.
    I tend to use 10K as a comprimise value.

    Paul
     
    Andy_Sollis likes this.
  8. York Paul

    York Paul Staff Member Moderator

    Messages:
    5,827
    Likes Received:
    6,909
    Joined:
    Aug 20, 2017
    Thanks for the wiring picture Mr S and the circuit info Paul... sorry about the late reply as the old body here has had to take a few days rest from work... knees and joints playing up in cold weather.

    Now another couple of questions if may... which wire size is best to use and also you mention about "the two 4 function decoders"... so do I need two decoders one for each direction and which is a good make to buy? Also can I for now test run the DPU with decoders fitted using my current DC set up ?

    As you see this is a whole new entry level for me and again chaps thanks to all for the guidance and info.

    cheers Yorkie
     
    Andy_Sollis likes this.
  9. paul_l

    paul_l Staff Member Administrator

    Messages:
    9,866
    Likes Received:
    5,929
    Joined:
    Dec 5, 2015
    Hi Paul

    2 to 4 function decoders not two 4 function decoders.

    2 Function decoder
    Pin 6 -Function 1 - White wire - Direction Forward - Front Light
    Pin 2 -Function 2 - Yellow wire - Direction Reverse - Rear Light
    Pin 3 - Not connected


    3 Function decoder
    Pin 6 -Function 1 - White wire - Direction Forward - Front Light
    Pin 2 -Function 2 - Yellow wire - Direction Reverse - Rear Light
    Pin 3 -Function 3 - Green wire - Accessory Function 1 e.g. interior lights or boiler flicker


    4 Function decoder
    Pin 6 -Function 1 - White wire - Direction Forward - Front Light
    Pin 2 -Function 2 - Yellow wire - Direction Reverse - Rear Light
    Pin 3 -Function 3 - Green wire - Accessory Function 1 e.g. interior lights or boiler flicker
    No connection Function 4 - - Purple wire - Accessory Function 2

    The Lais decoders will give a good start, cheap and smallish and will easily provide 1A. Choose the 4 function decoders as that will give the most flexibility - you don't have to use all the functions. Get the one with the 8 Pin harness (you'll probably cut if off anyway)

    Ebay Lais 4t Func decoder link


    [​IMG]

    Note the Black and Blue wires comming out of the right hand side are for stay alives - basically an additional high capacity capacitor and resistor to help the loco over dead sections/ dirty track etc. The spare purple wire is function number 4.

    Wire size - for the Red, Orange, Black & Grey wires (Track feed and motor wires) I use 24 AWG flexible silicon wires. The others I tend to use either the 24 AWG silicon wire or multistrand Phone cable.

    Paul
     
    Rob Pulham, Andy_Sollis and York Paul like this.
  10. paul_l

    paul_l Staff Member Administrator

    Messages:
    9,866
    Likes Received:
    5,929
    Joined:
    Dec 5, 2015
    PS once you have the decoder, we'll have a chat on installation and setup, not difficult, but can be a little daunting.

    Paul
     
    York Paul likes this.
  11. Keith M

    Keith M Staff Member Moderator

    Messages:
    4,460
    Likes Received:
    2,911
    Joined:
    Dec 16, 2015
    If you need more amps than the LaisDCC decoders can handle, then 'Rails' have recently started supplying their 'own-brand' decoders (rebranded from DCC Supplies I believe), and one of these can handle up to 3 amps, not as cheap as the Lais ones but probably a good alternative. Even if you are going for sound, it's advisable to try a non-sound decoder first rather than risk damaging an expensive sound decoder, then if all is well, just swap it over. It's handy having a 'spare' anyway just for testing purposes, but I'd advise 'running-in' the motor/gearbox for half an hour in each direction on DC anyway to bed things in, then do a stall test for maximum current check before fitting a decoder.
    Keith.
     
    Rob Pulham, Andy_Sollis and York Paul like this.
  12. York Paul

    York Paul Staff Member Moderator

    Messages:
    5,827
    Likes Received:
    6,909
    Joined:
    Aug 20, 2017
    Thanks for the clarification Paul and Keith, yes I see a way forward now, the motor bogie has been well run in and is very very quite on the test bed, lift the motor bogie off the cradle and the wheels carry on rotation for a few seconds... so I'm happy there. I'll get an amp meter to measure stall current and buy a Lais for starters so thanks for the link Paul. To update the only thing preventing me completing the DPU is the mark light LEDs, once they are in and fitted I can build the cab desks and bulkheads then glaze the unit and fit the windscreen wipers... put it all back together and hopefully job done and learnt a new skill.:thumbup::cheers:
     
    Andy_Sollis likes this.
  13. York Paul

    York Paul Staff Member Moderator

    Messages:
    5,827
    Likes Received:
    6,909
    Joined:
    Aug 20, 2017
    I've just purchased the decoder with stay alive from said supplier in Yarmouth so will wait for that to arrive. Keith this can be the test decoder for my builds and a replacement for sound can come next... I don't want things stalling abruptly when the Leek layout goes out on show.:D
     
    Andy_Sollis likes this.
  14. Keith M

    Keith M Staff Member Moderator

    Messages:
    4,460
    Likes Received:
    2,911
    Joined:
    Dec 16, 2015
    Hi Paul.
    The Yarmouth supplier is my 'supplier of choice' too, The 8 pin Lais is ok for up to 1 amp motor current and i think short term about 2, slightly less if lighting is in use, so ok at least for setting up prior to sound fitting for most lighter current applications. Just ordered one myself for testing the '02' on DCC as when I ordered the 21 pin for the Terrier, he was out of stock of the 8 pin ones, supply from China must be getting tight I guess. Let us know how you get on with it.
    Keith.
     
    jakesdad13, Andy_Sollis and York Paul like this.
  15. Keith M

    Keith M Staff Member Moderator

    Messages:
    4,460
    Likes Received:
    2,911
    Joined:
    Dec 16, 2015
    Forgot to mention, if you go online to laisdcc.com you'll find a 19 page manual which will answer more or less all you ever want to know about laisdcc decoders.
    Keith.
     
    jakesdad13 and Andy_Sollis like this.
  16. Andy_Sollis

    Andy_Sollis Staff Member Moderator

    Messages:
    3,957
    Likes Received:
    3,743
    Joined:
    Aug 4, 2018
    Of course, when it comes to the sound chip, you may need a harness.. as the pins “male and female” are the opposite to an 8 pin one. The 21 pin will obviously carry more functions, so not only could you change the head and tail
    Lights, you could probably have a cab light or interior lights too.
     
  17. Keith M

    Keith M Staff Member Moderator

    Messages:
    4,460
    Likes Received:
    2,911
    Joined:
    Dec 16, 2015
    Lais 21 pin are 6 function if I remember rightly Andy. They've gone up in price slightly (hasn't everything?) but still best value as far as I'm concerned.
    Keith.
     
    Andy_Sollis likes this.
  18. Colin_W

    Colin_W Full Member

    Messages:
    230
    Likes Received:
    95
    Joined:
    Nov 19, 2016
    Hi Paul, quickie pic for you. Make sure the LED Resistors are at least 1k and possibly more to start with. It may be prudent to put a 1k in between the 'A' (anode) and the blue wire but I think it should be ok as it is. I'm sure Paul L will let us know :lol:.
    Lights.JPG
     
    York Paul likes this.
  19. York Paul

    York Paul Staff Member Moderator

    Messages:
    5,827
    Likes Received:
    6,909
    Joined:
    Aug 20, 2017
    Hi Colin and thank you for the wiring diagram which is very helpful to a non-lectrcal numpty like be... I see it clearly now.:thumbup:
     
  20. York Paul

    York Paul Staff Member Moderator

    Messages:
    5,827
    Likes Received:
    6,909
    Joined:
    Aug 20, 2017
    Another simple question to ask if I may please. The decoder arrived this morning and I was wondering what type of plug on terminal connectors would I need to couple to the prongs on the decoder ?


    [​IMG]
     

Share This Page