Tuesday, September 30, 2008

Line Follower ROBOT


Award winner from VingPeaw Competition 2543, the robot built with 2051, L293D, and four IR sensors. Simple circuit and platform, quick tracking and easy-understand program using C language.

This Robot use two motors control rear wheels and the single front wheel is free. It has 4-infrared sensors on the bottom for detect black tracking tape, when the sensors detected black color, output of comparator, LM324 is low logic and the other the output is high.
Microcontrollor AT89C2051 and H-Bridge driver L293D were used to control direction and speed of motor.



Circuit diagram Robot.



Circuit diagram of Infrared sensors and comparators.


Position of sensors, left hand side is side view and right hand side is top view.
Software
Software for write to AT89C2051 is robot1.hex ,which was written by C-language ,the source code is robot1.ccompiled by using MC51 in TINY model with my start up code robot.asm .

Automatic Load Sensing Power Switch


Part- Total Qty.- Description
C1, C3 -2- 10uF 35V Electrolytic Capacitor
C2 -1- 1uF 35V Electrolytic Capacitor
R1 -1- 0.1 Ohm 10W Resistor
R2 -1- 27K 1/2W Resistor
R3, R4 -1- 1K 1/4W Resistor
R5 -1- 470K 1/4W Resistor
R6 -1- 4.7K 1/2W Resistor
R7 -1- 10K 1/4W Resistor
D1, D2, D4 -3- 1N4004 Rectifier Diode
D3 -1- 1N4744 15V 1 Watt Zener Diode
U1 -1- LM358N Dual Op Amp IC
Q1 -1- 2N3904 NPN Transistor
K1 -1- Relay, 12VDC Coil, 120VAC 10A Contacts
S1 -1- SPST Switch 120AVC, 10A
MISC -1- Board, Wire, Socket For U1, Case, Mains Plug, Socket

Notes



This circuit is designed for 120V operation. For 240V operation, resistors R2 and R6 will need to be changed.

A maximum of 5A can be used as the master unless the wattage of R1 is increased

S1 provides a manual bypass switch.

THis circuit is not isolated from the mains supply. Because of this, you must exercise extreme caution when working around the circuit if it is plugged in.

Source: aaroncake.net

AC Motor Speed Controller



Part-Total Qty.
R1 -1- 27K 1W Resistor
R2 -1 -10K 1/4W Resistor
R3 -1- 100K 1/4W Resistor
R4 -1 -33K 1/4W Resistor
R5 -1- 2.2K 1/4W Resistor
R6 -1- 1K 1/4W Resistor
R7 -1- 60K Ohm 1/4W Resistor
R8 -1- 3K Linear Taper Trim Pot
R9 -1- 5K Linear Taper Pot
R10 -1- 4.7K Linear Taper Trim Pot
R11 -1- 3.3K 1/4W Resistor
R12 -1- 100 Ohm 1/4W Resistor
R13 -1- 47 Ohm 1W Resistor (See Notes)
C1, C3 -2- 0.1uF Ceramic Disc Capacitor
C2 -1- 100uF 50V Electrolytic Capacitor
D1 -1- 6V Zener Diode
Q1 -1- 2N2222 NPN Transistor 2N3904
SCR1 -1- ECG5400
TR1 -1- TRIAC (See Notes)
U1 -1- DIAC Opto-Isolator (See Notes)
BR1, BR2 -2- 5A 50V Bridge Rectifier
T1 -1- Transformer (See Notes)
MISC -1- PC Board, Case, Line Cord, Socket For U1, Heatsinks

Notes

TR1 must be chosen to match the requirements of the load. Most generic TRIACs with ratings to support your load will work fine in this circuit. If you find a TRIAC that works well, feel free to leave a comment.

U1 must be chosen to match the ratings of TR1. Most generic DIAC based opto-isolators will work fine. If you have success with a specific part, feel free to leave a comment.

T1 is any small transformer with a 1:10 turns ratio. The circuit is designed to run on 120V so a 120V to 12V transformer will work. Alternately, you can wind T1 on a transformer core using a primary of 25 turns, a secondary of 200 turns, and 26 gauge magnet wire.

