Skip to main content

Hi,

I'm trying to develop a circuit that will use an insulated rail trigger to a relay to throw a two wire LGB switch machine. The relay output needs to be momentary, but the input to the relay will be constant so long as a train is on the insulated section of the track. I read that this could be as easy as wiring a capacitor and resistor in parallel on the output of the relay. Is that true? How do I calculate the values of the capacitor and resistor? Are there any other solutions?

Thank you,

George

Original Post

Replies sorted oldest to newest

George S posted:
Oman posted:

The Atlas 6924 universal switch control board performs this function.

They are out of stock almost everywhere. I would love to buy a few of those. I also looked at Azatrax, but those are optical sensor triggered, and I want to use insulated rail.

George

George,

I use this Azatrax relay (non-optical) with an insulated rail on my layout to trigger my Lionel block signal. Have no clue if it would adapt to the application you are looking for but thought I'd mention it.

http://www.azatrax.com/track-power-relay.html

George S posted:

What if I use two relays, one that is NO and one that is NC, and I use the RC circuit to delay the opening of the second circuit? So, no power would go to the NC relay unless triggered by the NO relay through an insulated rail activation.

George

George

I think you mean something like this. I would look into an NTC resistor for the delay. It would slow down the turn on of K2.

Const-Mom

Attachments

Images (1)
  • Const-Mom
Oman posted:
George S posted:

What if I use two relays, one that is NO and one that is NC, and I use the RC circuit to delay the opening of the second circuit? So, no power would go to the NC relay unless triggered by the NO relay through an insulated rail activation.

George

George

I think you mean something like this. I would look into an NTC resistor for the delay. It would slow down the turn on of K2.

Const-Mom

Yes, that is what I was thinking. Thanks for the suggestion. I may test it with a bulb before trying a switch machine.

George

johnstrains posted:
George S posted:
Oman posted:

The Atlas 6924 universal switch control board performs this function.

They are out of stock almost everywhere. I would love to buy a few of those. I also looked at Azatrax, but those are optical sensor triggered, and I want to use insulated rail.

George

George,

I use this Azatrax relay (non-optical) with an insulated rail on my layout to trigger my Lionel block signal. Have no clue if it would adapt to the application you are looking for but thought I'd mention it.

http://www.azatrax.com/track-power-relay.html

I think that one has a constant on output to keep the light lit. That will burn out my switch motor.

George

How many switches do you have or plan to have?

What kind of Accessory power is available for the relay circuit?

Is it acceptable to use a $2 DC-output wall-wart (which requires access to a wall-outlet socket)?  Or is it desirable/required to only have power from the Accessory AC (e.g., 14V, 16V) from an existing transformer?

Are you willing/able to solder a few components?

You should be able to do this for ~$5 per switch using a ~$3 timer-relay module from eBay/Asia and few 10-cent components.  Answer the above questions and I'll cook up something.

stan2004 posted:

How many switches do you have or plan to have?

What kind of Accessory power is available for the relay circuit?

Is it acceptable to use a $2 DC-output wall-wart (which requires access to a wall-outlet socket)?  Or is it desirable/required to only have power from the Accessory AC (e.g., 14V, 16V) from an existing transformer?

Are you willing/able to solder a few components?

You should be able to do this for ~$5 per switch using a ~$3 timer-relay module from eBay/Asia and few 10-cent components.  Answer the above questions and I'll cook up something.

Hi Stan,

Initially, this is for two switches in a double reverse loop dogbone. I have several accessory transformers available and bags of wall-warts. I also don't mind buying one or two if it makes it easier. I can solder pretty good. I'm starting to wear out my iron. I assume this is a relatively simple single layer project. 

FYI, the LGB switch machine is a two wire machine. I believe it uses reverse polarity to throw the opposite direction.

I really appreciate it!

George

gunrunnerjohn posted:

CAPACITOR DISCHARGE UNIT MkII

 Complete specs to build them available at that site.

Thanks John! So, this circuit wouldn't use a relay? It would just bleed off voltage after the initial pulse until the circuit was open? What kind of heat would this generate over about 30 seconds at 9 to 12 volts? That's how long I figure it will take a train to clear the insulated rail.

