Author Options:

How can I turn a square wave to a "logic one" or ON? Answered

I'm looking for ways to change a square wave to a logic high state. Attached is a diagram of the circuit. It picks up on when you approach it but sends out a square wave of I think about 50 Hz due to induction from mains in the body(?). I would like to turn this frequency into a logic one or ON when the frequency (from the hand) is present and for it to turn to a logic zero or OFF when no frequency is present. My goal is to get a decent logic proximity circuit that I can use to select pins for a binary multiplexer.

Attached is a diagram of the circuit which is inspired by this electrocope circuit, that I am trying to interface with other logic components. Basically Im aiming for an electrostatic proximity sensor that spits out a 1 or 0 based on some threshold sensitivity.

Would be super greatful if anyone had an idea of how to do this, I really need to get this working rather soon!





3 years ago

Thanks for the tip rickharris. I solved it using a low pass RC filter and a 40106 schmitt inverter instead. I am still having problem however, but further down the circuitry...

What I'm trying to do now with this circuit, is to have a MUX select between a bunch of resistors to send power to, determining the frequency of an oscillator (the oscillator in the diagram). I would like to use this to choose from 8 tones using three different buttons (the outputs from the inverter).

The problem Im having now is that when I turn the pins to the resistor R3 and R5 HIGH, R4 and R6 affects the frequency. Therefore they need to somehow be cut off from the circuit when the pin connected to them is LOW. I've been trying using transistors (2n3904 and BS170) as switches between the resistors and the rest of the oscillator circuit, this doesn't seem to work, probably because of the diode in the transistor that makes oscillation impossible(?) I've also tried with a 4066 bilateral switch, and connecting the control inputs to GND through a resistor to prevent any noise to open the switch. Doing this does indeed makes it possible to switch between two states, but the tone gets badly distorted for some reason I can't quite figure out

MUX controlled oscillator.jpg

3 years ago

Drive a 555 timer with a longish time constant from the squarewave, that way the 555 timer will keep the value high as long as there is a suitable input. When that drops off the 555 will time out and go low.

search for 555 monostable.