TOUCH SWITCH

Sunday, 3 April 2011

COMPUTER MICROPHONE

Interfacing Microphones to Computer Sound Cards

Most sound card microphone inputs require a minimum signal level of at least 10 millivolts, but some older 8-bit cards need as much as 100 millivolts. The typical impedance of the PC soundcard microphone input is in order of 1 to 20 kohms (can vary from card to card). The microphone type which works best with computer sound cards is the electret microphone.
Sound Blaster soundcards (SB16, SB32, AWE32, AWE64 or Live) from Creative Labs have a 3.5mm (1/8 inch) pink stereo jack for the microphone input, with the following pinout: Standard 3.5mm microphone jack
  1. Signal input (tip)
  2. +5V bias (ring)
  3. Ground (sleeve)
Note: Most soundcards will wire the positive DC bias voltage to the ring, but a small number of non-standard soundcards can have the bias voltage wired to the tip. A few cards have a jumper which enables or disables the power to the microphone jack. If the jumper is put on, the bias voltage ( +5V through a few kiloohm resistor) is wired to the tip. Newer mainboards with stereo microphone support will provide the bias voltage for both the tip and ring.
Standard sound card microphone input The approximate schematic of a Sound Blaster microphone input circuitry shows that the +5V voltage on the connector is heavily current limited. The card's voltage might not be exactly 5V, but it is usually something between 3 and 5 volts when no microphone is connected.

Electret microphones

The electret microphone is the cheapest omnidirectional microphone you can buy. Very sensitive, durable, extremely compact in size, electret mics are used in many applications where a small and inexpensive microphone with reasonably good performance is needed. You can find them in almost every stereo equipment, in consumer video cameras, mobile phones and so on.
Electret microphone
The electret is a modified version of the classic capacitor microphone, which exploits changes in capacitance due to mechanical vibrations to produce a small voltage proportional to sound waves. The electret does not need an applied (or phantom) voltage like the condenser microphone -- as it has a built-in charge -- but a few volts are still required to power the internal Field Effect Transistor (FET) buffer.
The bias is needed for the small built-in FET follower which converts the very high impedance of the electret element (tens of megohms) to an acceptable level (several kohms).
Electret microphone to sound card schematic
The circuit on the left shows a safe way to connect electret microphone capsules to old, non-standard soundcards. Build this circuit only if the simple schematic below does not work.

The component values are not critical; you can use any capacitor between 1uF and 22uF, and a resistor value from 1k to 22k.
Simple Electret microphone to sound card schematic A simple modification which works with most soundcards is presented on the right. The circuit works because usually the power is fed to the microphone connector through a few kohm resistor and the DC bias on the tip is removed by the input capacitor inside the card.
Use a simple one conductor shielded cable: wire the shield to the connector's sleeve; connect the ring and tip to the central conductor.
Note: A few, recently manufactured PCs have implemented true stereo microphone inputs. High performance speech recognition and advanced noise canceling applications -- see the Andrea Superbeam Array stereo microphone -- make good use of this new feature, providing more accurate and reliable signals in noisy environments. Stereo computer microphone schematic diagram
When the stereo mic input mode is selected, the bias voltage will be provided for both the tip and the ring. The wiring for a stereo microphone is simple -- see the schematic diagram on the left -- connect the shield of both microphones to the sleeve of the plug, the left mic to the tip and the right mic to the ring. For best performance, use unidirectional electret microphones.

Connecting dynamic microphones