George

Not familiar with the LGB switch machine.

So are you saying you need a momentary positive DC pulse to fire the switch one way.  And a momentary negative DC pulse to fire the switch the other way?  This is all do-able but need to be clear on what we're trying to do here!  Do you have specs on what kind of DC pulse is needed to drive the LGB switch? 

stan2004 posted:

Not familiar with the LGB switch machine.

So are you saying you need a momentary positive DC pulse to fire the switch one way.  And a momentary negative DC pulse to fire the switch the other way?  This is all do-able but need to be clear on what we're trying to do here!  Do you have specs on what kind of DC pulse is needed to drive the LGB switch? 

I hadn’t got that far. The LGB motor is DC and requires momentary control. The LGB switch controller actually uses 18V AC power with two diodes to create half wave rectified power to the switch. One diode controls left throw and the other has reversed polarity to control right throw. The switch motor will operate on much lower DC voltage, maybe 9 to 12 volts. I’ve read that the motor actuates in 15ms, but I was planning on a half second to one second. If DC power is used, the polarity must be reversed to throw the switch the opposite direction. 

I’m using these drives on tinplate switches that need too much force for a DZ or Atlas motor. 

So, the direction of the switch throw required is going to be dependent on which insulated rail is triggered. That either means two circuits per switch or a more complicated circuit I guess...

George

cjack posted:

Here's a recommended circuit...for some idea on what is required.

http://www.altek.nl/graphtips/EPLsturing.gif

Those circuits show how to wire the switch machine. I don't think it is for an insulated rail application, because LGB is typically two-rail. I think the #1 and #2 in the diagram are magnetic triggers, which is closer to momentary since the magnet is usually only on the engine, and the contact would only be open for a second as the engine passes. What do the capacitors do in the second diagram?

Thanks!

George

OK - if the LGB 2-wire switch uses the 2-diode (half-wave) method for polarity:

lgb

Shown above is a ~$3 timer relay module configured in a so-called non-retriggerable "Delay OFF" mode.**  Upon trigger the relay turns ON, then there's a settable delay (in your case 0.5 to 1.0 sec per your comment), then relay turns OFF.  Non-retriggerable means the trigger can remain active during or after the relay operation but the relay turns ON only once for the chosen time interval.

If this looks like a direction you'd like to pursue, I'll provide more details as I still have this timer module  set up on a test track for a different OGR thread.  I can even make a video showing it in action.

There is an additional issue of intermittent/noisy triggering when a consist enters or leaves the insulated rail section.  When there is only 1 or just a few axles straddling the outer rails, you can get multiple triggers rather than just one long-continuous "clean" trigger.  It should be benign in your application.  In other words you may get multiple 0.5-1.0 sec pulses of power to the LGB switch when a consist enters or leaves but they would be in the "same" direction if that makes sense.  If this is an issue, you can install a 10-cent resistor-capacitor trigger filter which I've detailed in many previous OGR threads using these low-cost relay modules.

lgb with rc filter

 

** Addendum.  Here's a snippet (spelling / grammar errors included!) from the timer module instruction sheet showing its different modes.  Mode P1.1 is what you want for non-retriggerable operation.

Operation mode:
P1: After triggered signal, power relay on time OP, then turn off; within the OP period following operation:
1) P1.1: signal being triggered again is not effective
2) P1.2: signal being triggered again, start time again
3) P1.3: signal being triggered again, reset; disconnect relay, stop timing
P2: giving the trigger signal, the time after shutdown relay CL power relay OP time; then timing, turn off the relay
P3.1: give the trigger signal after the power relay on time OP, CL shutdown time relay; then operating cycle above cycle gaive signal again, shutdown relay stop timing; cycle times (LOP) can be set
P3.2: after connecting. no need to trigger signal, power relay on time OP, CL shutdown time relay; then the operating cycle above timea cycle (LOP) can be set
Q4: keeping the function of the signal; if there is no trigger signal, the time will be canceled, relay stay connected; when the signal disappears, timing OP turn off the relay; over time, if no signal again, the time is cleared  

 

Attachments