R9 is used to adjust motor speed. R10 is a trim pot used to fine tune the governing action of the circuit. R8 fine tunes the feedback circuit to adjust for proper voltage at the gate of SCR1. It should be adjusted to just past the minimum point at which the circuit begins to operate.

R13 must be chosen to match the load. Generally, larger loads will require a smaller value.

Since this circuit is not isolated from mains, it must be built in an insulated case.

Source - Aaroncake.net

Temperature-controlled Fan




Parts:
P1_____________22K Linear Potentiometer (See Notes)

R1_____________15K @ 20°C n.t.c. Thermistor (See Notes)
R2____________100K 1/4W Resistor
R3,R6__________10K 1/4W Resistors
R4,R5__________22K 1/4W Resistors
R7____________100R 1/4W Resistor
R8____________470R 1/4W Resistor
R9_____________33K 4W Resistor

C1_____________10nF 63V Polyester Capacitor

D1________BZX79C18 18V 500mW Zener Diode
D2_________TIC106D 400V 5A SCR
D3-D6_______1N4007 1000V 1A Diodes

Q1,Q2________BC327 45V 800mA PNP Transistors
Q3___________BC337 45V 800mA NPN Transistor

SK1__________Female Mains socket

PL1__________Male Mains plug & cable

Device purpose:
This circuit adopt a rather old design technique as its purpose is to vary the speed of a fan related to temperature with a minimum parts counting and avoiding the use of special-purpose ICs, often difficult to obtain.

Circuit operation:
R3-R4 and P1-R1 are wired as a Wheatstone bridge in which R3-R4 generate a fixed two-thirds-supply "reference" voltage, P1-R1 generate a temperature-sensitive "variable" voltage, and Q1 is used as a bridge balance detector.
P1 is adjusted so that the "reference" and "variable" voltages are equal at a temperature just below the required trigger value, and under this condition Q1 Base and Emitter are at equal voltages and Q1 is cut off. When the R1 temperature goes above this "balance" value the P1-R1 voltage falls below the "reference" value, so Q1 becomes forward biased, pulse-charging C1.
This occurs because the whole circuit is supplied by a 100Hz half-wave voltage obtained from mains supply by means of D3-D6 diode bridge without a smoothing capacitor and fixed to 18V by R9 and Zener diode D1. Therefore the 18V supply of the circuit is not true DC but has a rather trapezoidal shape. C1 provides a variable phase-delay pulse-train related to temperature and synchronous with the mains supply "zero voltage" point of each half cycle, thus producing minimal switching RFI from the SCR. Q2 and Q3 form a trigger device, generating a short pulse suitable to drive the SCR.

Device purpose:
This circuit adopt a rather old design technique as its purpose is to vary the speed of a fan related to temperature with a minimum parts counting and avoiding the use of special-purpose ICs, often difficult to obtain.

Circuit operation:
R3-R4 and P1-R1 are wired as a Wheatstone bridge in which R3-R4 generate a fixed two-thirds-supply "reference" voltage, P1-R1 generate a temperature-sensitive "variable" voltage, and Q1 is used as a bridge balance detector.
P1 is adjusted so that the "reference" and "variable" voltages are equal at a temperature just below the required trigger value, and under this condition Q1 Base and Emitter are at equal voltages and Q1 is cut off. When the R1 temperature goes above this "balance" value the P1-R1 voltage falls below the "reference" value, so Q1 becomes forward biased, pulse-charging C1.
This occurs because the whole circuit is supplied by a 100Hz half-wave voltage obtained from mains supply by means of D3-D6 diode bridge without a smoothing capacitor and fixed to 18V by R9 and Zener diode D1. Therefore the 18V supply of the circuit is not true DC but has a rather trapezoidal shape. C1 provides a variable phase-delay pulse-train related to temperature and synchronous with the mains supply "zero voltage" point of each half cycle, thus producing minimal switching RFI from the SCR. Q2 and Q3 form a trigger device, generating a short pulse suitable to drive the SCR.