Dynamic microphone to sound card connection diagram Quality dynamic microphones usually do provide sufficient signal to drive a reasonably good computer sound card. All you must do is to wire the mic properly, and in some cases, turn on the mic preamplifier built into the sound card (called 'mic boost' on most PCs).
The connection is as simple as it gets: wire the microphone to the tip and sleeve of the sound card's microphone input. Leave the ring (bias) pin open, do not connect it to anything.
Most professional mics will be fitted with the standard XLR connector. To make a simple adaptor, wire the mic audio (XLR pin 2) to the sound card input connector's tip; wire the mic audio return (XLR pin 3) and the shield (XLR pin 1) to the sleeve.
Note: Some non-standard soundcards will have the bias voltage wired to the tip. Also, new PCs with stereo microphone inputs will provide the bias voltage to both the tip and ring of the microphone input when the stereo mic input mode is selected. This situation needs special care -- the sound card's bias circuit is current limited, so your microphone may survive this small DC bias, but it will probably cause severe distortion. A simple solution is to insert a small capacitor between the mic audio output and the mic input to cut the DC current.
There are a few cases when your dynamic microphone does not provide the signal level required by your hardware -- you'll end up with a very poor sound with lots of noise, even when you turn on the sound card's internal preamp. An easy solution is to build a microphone preamplifier similar to this simple single transistor circuit below:
Simple dynamic microphone amplifier schematic
The amplification is small, but it's enough to make the signals compatible with the sound card's input. The circuit does not need any external power supply, it uses the bias voltage (around +5V) of the sound card.

Simple BFO Metal Detector Schematic Diagram

Simple BFO Metal Detector Schematic Diagram

This simple BFO metal detector requires only a few of components and an evening's work. The two oscillators are simple Colpitts designs using BJT transistors. The reference oscillator's frequency is approximately 370kHz, slightly tunable with the help of a silicon varactor diode. The outputs of the two oscillators are fed to a mixer made with Q3 and Q4. The signal then goes through a low-pass filter (R13, C13) and a JFET preamp. The LM386 audio amplifier has a gain of 20, more than enough for most headphones. If you need more gain, you can add a 10uF capacitor between pins 1 and 8.
Simple BFO metal detector
Fig. 1: Simple BFO metal detector schematic diagram

Parts list:

Resistors:

  • R1, R3, R5, R7: 22kΩ resistors
  • R2, R6: 1kΩ resistors
  • R4, R9, R12: 15kΩ resistors
  • R8, R10, R11: 47kΩ resistors
  • R13: 2.2kΩ resistor
  • R14: 1MΩ resistor
  • R15: 8.2kΩ resistor
  • R16: 680Ω resistor
  • R17: 10Ω resistor
  • P1: 10kΩ lin. potentiometer (Tune)
  • P2: 10kΩ log. potentiometer (Volume)

Other parts:

  • L1: 10cm (4in.) diameter, 20 turns, AWG 22
  • L1: 82uH inductor
  • SW1: SPDT toggle switch
  • J1: Headphone jack 1/4 or 1/8 inch

Capacitors:

  • C1, C6, C7, C12, C14: 100nF capacitors
  • C2, C8: 22nF low temp. coef. capacitors
  • C3, C9: 2.2nF low temp. coef. capacitors
  • C4, C10: 10pF ceramic capacitors
  • C5, C11: 4.7uF/16V electrolytic
  • C13: 10nF capacitor
  • C15: 47nF capacitor
  • C16, C17: 220uF/16V electrolytic

Active components:

  • D1: NTE618 silicon varactor diode (20-440pF)
  • Q1-Q4: 2N2222 NPN silicon transistors
  • Q5: 2N5951 JFET transistor
  • IC1: LM386 (Audio amplifier IC)
The coil should have 20 turns of 0.65 mm (AWG 22) enameled copper wire wound on a 10 cm (4in.) diameter form. Wrap the completed loop with strips of aluminum foil or copper shield tape, then connect the shield to the ground. Make sure the Faraday shield has a gap at one point, so it does not make a shorted loop. You should mechanically secure the coil to a nonmetallic form to prevent microphonics.
After assembly, connect the headphones and slowly turn P1. The pitch will get lower until it disappears. Continuing to rotate P1 in the same direction will cause the pitch to rise again. The point at witch the pitch is the lowest and disappears is called "zero beat". If you can not get this zero beat frequency for the entire turn of P1 you may have to increase or decrease the value of L2.
Turn P1 close to the zero beat position (a tone of 50Hz-200Hz), then move the search coil near a metallic object. The tone should change, depending on the size and distance of the metal.
Note: this simple circuit will only detect relative large metallic objects at a short distance. Coins and other small objects will be much harder to find! If you want to build a detector with a performance comparable to commercial products, try a PI or VLF design.

Glow Tile

Saturday, 2 April 2011

