Saturday, July 6, 2013

Noise Switch

I was a looking for a simple electronic device that will produce a logic "1" when noise inside a room is more than a threshold. I found some but was too expensive for me, so I decided to built one on my own.
The logic is easy, break down a pc microphone, connect it to power, amplify the signal (with a variable resistance) and after that smooth out the noise with capacitors.... Thats it!!! Now lets built it...

An old pc microphone will do the job.
pc microphone
And now we have the microphone lets design the circuit:
noise switch
There is nothing special with this design (the circuit is similar to current switch). First we supply the microphone with voltage through a variable resistor (R7), this potensiometer will increase or decrease the sensitivity of microphone. Next a high pass filter will cut all the dc voltage, the high pass filter is nothing more than a capacitor and a big resistor, you can find more here). 
Now we are ready to amplify the input signal using an opamp, the application will be 100 times the input signal (gain = R9/R1 = 100/1). Then a pull down resistor with a decoupling capacitor will smooth and somehow add all the frequencies into a dc signal. 
Finally, as I always do, I use an optocoupler to isolate the circuit from other devices, and I am connecting the transistor in common emitter mode, so the output will be non-inverting (when sound "appears"  in the input logic "1" will appear at the output.

Thats it.... Simple ha?

Sunday, June 30, 2013

Current Switch

Today I will try to create a simple electronic device that will recognize if a machine is on or off by "reading" amperes on feeding wire.
The first thing we will need is a CT (current transformer). For my project I use this:
current transformer
By reading the datasheet of this CT, we can see that the load current it would be 0-30 Amperes and the output it would be 0-1 Volts.  So using an opamp I will amplify the input signal and then if the signal is bigger than zero volts I will enable an optocoupler.
First lets see the schematic and then I will try to explain it.
current switch schematic
And now step by step let me explain you the circuit. CT1 and CT2 is the AC voltage that the CT producing which is 0-1 Volts. Then I am adding a small capacitor which will remove any dc voltage from the signal. Next step is to amplify the signal, this can be done with an inverting amplifier (wikipedia: An inverting amplifier inverts and scales the input signal). The output of an inverting amplifier (see below) is:
Vout=-(Rf/Rin)*Vin, so the maximum output voltage of my circuit it would be Vout = -[(30+1)/1]*Vin. In other words I would amplify my signal 31 times.
Inverting Amplifier (Wikipedia)

After the amplification using a big capacitor as decoupling capacitor I will try to convert the AC signal to pure DC voltage that will feed the optocoupler and will give a pure DC (5V dc) output.
Thats all nothing special but useful device...


References:

  1. http://en.wikipedia.org/wiki/Operational_amplifier
  2. http://en.wikipedia.org/wiki/Operational_amplifier_applications
  3. http://www.ghielectronics.com/downloads/Gadgeteer/Module/SCT013-030V%5B1%5D.pdf

\