Notes:
The circuit is designed for 230Vac operation. If your ac mains is rated at about 115V, you can change R9 value to 15K 2W. No other changes are required.
Circuit operation can be reversed, i.e. the fan increases its speed as temperature decreases, by simply transposing R1 and P1 positions. This mode of operation is useful in controlling a hot air flux, e.g. using heaters.
Thermistor value is not critical: I tried also 10K and 22K with good results.
In this circuit, if R1 and Q1 are not mounted in the same environment, the precise trigger points are subject to slight variation with changes in Q1 temperature, due to the temperature dependence of its Base-Emitter junction characteristics. This circuit is thus not suitable for use in precision applications, unless Q1 and R1 operate at equal temperatures.
The temperature / speed-increase ratio can be varied changing C1 value. The lower the C1 value the steeper the temperature / speed-increase ratio curve and vice-versa.
Warning! The circuit is connected to 230Vac mains, then some parts in the circuit board are subjected to lethal potential! Avoid touching the circuit when plugged and enclose it in a plastic box.

Source- Redcircuits
The circuit is designed for 230Vac operation. If your ac mains is rated at about 115V, you can change R9 value to 15K 2W. No other changes are required.
Circuit operation can be reversed, i.e. the fan increases its speed as temperature decreases, by simply transposing R1 and P1 positions. This mode of operation is useful in controlling a hot air flux, e.g. using heaters.
Thermistor value is not critical: I tried also 10K and 22K with good results.
In this circuit, if R1 and Q1 are not mounted in the same environment, the precise trigger points are subject to slight variation with changes in Q1 temperature, due to the temperature dependence of its Base-Emitter junction characteristics. This circuit is thus not suitable for use in precision applications, unless Q1 and R1 operate at equal temperatures.
The temperature / speed-increase ratio can be varied changing C1 value. The lower the C1 value the steeper the temperature / speed-increase ratio curve and vice-versa.
Warning! The circuit is connected to 230Vac mains, then some parts in the circuit board are subjected to lethal potential! Avoid touching the circuit when plugged and enclose it in a plastic box.

Plant Moisture Meter



Stick the metal probes into a freshly watered plant and adjust R5 for a mid-scale meter deflection. The meter will monitor the soil wetness and the meter will indicate whether it is to moist or to dry. This circuit uses a dual power supply which could be created by two 9 volt batteries.