Telekinetic Pen

Mysterious Lightbulb Hack

LAZER SECURITY

555 TIMER WITH SPEAKER

VALENTINE HEART

This project flashes 18 LEDs at three different rates and you can use these to create an eye-catching Valentine Heart. The circuit is kept simple (and low cost) by using the 4060B IC which is a counter and oscillator (clock) in one package. The circuit requires a 9V supply, such as a PP3 battery. It will not work with lower voltages and a higher voltage will destroy the LEDs.
The preset variable resistor can be used to adjust the oscillator frequency and this determines the flash rate of the LEDs. The IC limits the current to and from its outputs so the LEDs can be safely connected without resistors in series to limit the current. The stripboard part of the circuit is easy to build but the wiring for the LEDs needs care so detailed instructions are provided below.
You can download our Valentine Heart template to print out and glue onto thick card, hardboard etc.
The Valentine Heart template is supplied as a PDF file. To view and print PDF files you need an Acrobat Reader which may be downloaded free for Windows, Mac, RISC OS, or UNIX/Linux computers. If you are not sure which type of computer you have it is probably Windows.
Warning!Valentine Heart
Using a battery (or power supply) with a voltage higher than 9V will destroy the LEDs.
You can see from the circuit diagram (below) that 6 LEDs are connected in series between the +9V supply and 0V. Each LED requires about 2V across it to light, so using a voltage of about 12V (= 6 × 2V) or more will make the LEDs conduct directly, regardless of the 4060B IC. With no series resistor to limit the current this will destroy the LEDs.


Parts Required

  • resistors: 10k, 470k
  • preset: 47k (this could be 100k if necessary)
  • capacitor: 0.1µF
  • 4060B IC
  • 16-pin DIL socket for IC
  • LEDs × 18, 5mm diameter, red (or any mix of red, orange, yellow and green)
  • on/off switch
  • battery clip for 9V PP3
  • stripboard 13 rows × 18 holes

Stripboard Layout

Stripboard layout for Valentine Heart project



Building the Circuit

  1. Begin by soldering the components onto the stripboard as shown in the diagram above. Do not insert the 4060B IC at this stage.
Arranging the LEDs:
  1. Cut out a suitable shape from stiff card (or similar material), such as the Valentine Heart template. Paint or colour the card at this stage if necessary.
  2. Plan the layout of the 18 LEDs (suggested positions are marked on the template).
  3. Drill 5mm holes for the LEDs - put the card on a piece of scrap wood to do this without damaging the card or the table.
  4. Push LEDs into the holes, they should be a fairly tight fit and glue should not be necessary.
  5. Label the LEDs D1 - D18 at random on the back of the card.
Wiring of the LEDs:
Use stranded wire for all the connections to the LEDs and solder all wires near to the LED body so the leads can be trimmed short later on.
The wire colours are suggested to avoid confusion but you can use other colours if you wish, the electricity won't mind! For example you could use red and black as suggested but substitute yellow and white for the blue and green suggested. LED with short lead cut
  1. Cut all the LED short leads to be very short to make identification easier:
  2. Connect RED wire to link up all the LONG leads of D1, D2 and D3.
    Remember to solder wires near to the LED body so the long lead can be trimmed short later on.
  3. Connect BLACK wire to link up all the SHORT leads of D16, D17 and D18.
  4. Use 3 pieces of BLUE wire to connect:
    • D7 short - D10 long
    • D8 short - D11 long
    • D9 short - D12 long
  5. Use 12 pieces of GREEN wire to connect:
    • D1 short - D4 long
    • D4 short - D7 long
    • D2 short - D5 long
    • D5 short - D8 long
    • D3 short - D6 long
    • D6 short - D9 long
    • D10 short - D13 long
    • D13 short - D16 long
    • D11 short - D14 long
    • D14 short - D17 long
    • D12 short - D15 long
    • D15 short - D18 long
  6. Connect the RED wire from the circuit board to the RED wiring on the Valentine heart (connect it to any convenient point).
  7. Connect the BLACK wire from the circuit board to the BLACK wiring on the Valentine heart (connect it to any convenient point).
  8. Connect the 3 BLUE wires from the circuit board to each of the 3 BLUE wires on the Valentine heart, they may be connected in any order.
  9. Carefully check all wiring.
  10. Trim the long LED leads.
  11. Plug the 4060B into its holder.
  12. Connect a 9V battery and switch on.
  13. Using a small screwdriver, adjust the 47k preset variable resistor to give a suitable flash rate for the LEDs.

