# Need to generate a TTL signal from a footswitch

I have an optical shutter controller which drives a shutter using either a TTL-level pulse or a footswitch. Unfortunately, there is only
one input on the controller. I'd like to construct a circuit with a junction box that will allow me to use both inputs without having to manually disconnect/reconnect each time. I plan to build a logic Or- gate to handle the two inputs. The TTL line is already compatible. I need to build a little circuit which will convert the pressing of the footswitch into a TTL-level signal. The leads of the inactivated footswitch are grounded (that is, when I measure the resistance between the two leads it shows 0 ohms). When the footswitch is activated (pressed) the resistance between the leads is infinite (that is, open). So, there are no active elements in the footswitch, it looks like 0 or infinite resistance depending on whether or not its pressed. Can anyone help me with a circuit that will generate TTL-low (0 Volts) when the switch is inactivated (leads grounded), and TTL- high (5 V) when the switch is activated (leads open)?
Thanks very much!
âœ–
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

As another poster pointed out, add a resistor to +5V and it's TTL-compatible. However:
1) A long lead may act as an antenna or pick up static electricity, so perhaps a buffer circuit may be necessary; 2) Many switches make intermittent connections at the moment when the switch makes or breaks. TTL may be fast enough to see this as many very rapid openings/closings of the switch. This may or may not be a problem for your circuit. If it is, a one-shot circuit can clean up the signal. It's possible to combine that with the buffer.
âœ–
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
writes:

Indeed!
From the time the first switch/button was connected to the first logic circuit, the problem of "de-bouncing" had to be addressed.
As to the circuit that "powers" the foot switch: I would prefer a voltage divider that makes the "high" level on the order of 3 volts and a series resistor than makes the "low" level on the order of .3 volts. If the driven circuit has a bit of hysterisis in its input characteristics, a small cap. across the switch may be sufficient for "debounce."
âœ–
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>

Connect theswitch between signal ground and TTL input. Connect one suitable resistor (for example 1 kohm to 5 kohms) from +5V to that input pin. Now when there is switch installed and not pressed (resistance 0 ohms), you get logic 0. When switch is pressed (open circuit), the input is logic 1.
This pull-up resistor does not cause problems if you drive the input with soem TTL signal source (TTL output can handle this extra pull-up load).
--
Tomi Engdahl (http://www.iki.fi/then /)
Take a look at my electronics web links and documents at
âœ–
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Thanks very much for your replies. I had planned on using a battery for power and I thought this circuit (pull-up resistor) would drain the battery especially because the shutter spends most of the time closed (so switch is shorting). Is that true, or am I worrying for nothing?
Mike
On Mar 17, 12:02 pm, Tomi Holger Engdahl

ama.net/