Re: detecting contact closure
- From: "Jenalee K." <jenaleek@xxxxxxxxx>
- Date: 31 Jul 2006 01:47:26 -0700
post a écrit :
Greets all. I'm an amateur at this, so please disregard any
errors in my techincal description. I have a seemingly simple
task to accomplish and am trying to figure out the best
(most reliable) way to get it done.
I have a mechanical switch located about 300-400 yards
away, on an entrance gate -- the contact closes when
someone opens the gate.
I'd like to detect the closed contact with a TTL circuit. I
already have the TTL logic in place (0V - gate is closed,
5V gate is open).. but am unsure how to "condition" the
mechanical switch so it reliably provides a 5V signal
to my TTL when the gate is open.
I'm considering 2 options:
1) use a resistor to 5V power supply.. when the switch closes,
it sends 5V to my TTL.. when it opens, i'll get something less
than 1 or 2V.. but I'm not sure if this will be a problem considering
the long wires i have to the switch. Surely the extra resistance
from all that wire will affect my simple 5V switch circuit.
2) my other option is to sense a small AC signal running through
the switch (since, as I understand, AC signals don't suffer so
much from loss over long distances). I would run a small AC signal
through the switch and interface to it with a diode bridge rectifier.
when the switch is closed, and there is AC flowing, I'll detect it
on the DC side of the bridge.
Any thoughts on the best way to go? Is there a better solution
out there? Don't want to get too complicated.. already have a
junk drawer of electronics parts like diodes, resistors, etc.. that I'd
like to use.
Thanks.
The usual way to do this is a pull-up resistor of 10k say to +5V and
the switch to 0V with maybe some debouncing circuit. That way you will
always have a well-defined level on the logic's input.
However, the 300 meters or so of wire between the switch and the logic
are a problem. They will pick up noise and stuff that will probably
destroy the logic some day so some isolation/protection will be
necessary. Cheap/simple ways (at the cost of an extra power supply):
- the switch operates a lamp (110VAC/230VAC) and a light sensor
(LDR,photo diode) detects the lamp on/off condition. Eliminates contact
bounce but some circuitry is needed to get a logic level out of it.
Maybe some rugged opto-coupler.
- the switch operates a relay and its contacts copy the switch. The
relay switch contacts are hooked up with a pull-up resistor to +5V and
the other contact to 0V as described before.
Lamps and relays are much more robust than TTL logic.
Or go wireless.
Or do signal conditioning at the gate and transmit over twisted pair
using RS485 logic.
Or...
Thanks,
Jenalee K.
.
- References:
- detecting contact closure
- From: post
- detecting contact closure
- Prev by Date: detecting contact closure
- Next by Date: Re: 24Vdc Power supply
- Previous by thread: detecting contact closure
- Next by thread: Re: detecting contact closure
- Index(es):
Relevant Pages
|