Images (2)
  • lgb
  • lgb with rc filter
Last edited by stan2004
stan2004 posted:

OK - if the LGB 2-wire switch uses the 2-diode (half-wave) method for polarity:

lgb

Shown above is a ~$3 timer relay module configured in a so-called non-retriggerable "Delay OFF" mode.  Upon trigger the relay turns ON, then there's a settable delay (in your case 0.5 to 1.0 sec per your comment), then relay turns OFF.  Non-retriggerable means the trigger can remain active during or after the relay operation but the relay turns ON only once for the chosen time interval.

If this looks like a direction you'd like to pursue, I'll provide more details as I still have this timer module  set up on a test track for a different OGR thread.  I can even make a video showing it in action.

There is an additional issue of intermittent/noisy triggering when a consist enters or leaves the insulated rail section.  When there is only 1 or just a few axles straddling the outer rails, you can get multiple triggers rather than just one long-continuous "clean" trigger.  It should be benign in your application.  In other words you may get multiple 0.5-1.0 sec pulses of power to the LGB switch when a consist enters or leaves but they would be in the "same" direction if that makes sense.  If this is an issue, you can install a 10-cent resistor-capacitor trigger filter which I've detailed in many previous OGR threads using these low-cost relay modules.

lgb with rc filter

Stan,

This looks like what I was looking for. I think the resistor - capacitor filter would be a nice additional feature.  Could this also be solved by a longer insulated rail section?

Second question, once the relay turns off, would the insulated rail DC input to the coil need to drop before the circuit is reset? Meaning, would the relay remain off as long as the coil remains energized?

Thank you,

George

Q1.  No, the length of the insulated rail section does not matter.  Even for a mile-long (!) section, when the consist first enters the section you have only 1 axles, then 2 axles, then 3 axles, etc.. straddling the outer rails and providing the electrical trigger signal.  Likewise, when the consist exits the section you get to the point where you have 3 axles, then 2 axles, then 1 axle, then 0 axles.  In both cases (entering and exiting) there is the opportunity for an intermittent electrical contact which would create a false trigger.

Q2. I may be misunderstanding you question.  But in the case of the timer-relay module, the trigger signal from the insulated rail section does NOT directly drive the relay coil.  There is electronics in the relay module which, in effect, disconnects the trigger signal from the relay coil after the programmed interval (say, 1 second) has elapsed.  So even if the consist stops on the trigger section providing a continuous trigger, the relay only turned ON once for 1 second.

So here we have one module in action.  The painted white track section is the insulated rail section.  There is a white wire going into the timer module.  This obviously shows half of what would be needed using the 2-diode method discussed earlier.

Initially there is NO resistor-capacitor filter.  Note how there are a couple of "false triggers" where the relay turns ON (listen for the relay click on and off coincident with the digital timer counting down from 1.0 sec).  Note also how even after the relay turns on and off, the "consist" can sit on the insulated section and you get no additional triggers.  But from dirty wheels, track, etc.. you can get false triggers from a momentary loss of a solid electrical connection between the outer rails.

Addendum: And here are some photos of components used.  

12v%2520dc%2520output%2520wall%2520wart%2520and%2520wiring%2520adapter

If you have a stash of DC-output wall-warts pretty much any would probably work.  9V and 12V are common DC outputs.  The timer module suggested can handle anything between 6-30V.  Shown in above recycled photo is an output adapter connector which converts the common coaxial barrel of a wall-wart to screw-terminal so you don't have to splice into the wall-wart cable.  This photo was from this OGR thread which also included the following photo:

resistor%2520assortment%2520less%2520than%2520a%2520penny%2520each

In the earlier thread I suggested buying a resistor kit which gives you a broad assortment of resistors for less than a penny a piece.  Even if this is your only venture into component-level assembly, it shouldn't break the bank!

And here's a photo of the Delay-OFF relay module.  Note that I only show photos since OGR does not allow direct eBay links.  And even eBay listing #'s which can help to find a current listing go stale after 6 months or something like that.  I'm thinking this application may come up again!

dc 6-30v relay timer