Game Show Indicator Lights (Who's First)


The circuit below turns on a light corresponding to the first of several buttons pressed in a "Who's First" game. Three stages are shown but the circuit can be extended to include any number of buttons and lamps.
Three SCRs (silicon controlled rectifiers) are connected with a common cathode resistor (50 ohm) so that when any SCR conducts, the voltage on the cathodes will rise about 7 volts above the voltage at the junction of the 51K and 1K ohm resistors and prevent triggering of a second SCR. When all lamps are off, and a button is pressed, the corresponding SCR is triggered due to the voltage at the divider junction being higher than the cathode. Once triggered, the SCR will remain conducting until current is interrupted by the reset switch. Or, you can just turn the power off and back on.

A 50 ohm, 5 watt resistor was selected to produce a 10 volt drop at 200 mA when a single 25 watt lamp comes on. Higher wattage lamps would require a lower value resistor, and visa versa. For example to use 60 watt lamps and maintain the 10 volt drop, the peak current would be 60/160 = 375 mA and the resistance would be E/I = 10/.375 or about 27 ohms at 3.75 watts. The SCRs are "Sensitive Gate' types which trigger on about 200 uA and the gate current is around 1.5 mA when the first button is pressed. The 1N914 diodes in series with the buttons gates are used to prevent a reverse voltage on the gate when a button is pressed after an SCR is conducting. The two resistors (1K and 50 ohm) will be fairly large in physical size (compared to a 1/4 watt size) and should be rated for 5 watts of power or more. Use caution and do not touch any components while the circuit is connected to the AC line.

Adding a Buzzer:

The relay shown in parallel with the 50 ohm cathode resistor can be used to momentarily power a buzzer with an external circuit through the contacts. The 1000 uF capacitor causes the relay to energize for about one second, longer times can be obtained with a larger capacitor.


Parts List:

Quantity - Description

1 - 4 Amp/400 Volt Bridge Rectifier
3 - Silicon Controlled Rectifier (SCR)
3 - 120 VAC/ 25 Watt incandescent lamp
1 - 50-100 microfarad/ 200 volt capacitor
1 - 1000 microfarad / 35 volt capacitor
1 - 50 ohm resistor/ 5 or 10 Watt
3 - Push Button Switch (normally open)
1 - Push Button Switch (normally closed)
3 - 2K resistor, 1/4 watt
4 - 1N914 Diode
1 - 51K resistor, 1 watt
1 - 2 Amp Fuse
1 - Relay (SPDT) 9 Volt DC, 500 ohm coil

DC Motor Reversing Circuit



Description:
A DC motor reversing circuit using non latching push button switches. Relays control forward, stop and reverse action, and the motor cannot be switched from forward to reverse unless the stop switch is pressed first.
Notes:
Except for the back emf diodes across the relay coils this circuit is identical in function to the example shown on the relay contact labeling guide in the practical section. At first glance this may look over-complicated, but this is simply because three non-latching push button switches are used. When the forward button is pressed and released the motor will run continuously in one direction. The Stop button must be used before pressing the reverse button. The reverse button will cause the motor to run continuously in the opposite direction, or until the stop button is used. Putting a motor straight into reverse would be quite dangerous, because when running a motor develops a back emf voltage which would add to current flow in the opposite direction and probably cause arcing of the relay contacts. This circuit has a built-in safeguard against that condition.

Circuit Operation:
Assume that the motor is not running and that all relays are unenergized. When the forward button is pressed, a positive battery is applied via the NC contacts of B1 to the coil of relay RA/2. This will operate as the return path is via the NC contacts of D1. Relay RA/2 will operate. Contacts A1 maintain power to the relay even though the forward button is released. Contacts A2 apply power to the motor which will now run continuously in one direction. If now the reverse button is pressed, nothing happens because the positive supply for the switch is fed via the NC contact A1, which is now open because Relay RA/2 is energized. To Stop the motor the Stop switch is pressed, Relay D operates and its contact D1 breaks the power to relays A and B, (only Relay A is operated at the moment). If the reverse switch is now pressed and released. Relay B operates via NC contact A1 and NC contact D1. Contact B1 closes and maintains power so that the relay is now latched, even when the reverse switch is opened. Relay RC/2 will also be energized and latched. Contact B2 applies power to the motor but as contacts C1 and C2 have changed position, the motor will now run continuously in the opposite direction. Pressing the forward button has no effect as power to this switch is broken via the now open NC contact B1. If the stop button is now pressed. Relay D energizes, its contact D1 breaks power to relay B, which in turn breaks power to relay C via the NO contact of B1 and of course the motor will stop. All very easy. The capacitor across relay D is there to make sure that relay D will operate at least longer than the time relays A,B and C take to release.

Correction to Diagram
In the original circuit a diode was omitted, this is the diode now in series with relay coils RA and RD. Special thanks to Christian Sanchez from Ecuador for pointing this mistake out. Without the diode relay RA remains energized, its holding current path is through relay coils RB and RC, the diode now breaks the path,

Saturday, September 27, 2008

Simple Servo Controller



Parts

Part - TotalQty. - Description
R1 - 1 - 820 Ohm 1/4W Resistor
R2 - 1 - 68K 1/4W Resistor
R3 - 1 - 10K 1/4W Resistor
R4 - 1 - 1K 1/4W Resistor
R5 - 1 - 1K Linear Taper Pot
C1 - 1 - 1uF 16V Electrolytic Capacitor
Q1 - 1 - 2N3904 NPN Transistor or 2N2222, Most Small Signal Transistors
U1 - 1 - 555 Timer IC
MISC - 1 - Board, Wire, Knob For R1, 8 Pin Socket For U1

Notes

R1 adjusts the position of the servo.

Connect the servo to the circuit as shown in the schematic. For common Futaba servos, the red wire is power, the black wire is ground, and the white wire is control.

Cellular Phone calling Detector



Parts:
R1____________100K 1/4W Resistor
R2______________3K9 1/4W Resistor
R3______________1M 1/4W Resistor

C1,C2_________100nF 63V Polyester Capacitors
C3____________220µF 25V Electrolytic Capacitor

D1______________LED Red 10mm. Ultra-bright (see Notes)
D2___________1N5819 40V 1A Schottky-barrier Diode (see Notes)

Q1____________BC547 45V 100mA NPN Transistor

IC1____________7555 or TS555CN CMos Timer IC

L1_____________Sensor coil (see Notes)

B1_____________1.5V Battery (AA or AAA cell etc.)



This circuit was designed to detect when a call is incoming in a cellular phone (even when the calling tone of the device is switched-off) by means of a flashing LED.
The device must be placed a few centimeters from the cellular phone, so its sensor coil L1 can detect the field emitted by the phone receiver during an incoming call.

The signal detected by the sensor coil is amplified by transistor Q1 and drives the monostable input pin of IC1. The IC's output voltage is doubled by C2 & D2 in order to drive the high-efficiency ultra-bright LED at a suitable peak-voltage.

3 Transistor Audio Amp (80 milliwatt)



This circuit is similar to the one above but uses positive feedback to get a little more amplitude to the speaker. I copied it from a small 5 transistor radio that uses a 25 ohm speaker. In the circuit above, the load resistor for the driver transistor is tied directly to the + supply. This has a disadvantage in that as the output moves positive, the drop across the 470 ohm resistor decreases which reduces the base current to the top NPN transistor. Thus the output cannot move all the way to the + supply because there wouldn't be any voltage across the 470 resistor and no base current to the NPN transistor.
This circuit corrects the problem somewhat and allows a larger voltage swing and probably more output power, but I don't know how much without doing a lot of testing. The output still won't move more than a couple volts using small transistors since the peak current won't be more than 100mA or so into a 25 ohm load. But it's an improvement over the other circuit above.

In this circuit, the 1K load resistor is tied to the speaker so that as the output moves negative, the voltage on the 1K resistor is reduced, which aids in turning off the top NPN transistor. When the output moves positive, the charge on the 470uF capacitor aids in turning on the top NPN transistor.

The original circuit in the radio used a 300 ohm resistor where the 2 diodes are shown but I changed the resistor to 2 diodes so the amp would operate on lower voltages with less distortion. The transistors shown 2n3053 and 2n2905 are just parts I used for the other circuit above and could be smaller types. Most any small transistors can be used, but they should be capable of 100mA or more current. A 2N3904 or 2N3906 are probably a little small, but would work at low volume.

The 2 diodes generate a fairly constant bias voltage as the battery drains and reduces crossover distortion. But you should take care to insure the idle current is around 10 to 20 milliamps with no signal and the output transistors do not get hot under load.

The circuit should work with a regular 8 ohm speaker, but the output power may be somewhat less. To optimize the operation, select a resistor where the 100K is shown to set the output voltage at 1/2 the supply voltage (4.5 volts). This resistor might be anything from 50K to 700K depending on the gain of the transistor used where the 3904 is shown.

LED Photo Sensor



Here's a circuit that takes advantage of the photo-voltaic voltage of an ordinary LED. The LED voltage is buffered by a junction FET transistor and then applied to the inverting input of an op-amp with a gain of about 20. This produces a change of about 5 volts at the output from darkness to bright light. The 100K potentiometer can be set so that the output is around 7 volts in darkness and falls to about 2 volts in bright light.

AC Line Current Detector



This circuit will detect AC line currents of about 250 mA or more without making any electrical connections to the line. Current is detected by passing one of the AC lines through an inductive pickup (L1) made with a 1 inch diameter U-bolt wound with 800 turns of #30 - #35 magnet wire. The pickup could be made from other iron type rings or transformer cores that allows enough space to pass one of the AC lines through the center. Only one of the current carrying lines, either the line or the neutral should be put through the center of the pickup to avoid the fields cancelling. I tested the circuit using a 2 wire extension cord which I had separated the twin wires a small distance with an exacto knife to allow the U-bolt to encircle only one wire.
The magnetic pickup (U-bolt) produces about 4 millivolts peak for a AC line current of 250 mA, or AC load of around 30 watts. The signal from the pickup is raised about 200 times at the output of the op-amp pin 1 which is then peak detected by the capacitor and diode connected to pin 1. The second op-amp is used as a comparator which detects a voltage rise greater than the diode drop. The minimum signal needed to cause the comparator stage output to switch positive is around 800 mV peak which corresponds to about a 30 watt load on the AC line. The output 1458 op-amp will only swing within a couple volts of ground so a voltage divider (1K/470) is used to reduce the no-signal voltage to about 0.7 volts. An additional diode is added in series with the transistor base to ensure it turns off when the op-amp voltage is 2 volts. You may get a little bit of relay chatter if the AC load is close to the switching point so a larger load of 50 watts or more is recommended. The sensitivity could be increased by adding more turns to the pickup.

Touch Activated Light



The circuits below light a 20 watt lamp when the contacts are touched and the skin resistance is about 2 Megs or less. The circuit on the left uses a power MOSFET which turns on when the voltage between the source and gate is around 6 volts. The gate of the MOSFET draws no current so the voltage on the gate will be half the supply voltage or 6 volts when the resistance across the touch contacts is equal to the fixed resistance (2 Megs) between the source and gate.
The circuit on the right uses three bipolar transistors to accomplish the same result with the touch contact referenced to the negative or ground end of the supply. Since the base of a bipolar transistor draws current and the current gain is usually less than 200, three transistors are needed to raise the microamp current level through the touch contacts to a couple amps needed by the light. For additional current, the lamp could be replaced with a 12 volt relay and diode across the coil.

DC Motor Control Circuit




Notes:
Here, S1 and S2 are normally open , push to close, press button switches. The diodes can be red or green and are there only to indicate direction. You may need to alter the TIP31 transistors depending on the motor being used. Remember, running under load draws more current.This circuit was built to operate a small motor used for opening and closing a pair of curtains. As an advantage over automatic closing and opening systems, you have control of how much, or how little light to let into a room.The four diodes surriunding the motor, are back EMF diodes. They are chosen to suit the motor. For a 12V motor drawing 1amp under load, I use 1N4001 diodes.

Light Detector Circuit



Notes:
Variable resistor R1 adjusts the light threshold at which the circuit triggers. R1's value is chosen to match the photocells resistance at darkness. The circuit uses a CMOS 4001 IC. Gate U1a acts as the trigger, U1b and c form a latch. S1 resets the circuit. The output device may be a low power piezo buzzer.

Dark Activated Switch




Description:
This circuit will activate a relay when light falls to a preset level. Light level can be adjusted with VR1 and the relay contacts may be used to operate an external light or buzzer.



Notes:
The light sensor used is the ORP12 photocell. In bright light the resistance of the ORP12 can be as low as 80 ohm and at 50lux (darkness) the resistance increases to over 1 Mohm. The 1M control should provide a wide range for light intensities, if not its value may be increased. The op-amp senses the voltage difference between pins 2 and 3. The control VR1 is adjusted so that the relay is off, the output of the op-amp will be around 2 Volts. When light falls, the resistance of the photocell increases and the difference in input voltage is amplified by the op-amp, the output will swing towards full supply and drive the transistor and relay. The 270k resistor provides a small amount of hysteresis, so that the circuit switches on and off with slightly different light levels. This eliminates relay chatter. Take great care if you decide to wire the relay to activate a mains lamp. Make sure the relay contacts provide adequate isolation and have ample rating for the load.

Parts List:
ORP12 Photocell (1)
RLY1: 12VSPDT (1)
U1: UA741 (1)
Q1: BC109 NPN (1)
D1: 1N4002 DIODE (1)
F1: 1A (1)
VR1: 1M RESISTOR (1)
ORP12: 500K RESISTOR (1)
R1,R3,R2: 10k RESISTOR (3)
R5: 4.7k RESISTOR (1)
R6: 1k RESISTOR (1)
R4: 270k RESISTOR (1)