Stan, tried your approach and it works perfectly. Using a 5.1K resistor I get relay activation and very good sensor sensitivity.

As to a sensor approach on the TT. We currently have 9 different locations for the TT. We are using a stepper motor/Arduino for position control. The stepper controller provides selectable steps/rev (up to 6400) plus the stepper to TT is gear driven for further resolution. We use a limit switch for initial positioning and the spur/engine house track fixed locations are in a table generated with a calibration program. There are currently only 2 main line entry/exit points and I am just trying to add a safety feature to prevent an engine from going into the pit if I have not positioned the TT. The TT is very complex and adding even a single emitter would be a mess.

I think I will use a 2nd relay to disable the sensor function and will activate it from the control panel, where I only have 12VDC available (5V is provided from a regulator under the layout near the slip ring and is fed off a 12V bus. My relays are all 5V, so can I just add a larger resistor (like 12K) from 12V to the relay control input?

Ken

 

As I understand it, you want a control panel bypass/over-ride switch that prevents any of the relay modules from triggering.  But you only have 12V DC at the control panel.

Assuming the 5V and 12V DC share a common Ground, you could do something like this which does not require an additional relay.

kens trains IR 1

That's good thinking to extrapolate using a 12K (instead of 5K) resistor since you have 12V instead of 5V DC.  12K is kind of an unusual value for the weekend-DIY'er so you might find 10K, 15K, 20K work equally well.

So if the control panel switch is "open", then 12V DC is not supplied to any of the relay modules (only 3 shown above using the miracle of cut-and-paste).  So none of the relay modules can trigger whether their respective beams are broken or not.

Attachments

Photos (1)

Stan that's a great suggestion, but one problem. As I said the TT is complex. Under the table is a set of electronics/relays to activate sound--(currently also trying to learn how to use DFPlayer module to replace that stuff). Power (~5.4VDC) to that audio setup and to the TT (via the slip ring) is supplied from a voltage regulator that receives 12VDC. I could add a 2nd voltage regulator to supply 5V to the detection/override functions. I guess it's a matter of what is most convenient and effective. Also, it doesn't seem reasonable to keep those components always powered even if not being used--so maybe that's best approach.

By the way I did keep increasing resistance values and am using 15K.

By the way, if I haven't been too much of a pest, I would really like to know why current level (if that's what is the controlling agent) through an IR sensor affects its' sensitivity (or at least that's what I observed). Maybe I need to check some spec.s.

Thanks again for all of the help & suggestions.

Ken

"~5.4vdc"?

"~5.4vAC?" " -5.4vdc?" or "....5.4vdc"

 I'm not up to speed on readingreadi thisthis thread, so the exact context is unknown to me;  but ~ is a symbol for AC; so "~5.4vdc" 

It stood out like a sore thumb to me in the paragraph.

(and not elaberating moremore bec of spellwreck).

"Still trying to not shoot my eye out"

 

"Nursing insomnia one railcar at a time"

My aroma therapy? Smoke Pellets.

 





ken's trains posted:

... I could add a 2nd voltage regulator to supply 5V to the detection/override functions. I guess it's a matter of what is most convenient and effective. Also, it doesn't seem reasonable to keep those components always powered even if not being used-- 

Many options.  My observation was you shouldn't need a 2nd relay.  That is, the control panel toggle switch could either (1) block triggers to the relay modules, or (2) as you suggest simply cut power to the IR relay modules themselves.  

If using method 2), DC-to-DC voltage regulator modules (to convert 12V DC to 5V DC) are about $1 on eBay with free shipping from Asia.

ken's trains posted:

...By the way I did keep increasing resistance values and am using 15K.

By the way, if I haven't been too much of a pest, I would really like to know why current level (if that's what is the controlling agent) through an IR sensor affects its' sensitivity (or at least that's what I observed).

If I understand your question, the IR sensor is not binary "on" or "off" like a toggle switch.  Instead, the electrical resistance between the 2 terminals varies depending on the amount of IR energy hitting it.  More IR energy lowers the effective resistance.  In your application the IR sensor (photo-transistor so actually a semiconductor) is effectively behaving as a garden variety photo-resistor where the resistance between the 2 terminals decreases as light increases.

photoresistor

Apparently you were having a sensitivity issue so that's why I suggested you increase the trigger resistor value from 1K to 5K or whatever.  Increasing the resistor value decreases the amount of current available to trigger the relay.  In your application, the IR sensor shunts or diverts the trigger current.  Increasing the resistor value means less current needs to be diverted to keep the relay off when the IR beam is present.  Thus this increases sensitivity since less IR energy is needed.

Attachments

Photos (1)

Stan, thank you for the explanation.

As to sensor (safety) control, it turns out that going thru my many purchases from ebay, I bought a number of rotary switches (I have 2 ZW Transformers and used them to switch tracks & throttles). One of the switches is a 4-pole/5 pos. switch and is perfect for the job. I am not only turning safety functions on/off, I am also selecting a specific track section, illuminating a lamp on the selected track section, and changing ZW throttles based on where the engine is coming from/going to.

And Adriatic, I used the (~) symbol to indicate approximate. I need to fiddle with the regulator output to make sure I have enough 'juice' to drive the servos on the TT without overdriving the optics.

 

Add Reply

Post
OGR Publishing, Inc., 1310 Eastside Centre Ct, Suite 6, Mountain Home, AR 72653
330-757-3020

www.ogaugerr.com
×
×
×
×
×