This one seems to be the least expensive when you buy 2 since shipping is apparently the same.  Otherwise there a plenty of eBay sellers for about $3 each with free shipping from Asia.

If you do choose this route, it can be confusing to "program" the timer module to what you want but I'll be here to help if you get to that point!  Many of the instruction sheets that accompany these modules are poor translations to say the least!

 And if you need those 2 diodes per the diagram that cjack posted, they are a couple pennies each:

1n4003 diodes 2 cents each

Attachments

Images (4)
  • 12v%2520dc%2520output%2520wall%2520wart%2520and%2520wiring%2520adapter
  • resistor%2520assortment%2520less%2520than%2520a%2520penny%2520each
  • dc 6-30v relay timer
  • 1n4003 diodes 2 cents each
Last edited by stan2004
stan2004 posted:

Q1.  No, the length of the insulated rail section does not matter.  Even for a mile-long (!) section, when the consist first enters the section you have only 1 axles, then 2 axles, then 3 axles, etc.. straddling the outer rails and providing the electrical trigger signal.  Likewise, when the consist exits the section you get to the point where you have 3 axles, then 2 axles, then 1 axle, then 0 axles.  In both cases (entering and exiting) there is the opportunity for an intermittent electrical contact which would create a false trigger.

Q2. I may be misunderstanding you question.  But in the case of the timer-relay module, the trigger signal from the insulated rail section does NOT directly drive the relay coil.  There is electronics in the relay module which, in effect, disconnects the trigger signal from the relay coil after the programmed interval (say, 1 second) has elapsed.  So even if the consist stops on the trigger section providing a continuous trigger, the relay only turned ON once for 1 second.

So here we have one module in action.  The painted white track section is the insulated rail section.  There is a white wire going into the timer module.  This obviously shows half of what would be needed using the 2-diode method discussed earlier.

Initially there is NO resistor-capacitor filter.  Note how there are a couple of "false triggers" where the relay turns ON (listen for the relay click on and off coincident with the digital timer counting down from 1.0 sec).  Note also how even after the relay turns on and off, the "consist" can sit on the insulated section and you get no additional triggers.  But from dirty wheels, track, etc.. you can get false triggers from a momentary loss of a solid electrical connection between the outer rails.

Addendum: And here are some photos of components used.  

12v%2520dc%2520output%2520wall%2520wart%2520and%2520wiring%2520adapter

If you have a stash of DC-output wall-warts pretty much any would probably work.  9V and 12V are common DC outputs.  The timer module suggested can handle anything between 6-30V.  Shown in above recycled photo is an output adapter connector which converts the common coaxial barrel of a wall-wart to screw-terminal so you don't have to splice into the wall-wart cable.  This photo was from this OGR thread which also included the following photo:

resistor%2520assortment%2520less%2520than%2520a%2520penny%2520each

In the earlier thread I suggested buying a resistor kit which gives you a broad assortment of resistors for less than a penny a piece.  Even if this is your only venture into component-level assembly, it shouldn't break the bank!

And here's a photo of the Delay-OFF relay module.  Note that I only show photos since OGR does not allow direct eBay links.  And even eBay listing #'s which can help to find a current listing go stale after 6 months or something like that.  I'm thinking this application may come up again!

dc 6-30v relay timer

This one seems to be the least expensive when you buy 2 since shipping is apparently the same.  Otherwise there a plenty of eBay sellers for about $3 each with free shipping from Asia.

If you do choose this route, it can be confusing to "program" the timer module to what you want but I'll be here to help if you get to that point!  Many of the instruction sheets that accompany these modules are poor translations to say the least!

 And if you need those 2 diodes per the diagram that cjack posted, they are a couple pennies each:

1n4003 diodes 2 cents each

Fantastic! I thought you were going to make me build the relay module... Phew.

the rest looks like I can handle it! Thank you! I’ll circle back as I get the parts and assemble it. If all goes well, I’ll post pictures of the circuit and operation. Otherwise, I’ll be back with questions.

BTW, I’ve ordered from China. You may not hear from me until later in January.

George

Last edited by George S

