Jump to content

Automatic Coach lighting


am549

Recommended Posts

I know that Train Tech have their own automatic coach lighting kit but I'm wondering how possible it would be to make my own as their a little on the expensive side by the time you've kitted out a few sets of coaches...

I've been looking at the set Layouts 4 u make and wonder whether it's possible to swap the reed switch for a vibration sensor instead (something like this https://www.adafruit.com/product/1766). Admittedly it won't stay on when there's no movement (perhaps a capacitor of some description can keep it on or some sort of timing chip?) but would it work just swapping out the reed switch?

Link to comment
Share on other sites

There are a number of options for coach lighting. I have a carriage with the lighting kit, which may have come from Layouts4U - this consists of a strip of LED lights stuck to the carriage roof, with a latching reed switch between the lights and a button battery - operated by waving a magnet over the carriage roof. It works well, as I placed a strong magnet inside the tunnel portal leading from the fiddle yard - trains leaves, lights come on, when it returns they are turned off. This system is very similar to the Hornby Magnalight.

forum_image_626ab109c6d6f.thumb.png.3b291450ad8c93a35563c8f8b8a5b175.png


Another option is to place a similar strip of LED lights inside on the carriage roof, and run a pair of wires, via a resistor, through the bogie, to wheel contacts (DCC Concepts), these also work well, but running DCC, the lights are on all of the time.

forum_image_626ab11542e56.thumb.png.602decf2fdc96461a4a93d91a37ff71a.png

Link to comment
Share on other sites

I did some coach lighting experiments a few years ago using a three cell rechargeable NiCad battery mounted at the end of the coach near the door. This was only 3.6V so the LEDs, each with a series dropper resistor, were connected in parallel. The battery was recharged via contacts on the coach wheels. On and off switching was totally electronic using a bi-directional Hall effect switch to latch a set-reset flip-flop. This was activated by an electromagnet on an overhead gantry whose polarity could be reversed to switch the lights on and off.

The capacity of the battery was only 80 mAh so the lights wouldn't last long if there was no power on the track. Nowadays I would use a lithium battery which provides 3.7 V from a single cell and is available in much higher capacities and a variety of shapes, some probably thin enough to fit under the coach.

Additional info. I've found some flat rectangular batteries on a well-known auction site that come in a variety of sizes, shapes and capacities. These have a built in charger circuit which is important as the charging regime is more complicated for lithium batteries than for NiCad.

Link to comment
Share on other sites

Think I might have to do some experiments with the movement sensors to see if they work, unless a hall sensor would work off the track being live?

Quite liked the idea of the lights coming on as soon as the trains start moving and something easily installed into the carriage without drilling holes etc for contacts. Had spotted those vibration sensors also on a well known auction site and thought might just be able to swap one for a reed switch

Link to comment
Share on other sites

I'm not quite sure what you mean by ..."unless a hall sensor would work off the track being live?"

Hall effect sensors of course detect magnetic fields. The type I used was a linear sensor, which has an output voltage of around half supply voltage when just in the earth's magnetic field. When one face of the sensor is placed near the north pole of a magnet the output voltage will increase, when the south pole of a magnet is placed near the same face of the sensor the output voltage will decrease. The output of the Hall effect sensor is connected to a voltage comparator that can sense the increase or decrease in the Hall effect sensor output and turn the lights on or off accordingly. This is how I could turn the lights on or off by reversing the polarity of the activating electromagnet on the gantry.

Link to comment
Share on other sites

For some reason I had in my head that current passing through a circuit would produce enough of a field to turn the lights on/off with a hall sensor.

Might need to buy a TT kit to see what they're using to detect motion, it's not massively clear from the product images what sort of sensor is being used but judging by the price I suspect something akin to what's in a mobile phone.

It seems trying to do something on the cheap isn't going to be possible.

I wonder if a mercury switch would work

Link to comment
Share on other sites

I don't think it is going to be possible to make an effective coach lighting system without using electronics, but that doesn't mean that electronics have to be expensive.

Firstly let me raise two points:

  1. I'm not sure why you want motion sensing. Surely you want the coach lights to be on when the coach is in use, whether it is moving or not?
  2. I know almost zero about DCC. I don't use it because of the expense and because there is no way of interfacing it with the electronics that I want to put into my layout. However, if you are using DCC I believe there are accessory decoders that can presumably switch things such as coach lighting on and off.

I've attached a diagram of the coach lighting circuit I designed. Unfortunately for various reasons this never got beyond the prototype stage on Veroboard, but using surface mount components it should fit on a very small PCB.forum_image_626bb69f10f89.thumb.png.87aa378132826ff6e78034a1e6843833.png

Power from the track is rectified and smoothed by C1, and used to charge battery BY1. The circuit will operate without power with lights off for about 40 hrs, and a time dependent on the number of LEDs used when the lights are on. An isolating switch is provided to switch the circuit off completely for long periods of non-use.

The lights are switched on by bringing a magnet close to the hall-effect sensor, or switched off by reversing the polarity of the magnet (or an electromagnet buried in the track could be used). The output of the sensor is nominally half supply voltage when exposed only to the earth's magnetic field. When it detects a larger magnetic field the output will rise or fall depending on the magnet polarity.

Op-amp IC1 is used as a voltage comparator. When the output of the sensor rises. the output of the op-amp will go low. When the output of the sensor falls the output of the op-amp will go high. To prevent the comparator output responding to small changes in magnetic field, positive feedback or hysteresis is provided via R4. The output of IC1 drives the gate of a MOSFET that switches the LEDs on or off. 

Link to comment
Share on other sites

I had a look at the Train Tech coach lighting and have the following comments:

  1. It doesn't use a rechargeable battery but a CR2032 3V lithium coin cell, so it doesn't need pickups on the coach wheels.
  2. Good quality CR2032s cost over £1 each.
  3. CR2032s are typically rated at 200 to 250 mAh but typically this is tested with a load of 15k Ohms or a current of only 200 microamps. The LEDs in coach lighting will take several milliamps and the life will be much less, so you will be looking at quite a large ongoing outlay in batteries if you have a lot of coaches.
  4. You will presumably need to dismantle the coach to change the batteries.


Link to comment
Share on other sites

I guess the main thing was (trying) to do as little damage/modifications to the rolling stock as possible to get the lighting in (which is why the train-tech/layouts4u kits were so appealing) as they're completely isolated and just run off a battery.

The automatically coming on/off means not forgetting to go round all the coaches after a session and manually having to switch them off and stopping in stations etc could have been mitigated with a capacitor/timer of some description.

I am running DCC but am at a stage where I don't want to be soldering decoders etc, which was the other appeal of the isolated battery kits so having a little project to practice soldering and learn the electronics side of things before going onto more complex things was another factor.

I guess I had though it was a simple swap of one type of switch for another initially but it does seem to be a tad more complex than I thought

Link to comment
Share on other sites

On the Hornby Maglight system, which uses a CR2032 or something very similar, Hornby say the battery should last for 200 hours - that is of course not with the lights on all of the time.

You do not have to do much "butchering" to your carriages when using (in my case) DCC Concepts wheel contacts, in fact no major surgery is required at all. Once you have got the carriage apart, you have the chassis, body and seating. I found with a Maunsell carriage that I was able to drill a small hole through the mounting spigot on one bogie, with a corresponding hole in the floor of the seating unit, and then run two wires from the wheel contacts to the self-adhesive strip of LED lights stuck to the carriage roof. The power pick-up was superglued to the bogie - needs some black paint.

The picture shows the DCC Concepts power pickups, stuck to the bogie. There is no noticeable drag on the wheels - my Hornby M7 pulls two coaches, both fitted with this power pick-up arrangement.

forum_image_626be24dcd5fe.thumb.png.613144a0a7f8a313491e1c5f2f951249.png

Link to comment
Share on other sites

If you are operating with DCC then the best solution would be a DCC accessory decoder. This would of course require an actual DCC command rather than the lights coming on automatically. However you wouldn't need a battery and there would be no need to change batteries. It would, however require contacts to the coach wheels.

If you still want a home-made system with no connection to the track and where the lights come on when the coach moves then you will need a system that detects acceleration and deceleration. I won't call this "motion sensing" because you can't detect motion at a constant speed.

Accelerometers exist but they are relatively expensive. The simplest solution would be to use a tilt switch. These are devices that make contact when tilted through a small angle. There is a wide variety of these but the most suitable would be one that makes contact when tilted from the vertical. This could be mounted on a vertical piece of piano wire so that when the carriage accelerated, declerated or went round corners it would tilt. If you are good at metalwork you could also make your own acceleration switch consisting of a ball bearing in a shallow bowl with a metal ring around the outside. When the coach changes speed the ball will roll to the edge of the bowl and make contact between the bowl and the ring. Of course the lights might come on when the coach is going up or down hill, but as you want them on that shouldn't be a problem.

Of course when the coach stops accelerating the switch will open so you still need some electronics to keep the lights on. This could consist of a 555 analogue timer, triggered by the closing of the tilt switch that can be set to time any required period, determined by an external resistor and capacitor. I've attached a typical circuit in block form but haven't shown the actual timing components for the 555. forum_image_626bfd03955d5.thumb.png.c06c17ecfc83ecce0aee0b26fa20d6ce.png


Moderators note - when you submit a post with an image it queues for release by a moderator. This action is notified to you by a flag at the top of screen. You may wish to use the three dot context menu to delete your many duplicate posts and save us the task.

Link to comment
Share on other sites

If you are operating with DCC then the best solution would be a DCC accessory decoder. This would of course require an actual DCC command rather than the lights coming on automatically. However you wouldn't need a battery and there would be no need to change batteries. It would, however require contacts to the coach wheels.
If you still want a home-made system with no connection to the track and where the lights come on when the coach moves then you will need a system that detects acceleration and deceleration. I won't call this "motion sensing" because you can't detect motion at a constant speed.
Accelerometers exist but they are relatively expensive. The simplest solution would be to use a tilt switch. These are devices that make contact when tilted through a small angle. There is a wide variety of these but the most suitable would be one that makes contact when tilted from the vertical. This could be mounted on a vertical piece of piano wire so that when the carriage accelerated, declerated or went round corners it would tilt. If you are good at metalwork you could also make your own acceleration switch consisting of a ball bearing in a shallow bowl with a metal ring around the outside. When the coach changes speed the ball will roll to the edge of the bowl and make contact between the bowl and the ring. Of course the lights might come on when the coach is going up or down hill, but as you want them on that shouldn't be a problem.
Of course when the coach stops accelerating the switch will open so you still need some electronics to keep the lights on. This could consist of a 555 analogue timer, triggered by the closing of the tilt switch that can be set to time any required period, determined by an external resistor and capacitor. I've attached a typical circuit in block form but haven't shown the actual timing components for the 555. forum_image_626bfd03955d5.thumb.png.a2b06c3c790489178ac48458ac495b22.png

Moderators note - when you submit a post with an image it queues for release by a moderator. This action is notified to you by a flag at the top of screen. You may wish to use the three dot context menu to delete your many duplicate posts and save us the task.

 

 

Link to comment
Share on other sites

I've had some thoughts as to how you could make an automatic coach light system without any electronics (meaning active devices such as transistor, integrated circuits).

Firstly, for the acceleration/deceleration switch I suggest a home-made pendulum switch as shown in the diagram (I've not been able to find any suitable off-the shelf ones so far). This consists of a steel wire with a weight on the end, inside a brass tube. When the loco accelerates, decelerates, goes round corners or generally rocks around the weight will swing to one side and the wire will contact the tube. The dimensions of the tube will have to be worked out by experimenting but as a starting point I suggest a brass tube about 25 mm long and 2mm internal diameter, a piece of steel piano wire about 0.5 mm diameter and a brass weight about 4 mm long by 5 mm diameter.

The circuit is very simple. When the switch makes contact it will connect the battery to a 2 Farad supercapacitor. R1 limits the inrush current to avoid eroding the switch contacts. This capacitor should hold enough charge to keep the LEDs lit for up to 2 minutes when the switch is open.

CR2032 specs indicate that the maximum continuous current these cells can supply is around 6 mA, so I have chosen the LED series resistors to draw a total maximum current of around 5 mA using white LEDs with a forward voltage of 2.7 V. Other LEDs may need different value resistors. I don't know how many coin cells commercial coach lighting systems use, but I have shown two in series because with a single cell the battery voltage would only have to drop 300mV before the LEDs went out.

If there is room under the coach chassis I would suggest mounting the batteries there in holders to avoid having to dismantle the coach to change batteries.

I am now out of ideas for automatic coach lighting but am happy to answer any questions people may have.

forum_image_626d23e56e18d.thumb.png.04ba18f76111982d207a8481ead2e5cf.png

Link to comment
Share on other sites

Additional. Off-the-shelf pendulum and trembler switches can be found under "vibration sensors" - should have thought of that before. There is a huge variety of them so cannot advise which would be suitable. Something that is small, fairly sensitive but will not make contact if the coach is parked on a slope.

Link to comment
Share on other sites

I’m planning on detailing & lighting the interior of (hopefully) most of my coaches. I have got together a variety of parts & components to try a few things. I am leaning towards using latching reed switches at this stage. The only downside I can see is price & availability. I’m also leaning towards using track power rather than batteries. I don’t want the interior of the coaches to be just brown either but the large majority of videos I have seen of people painting seats etc. just look terrible. There must be some way of doing a good job of this. Also, passengers need to be fitted but I don’t think these need to be the most detailed/expensive ones. Even something as simple as painting the inside of the roof white can make a huge difference but hardly anyone seems to do this. Anyway, just a few thoughts…

Link to comment
Share on other sites

A long time back I saw an article - maybe another forum - where someone had fully detailed a Pullman with tableware, antimacassars on the seat backs, better table lamps, etc.

From memory even the toilet compartment was detailed even though you could not see it. The person doing the work said the hidden detail was done because he knew it was done, not for general viewing.

One of the problems with passengers is you usually have to cut their legs off to get them to sit right. Some folk have reported using Ho scale figures as more realistic in coaches.

Link to comment
Share on other sites

Topcat. Thanks for that it's a really comprehensive set of explanations and drawings. Just need to go and find a suitable vibration sensor (as you've said there is loads of them about so getting one sensitive enough to detect the motion is going to be key).

Next stop is getting some kit together and having a go at getting something working

Link to comment
Share on other sites

AM. Good luck with getting a system working. Before you buy a supercapacitor, which are quite expensive, I suggest you try out the circuit an ordinary aluminium electrolytic capacitor, say 10,000 uF/ 6.3V. This will only keep the lights on for a few seconds when the coach is stationary, but will prove the concept. If you can let me know the type of LEDs you are using I can work out series resistor values more accurately. Let me know if you need any more help.

Link to comment
Share on other sites

Wow that looks awesome! Assuming there's a small hole drilled to get the wires for the battery compartment underneath?

Was hoping to use these LED strips for the lighting https://www.railwayscenics.com/bulb-cool-white-non-waterproof-led-strip-unwired-5mm-wide-p-2765.html as they can be cut to size quite easily and are easy to stick to the roof with a bit of double sided tape.

I keep seeing these 555 timers popping up during my reading around. I can see how they can be wired up to turn on from an instructables article, just struggling with the trigger for the reset and how much power they use when not in use

Link to comment
Share on other sites

AM. I had a rethink and came up with a circuit that is much cheaper than using a Supercap (which are expensive) but simpler than using a 555 timer. When the vibration sensor switch closes it charges capacitor C1 via R1. This turns on MOSFET Q1 and lights the LEDs. If S1 does not close again C1 will slowly discharge through R2 until Q1 turns off. If S1 continually opens and closes the lights will stay on.

I am still dubious about using only one CR2032 lithium cell as the end-point voltage specified for these is 2 V, by which time the LEDs won't be lit. I had a look at vibration sensors on Ebay and found one from a seller called ezy_bay. It's called a vibrating sensor high sensitive vibration snap switch SW-1801P. The seller says it can be mounted in any position so should not close if a coach is parked on a slope.



forum_image_62711aa13988a.thumb.png.98ce373a327d8c1454b6fd6d5035403c.png

Link to comment
Share on other sites

Those are the vibration sensors I saw which made me ask the question as they're really cheap in the grand scheme of things.

Whilst more complex, I'm still being drawn to the 555 method simply for having an ability to have lights on for a period whilst stopped but there is something quite good about the simplicity of the above. I'm assuming that simply swapping the reed switch from the other set with the vibration one it has the potential for the lights to flicker quite significantly during operation?

Link to comment
Share on other sites

AM. The last circuit I sent does keep the lights on when the coach is not moving. Once C1 has charged it will keep Q1 turned on (and the LEDs lit) until C1 discharges through R2. You may want to play around with the value of R2 to get the time you want (somewhere between 100k and 1M) because electrolytic capacitors have very large tolerances.

No the lights won't flicker because once C1 is charged and Q1 is turned on it doesn't matter what the vibration sensor does. The lights will stay on until either:

a) the coach has stopped, C1 discharges and the lights will go off after a delay.

b) the coach is still moving, the vibration switch closes again and re-charges C1, so the lights will stay on.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
  • Create New...