Circuit diagram

Circuit diagram for Valentine Heart project

Light house

This project was designed for a model lighthouse to flash a lamp in a simple sequence: two flashes of 2s with a short gap of 1s, followed by a longer gap of 5s before repeating the sequence.
Lighthouse The 555 timer is connected as an astable to provide clock pulses for the 4017 counter. The 4017 has ten outputs (Q0 to Q9) and each one becomes high ('on') in turn as the clock pulses are received. Outputs Q0, Q1, Q3 and Q4 are combined with diodes to produce the flash sequence. A transistor amplifies the current to power the lamp, or LED if you prefer (a 470ohm LED resistor is included on the stripboard layout). The 1Mohm preset controls the time period (T) of the 555 astable from about 0.1s to 1.5s, for example set T = 1s.
For a different flash sequence connect the diodes to combine different 4017 outputs (Q0-Q9). If the full count from 0 to 9 is not required one of outputs can be connected to the reset input (pin 15). For example connecting Q8 (pi

Stripboard Layout

Stripboard layout for model lighthouse project



Circuit diagram

Circuit diagram for model lighthouse project

n 9) to reset (pin 15) reduces the long gap at the end of the sequence to 3s (with T=1s).
This project uses a 555 astable circuit to provide the clock pulses for the 4017 counter.
For information about lighthouses in the UK visit www.trinityhouse.co.uk

Parts Required

  • resistors: 470, 2k2, 22k, 100k
  • capacitors: 0.1µF, 1µF 16V radial
  • diodes: 1N4148 ×4
  • transistor: BC108 (or equivalent)
  • 1M preset, horizontal
  • 6V 60mA MES lamp
  • MES lampholder
  • 555 timer IC, such as NE555
  • 4017 counter IC
  • DIL sockets for ICs: 8-pin, 16-pin
  • on/off switch
  • battery clip
  • 9V battery box for 6 AA cells
  • stripboard: 19 rows × 21 holes

Model Railway Level Crossing Lights

Model Railway Level Crossing Lights
A kit for this project is available from RSH Electronics.
A magnet under the train operates reed switches positioned on the track. The trigger reed switch starts the sequence by switching on the amber light, a few seconds later the two red lights start to flash. When the train has passed the level crossing it operates the cancel reed switch which switches off the lights until the next train arrives.
There is a PCB pattern for this project, but if you don't have facilities to make PCBs you can build this project on stripboard instead. Please see the New Railway Modellers website for a stripboard layout and advice on making model lamps and barriers.
This project uses a 555 monostable circuit to switch on the amber LED for a few seconds. When this switches off it triggers a 555 bistable circuit which switches on a 555 astable circuit to flash the red LEDs.


Parts Required
  • resistors: 680 ×3, 1k ×3, 33k, 47k, 82k, 270k
  • capacitors: 0.1µF ×3, 10µF radial ×2
  • red LED (3mm best) ×2
  • amber* (or yellow) LED (3mm best)
    *
    some amber LEDs are too orange to look correct, yellow may be better
  • 555 timer IC ×3
  • 8-pin DIL socket for IC ×3
  • on/off switch
  • battery clip
  • reed switch ×2
  • miniature magnet - each locomotive needs one
  • printed circuit board (PCB) - pattern given below


PCB component layout


Track connections
The reed switches can be held in place between the rails with a small piece of blu tac.
Each locomotive will need a miniature magnet glued to its underside, test first with blu tac, then use superglue.


Circuit diagram
Circuits: 555 monostable (on left) | 555 bistable (in middle) | 555 astable (on right)


PCB copper track pattern






Stripboard layout
If you don't have facilities to make your own PCB you can build this project on stripboard. Please see the New Railway Modellers website for a stripboard layout as well as advice on making model lamps and barriers.