I think I have another solution for this. Assuming I have the components, I will try setting it up this weekend. The LGB EPL switch has a companion supplemental switch that can be used to control things based on the switch direction. It can be used to control another switch or to light red/green lights to show the switch direction. If I use a quad comparator with an insulated rail, I should be able to trigger a relay to throw the EPL switch if it is facing the wrong direction. Once the switch is thrown, the quad comparator would shut off the relay. I assume I need a relay because I can’t run AC through the quad comparator.

Anything I should be careful about when creating this circuit? I think I can use the same DC power supply for the insulated rail and the supplemental switch. I think the supplemental switch is very basic, with input power terminals and two separate pairs of output terminals.

I’ll report back with results.

George

Last edited by George S

I'd like to see your schematic before commenting.  For example, I'm not clear on why you need a "quad" comparator implying 4 comparators for something like this.  What are you comparing?

If you're saying there are 2 bulbs - one indicating the switch is "straight" and the other indicating the switch is "diverge" then here's another idea:

lgb alternative

The idea here is you no longer need a timer to limit the power applied to the solenoid to 1/2 sec, 1 sec or whatever.  You only power the solenoid if the switch is in the "wrong" position as indicated by the red or green bulb.  In the example above, the phototransistor turns ON when a train enters the insulated rail section that demands the switch be in the straight setting AND the bulb indicates the diverge position.  If the switch is ALREADY in the straight position, then the bulb will be OFF and the relay will not fire.

There are many schemes that use this kind of feedback that stumble for this reason.  Sometime the switch get jammed or stuck in some mid-position (between diverge and straight). Because the switch is in no-man's land, the indicator may be simply wrong and the red or green bulbs might even be BOTH on, BOTH off.  Of course if the switch is mechanically jammed then even the timer method would not work so one can argue this is a moot point.

I show just one direction (one relay) but you can buy a 2-channel 12V DC relay module for less than $1 per channel as suggest above.  A phototransistor is essentially an electrical switch that turns ON when light is presented.  A resistor is a penny or two.  So if indeed you have lamp indicators showing which position the switch is in, then for about $2-3 you can eliminate the timers and save a few bucks. 

Attachments

Images (1)
  • lgb alternative
Last edited by stan2004

I was going to use the quad comparator to compare which of the two switch paths has voltage from the supplemental switch. I was planning to only use two of the comparators. I have a few of these. Do they make "bi" comparators?  My thought was that the comparator would be a switch, much the way your photo transistor would work. The photo transistor is an interesting idea, but I have had problems with IR light pollution in the past and don't think this is as reliable. My switch doesn't currently have lights, but they could easily be added to the supplemental switch. Of course now I'm buying lights. I'll try a diagram to explain better. 

I already ordered the timer relays and I will probably use them, because l think they are a fail-safe to be sure the switch doesn't get power for too long.

George

Yes, a diagram would help me understand your thinking.  I guess I'm not clear on the signal coming from the switch telling you which direction it's set to.  That is, a red and green lamp pair obviously indicates the direction.  But is this direction indicator an AC voltage?  How many volts?  What signal do you get if the switch is jammed/stuck between straight and diverge?

Comparators work with DC signals.  Yes, you can rectify an AC signal to DC with a few pennies of diodes but I curiously await your diagram.  And, yes, they make "bi" comparators (2 in one package) though more commonly called "dual" comparators.

As for IR reliability, in this particular application you would place the IR phototransistor right up against the corresponding lamp and then put some black heat-shrink, electrical tape, whatever so no stray light hits the phototransistor.  I did not mention this earlier but one "freebie" you get from using an incandescent lamp is it essentially converts an AC signal to a DC signal.  You get a steady (DC) light from the bulb even if it's driven by an AC voltage.  

 

 

OK, I tried a diagram. This is not so easy in Powerpoint. I only showed the wiring for one side of the switch and didn't finish the wiring of the second relay.

circuit

The LGB 12070 is a SPDT switch that piggybacks on the LGB switch machine. I would only need to use one side of the 12070. I have all the components to build this. I can't find my project board or I would have had it mocked up already.

George

Attachments

Images (1)
  • circuit
Last edited by George S
George S posted:

OK, I tried a diagram. This is not so easy in Powerpoint. I only showed the wiring for one side of the switch and didn't finish the wiring of the second relay.The LGB 12070 is a SPDT switch that piggybacks on the LGB switch machine. I would only need to use one side of the 12070. I have all the components to build this. I can't find my project board or I would have had it mocked up already.

George

George

There are some issues with how you implemented the comparators. However, I don't see the comparators as being necessary. You want to turn on one relay momentarily, if the path is straight and the other relay if the path is divergent? I think this circuit does the same thing without the comparators.

 

LGB 12070 

Attachments

Images (1)
  • LGB 12070

What he said!

lgb 12070

From what I can tell, the LGB 12070 supplementary switch is simply a lever microswitch.  So as Oman shows the logical "AND" function is effected by placing the 12070 in-series with the insulated rail trigger signal.  In other words, it requires the combination the insulated rail trigger AND the LGB switch being in the undesired position to fire the switch to the opposite position.  If the switch is already in the correct position, then nothing happens.

So you should be able to wire this up today...no comparator required.

The only issue I see is as follows.  When the solenoid fires to drive the switch to the opposite position (whether diverge -> straight or straight -> diverge) at some point in the motion, the 12070 will flip its position and power will no longer go to the solenoid.  The question is whether there is enough "momentum" to carry the mechanism to the opposite setting.  You'd think the designers would have accounted for this but who knows!  In any case you can check it out with what you have today and let us know for the record.

If the 12070 releases too quickly, the switch mechanism does not firmly snap over to the opposite position, then we're back to the timer mechanism so that power is applied for some minimum duration (e.g., 1/2 sec).

Attachments

Images (1)
  • lgb 12070
Last edited by stan2004

Keith and Stan, 

Thank you! Leave it to me to design a Rube Goldberg. LGB designed great power into simple mechanisms. 

I will give it a go. I think there should be enough momentum in the machine, but we will see. I should be able to test this tomorrow.

Glad I waited for a response before getting out my soldering iron. 

George

Oman posted:
George S posted:

I got one side working. So, great progress!

George

Glad to hear. Even though it's working, it would be a good idea to add diodes across the relay coils. This will slow the turn off time of the relays.

LGB 12070

Thank you for the suggestion. I don't think it is required. Something about the 12070 strongly completes the closure of the switch. There is not much chance of the switch fouling. I tried pushing the point the opposite direction while a car was on the insulated rail section and the relay engaged the switch machine almost immediately. Of more concern might be the relay staying on too long. For example, if a screw got caught in the switch preventing closure of the switch, the relay would stay engaged and continue sending power to the 12010. You can hear the switch machine rattling in that case, so I think I could react. I am not too worried about it. The LGB components are pretty robust.

George

Oman posted:
George S posted:

I got one side working. So, great progress!

George

Glad to hear. Even though it's working, it would be a good idea to add diodes across the relay coils. This will slow the turn off time of the relays.

Really?  The diodes across the relay coils are normally just to protect against inductive kickback, how are they slowing the turn-off time of the relays?

John

V = L x di/dt where L and di are constants. The smaller V is, the longer dt is, that is the time for the current in the coil to dissipate. With a diode, V is 0.7 volts. Without a diode, V is whatever the break-over voltage of the contact is.

"When used with a DC coil relay, a flyback diode can cause delayed drop-out of the contacts when power is removed, due to the continued circulation of current in the relay coil and diode."

Above quote from below link.

https://en.wikipedia.org/wiki/Flyback_diode

 

gunrunnerjohn posted:

Any delay from the flyback diode will be minuscule, certainly no more than a couple of milliseconds.  I can't imagine this is significant in this application.  If you really want to stretch the relay dropout time, a capacitor is the way to go.

John

FWIW, this  Snubber delay suggests a delay of 2X or more. The question on the web page isn't important, but answer #2 demonstrates the delay effect of a diode vs a resistor. A diode vs no snubber would be even more significant.

The relay in George's application has a published release time of 5 ms. Doubling to 10 ms. could be the difference between working or not. 

Add Reply

Post
×
×
×
×
Link copied to your clipboard.
×
×