Tuesday, June 28, 2011

Intelligent Presence Simulator circuit and explanation

However effective a domestic alarm system may be, it’s invariably better if it never goes off, and the best way to ensure this is to make potential burglars think the premises are occupied. Indeed, unless you own old masters or objects of great value likely to attract ‘professional’ burglars, it has to be acknowledged that the majority of burglaries are committed by ‘petty’ thieves who are going to be looking more than anything else for simplicity and will prefer to break into homes whose occupants are away.

Rather than simply not going on holiday – which is also one solution to the problem (!) – we’re going to suggest building this intelligent presence simulator which ought to put potential burglars off, even if your home is subjected to close scrutiny. Like all its counterparts, the proposed circuit turns one or more lights on and off when the ambient light falls, but while many devices are content to generate fixed timings, this one works using randomly variable durations.
Intelligent Presence Simulator Circuit Diagram

So while other devices are very soon caught out simply by daily observation (often from a car) because of their too-perfect regularity, this one is much more credible due to the fact that its operating times are irregular. The circuit is very simple, as we have employed a microcontroller – a ‘little’ 12C508 from Microchip, which is more than adequate for such an application. It is mains powered and uses rudimentary voltage regulation by a zener diode.

A relay is used to control the light(s); though this is less elegant than a triac solution, it does avoid any interference from the mains reaching the microcontroller, for example, during thunderstorms. We mustn’t forget this project needs to work very reliably during our absence, whatever happens. The ambient light level is measured by a conventional LDR (light dependent resistor), and the lighting switching threshold is adjustable via P1 to suit the characteristics and positioning of the LDR.

Note that input GP4 of the PIC12C508 is not analogue, but its logic switching threshold is very suitable for this kind of use. The LED connected to GP1 indicates the circuit’s operating mode, selected by grounding or not of GP2 or GP3 via override switch S1. So there are three possible states: permanently off, permanently on, and automatic mode, which is the one normally used. Given the software programmed into the 12C508 (‘firmware’) and the need to generate very long delays so as to arrive at lighting times or an hour or more, it has been necessary to make the MCU operate at a vastly reduced clock frequency.

PCB Layout:
PCB Layout Of Intelligent Presence Simulator

In that case, a crystal-controlled clock is no longer suitable, so the R-C network R5/C3 is used instead. For sure, such a clock source is less stable than a crystal, but then in an application like this, that may well be what we’re after as a degree of randomness is a design target instead of a disadvantage. Our suggested PCB shown here takes all the components for this project except of course for S1, S2, and the LDR, which will need to be positioned on the front panel of the case in order to sense the ambient light intensity.

The PCB has been designed for a Finder relay capable of switching 10 A, which ought to prove adequate for lighting your home, unless you live in a replica of the Palace of Versailles. The program to be loaded into the 12C508 is available for free download from the Elektor website as file number 080231-11.zip or from the author’s own website: www.tavernier-c.com. On completion of the solder work the circuit should work immediately and can be checked by switching to manual mode.

The relay should be released in the ‘off’ position and energized in the ‘on’ position. Then all that remains is to adjust the day/night threshold by adjusting potentiometer P1. To do this, you can either use a lot of patience, or else use a voltmeter – digital or analogue, but the latter will need to be electronic so as to be high impedance – connected between GP4 and ground. When the light level below which you want the lighting to be allowed to come on is reached, adjust P1 to read approximately 1.4 V on the voltmeter.

If this value cannot be achieved, owing to the characteristics of your LDR, reduce or increase R8 if necessary to achieve it (LDRs are known to have rather wide production tolerances). Equipped with this inexpensive accessory, your home of course hasn’t become an impregnable fortress, but at least it ought to appear less attractive to burglars than houses that are plunged into darkness for long periods of time, especially in the middle of summer. (www.tavernier-c.com)

COMPONENTS LIST
Resistors
R1 = 1k 500mW
R2 = 4k7
R3 = 560R
R4,R6 = 10k
R5 = 7k5
R 7 = LDR
R8 = 470k to 1 M
P1 = 470k potentiometer
Capacitors
C1 = 470µF 25V
C2 = 10µF 25V
C3 = 1nF5
C4 = 10nF
Semiconductors
D1,D2 = 1N4004
D3 = diode zener 4V7 400 mW
LED1 = LED, red
D4 = 1N4148
T1 = BC547
IC1 = PIC12C508, programmed, see Downloads
Miscellaneous
RE1 = relay, 10A contact
S1 = 1-pole 3-way rotary switch
F1 = fuse 100 mA
TR1 = Mains transformer 2x9 V, 1.2 -3 VA
4 PCB terminal blocks, 5 mm lead pitch
5 solder pins

Downloads:

The PCB layout can be downloaded free from our website www.elektor.com; file # 080231-1.
The source code and .hex files for this project are available free on www.elektor.com; file # 080231-11.zip

Monday, June 27, 2011

Design of metal detector using the induction balance system application

ABSTRACT: An embedded system logic approach was used to achieve metal detection,. The controller is simulated to realize . Three technologies were used Very low frequency (VLF) Pulse induction (PI) Beat-frequency oscillation (BFO) , The issue of safety and security were also emphasized.
Keyword: Microcontroller, low frequency, detector, security, oscillators, sensors
1.0                   INTRODUCTION
Towards the end of the 19th century, many scientists and engineers used their growing knowledge of electrical theory in an attempt to devise a machine which would pinpoint metal. The use of such a device to find ore-bearing rocks would give a huge advantage to any miner who employed it. The German physicist Heinrich Wilhelm Dove invented the induction balance system, which was incorporated into metal detectors a hundred years later. Early machines were crude, used a lot of battery power, and worked only to a very limited degree. Alexander Graham Bell used such a device to attempt to locate a bullet lodged in the chest of American President James Garfield in 1881; the attempt was unsuccessful because the metal bed Garfield was lying on confused the detector.[1]
1.2  Trends
Many manufacturers of these new devices brought their own ideas to the market. Whites Electronics of Oregon began in the 50′s by building a machine called the Oremaster Geiger Counter. Another leader in detector technology was Charles Garrett, who pioneered the BFO (Beat Frequency Oscillator) machine. With the invention and development of the transistor in the 50′s and 60′s, metal detector manufacturers and designers made smaller lighter machines with improved circuitry, running on small battery packs. Companies sprang up all over the USA and Britain to supply the growing demand.[2]
Larger portable metal detectors are used by archaeologists and treasure hunters to locate metallic items, such as jewelry, coins, bullets, and other various artifacts buried shallowly underground.[3]
1.3       METHODOLOGY
Metal detectors use one of three technologies:
Very low frequency (VLF)
Pulse induction (PI)
Beat-frequency oscillation (BFO)
Before going to my own design technique which is beat-frequency oscillation let me briefly introduce the other technologies.   [4]
1.4                   VLF Technology
Very low frequency (VLF), also known as induction balance, is probably the most popular detector technology in use today. In a VLF metal detector, there are two distinct coils:
Transmitter coil – This is the outer coil loop. Within it is a coil of wire. Electricity is sent along this wire, first in one direction and then in the other, thousands of times each second. The number of times that the current’s direction switches each second establishes the frequency of the unit.
Receiver coil – This inner coil loop contains another coil of wire. This wire acts as an antenna to pick up and amplify frequencies coming from target objects in the ground. [5]
The current moving through the transmitter coil creates an electromagnetic field, which is like what happens in an electric motor. The polarity of the magnetic field is perpendicular to the coil of wire. Each time the current changes direction, the polarity of the magnetic field changes. This means that if the coil of wire is parallel to the ground, the magnetic field is constantly pushing down into the ground and then pulling back out of it.
1.5                   PI Technology
A less common form of metal detector is based on pulse induction (PI). Unlike VLF, PI systems may use a single coil as both transmitter and receiver, or they may have two or even three coils working together. This technology sends powerful, short bursts (pulses) of current through a coil of wire. Each pulse generates a brief magnetic field. When the pulse ends, the magnetic field reverses polarity and collapses very suddenly, resulting in a sharp electrical spike. This spike lasts a few microseconds (millionths of a second) and causes another current to run through the coil. This current is called the reflected pulse and is extremely short, lasting only about 30 microseconds. Another pulse is then sent and the process repeats. A typical PI-based metal detector sends about 100 pulses per second, but the number can vary greatly based on the manufacturer and model, ranging from a couple of dozen pulses per second to over a thousand. Pulse Induction detectors are now widely used in the construction industry; the Whites PI-150 is an industrial machine which can detect large objects to 10 feet, using a 12 or 15 coil.
 2.0    MODULE ANALYSIS
Dc power supply
This unit supplies the necessary d.c voltages for the circuit operation
Reference coil oscillator
This oscillator contains the reference coil as the inductive element and set the frequency to which that from the oscillator two is referred to.
Search coil oscillator
This is the second oscillator which contains the search coil as its inductive element. The inductance of the search coil changes when it locates a metal, which in turn changes the frequency of the oscillator. This frequency is compared with that from the oscillator one to produce a beat note.
Mixer
The pulses produced by each oscillator are mixed in the mixer unit and the sum filtered to ground.
Gain filter
The gain filter processes and amplifies the difference of the mixed pulses from the mixer and drives a piezo buzzer with it.
Output transducer(load)
The output transducer converts the electrical signal into audible sound to give an audio indication of the presence of a metal.
2.1   OBJECTIVE
The aim of the project is to ease the trouble of trying to locate a useful metallic object in a particular or specified environment. As the trouble of straining the eyes is drastically reduced when the metal detector is used in the workshop where small metallic components could be easily misplaced. Also at security posts for searching people and their luggage.
P=I2R= IV= V2/R
All three equations are equivalent. The first is derived from Joule’s law, and the other two are derived from that by Ohm’s Law.
The total amount of heat energy released is the integral of the power over time:
W= ∫v(t)i(t)dt.
If the average power dissipated exceeds the power rating of the resistor, the resistor may depart from its nominal resistance, and may be damaged by overheating. Excessive power dissipation may raise the temperature of the resistor to a point where it burns out, which could cause a fire in adjacent components and materials.
2.2   Series and parallel circuits
Parallel circuit
Resistors in a parallel co nfiguration each have the same potential difference (voltage). To find their total equivalent resistance (Req):
1/Req = 1/R1 + 1/ R2….. +.. 1/ Rn
The parallel property can be represented in equations by two vertical lines “||” (as in geometry) to simplify equations. For two resistors,
Req = R1//R2= R1R2/(R1+R2)
Series circuit
The current through resistors in series stays the same, but the voltage across each resistor can be different. The sum of the potential differences (voltage) is equal to the total voltage. To find their total resistance:
Req= R1 + R2 +…..+ R2
Parallel and series network
A resistor network that is a combination of parallel and series can sometimes be broken up into smaller parts that are either one or the other. For instance,
Req = (R1//R2) + R3= (R1R2)/(R1+R2)+R3
However, many resistor networks cannot be split up in this way. Consider a cube, each edge of which has been replaced by a resistor. For example, determining the resistance between two opposite vertices requires matrix methods for the general case. However, if all twelve resistors are equal, the corner-to-corner resistance is 5⁄6 of any one of them.
2.3                   Electric circuits
When a capacitor is connected to a current source, charge is transfered between its plates at a rate i(t) = dq(t) / dt. As the voltage between the plates is proportional to the charge, it follows that
V(t) = 1/c q(t) = 1/c∫i(τ)d τ
Conversely, if a capacitor is connected to a voltage source, the resulting displacement current is given by
I(t)Cdv(t)/dt
For example, if one were to connect a 1000 µF capacitor to a voltage source, then increase the sourced voltage at a rate of 2.5 Volts per second, the current flowing through the capacitor would be
I= Cdv/dt =(1000×10-6F)(2.5V/s)=2.5mA
Ø   DC sources
A circuit containing only a resistor, a capacitor, a switch and a constant (DC) voltage source vsrc(t) = V0 in series is known as a charging circuit. From Kirchhoff’s voltage law it follows that
Vo=Vr(t) + Vc(t) = i(t)R I/C∫ i(τ)dτ
where vr(t) and vc(t) are the voltages across the resistor and capacitor respectively. This reduces to a first order differential equation
Assuming that the capacitor is initially uncharged, there is no internal electric field, and the initial current is I0 = V0 / R. This initial condition allows solution of the differential equation as
.i=Vo/Rexp(-t/RC)
The corresponding voltage drop across the capacitor is
v(t)=Vo[1-exp(-t/RC)]
Therefore, as charge increases on the capacitor plates, the voltage across the capacitor increases, until it reaches a steady-state value of V0, and the current drops to zero. Both the current, and the difference between the source and capacitor voltage decay exponentially with respect to time. The time constant of the decay is given by τ = RC.
2.4                   Series or parallel arrangements
parallel circuits
Capacitors in a parallel configuration each have the same potential difference (voltage). Their total capacitance (Ceq) is given by:
Ceq =C1 +C2 + ……..+Cn
The reason for putting capacitors in parallel is to increase the total amount of charge stored. In other words, increasing the capacitance also increases the amount of energy that can be stored. Its expression is:
Estored = ½ CV2
Series circuit
The current through capacitors in series stays the same, but the voltage across each capacitor can be different. The sum of the potential differences (voltage) is equal to the total voltage. Their total capacitance is given by:
1/ Ceq = 1/ C1 + 1/ C2+……..+ 1/ Cn
In parallel, the effective area of the combined capacitor has increased, increasing the overall capacitance. However, in series, the distance between the plates has effectively been increased, reducing the overall capacitance.
Ø      Noise filters, motor starters, and snubbers
When an inductive circuit is opened, the current through the inductance collapses quickly, creating a large voltage across the open circuit of the switch or relay. If the inductance is large enough, the energy will generate a spark, causing the contact points to oxidize, deteriorate, or sometimes weld together, or destroying a solid-state switch. A snubber capacitor across the newly opened circuit creates a path for this impulse to bypass the contact points, thereby preserving their life; these were commonly found in contact breaker ignition systems, for instance. Similarly, in smaller scale circuits, the spark may not be enough to damage the switch but will still radiate undesirable radio frequency interference (RFI), which a filter capacitor absorbs. Snubber capacitors are usually employed with a low-value resistor in series, to dissipate energy and minimize RFI. Such resistor-capacitor combinations are available in a single package.
Ø      Tuned circuits
In a tuned circuit such as a radio receiver, the frequency selected is a function of the inductance (L) and the capacitance (C) in series, and is given by:
.f = 1/2π√LC
This is the frequency at which resonance occurs in an LC circuit.
2.5                  INDUCTOR
An inductor is a passive electrical component with significant inductance. Inductors are implemented by some sort of coiled conductive winding which may surround a ferromagnetic core. Large inductors used at low frequencies may have thousands of turns around an iron core; at very high frequencies a straight piece of wire (i.e., with turns and core reduced to zero) has significant inductance.
An “ideal inductor” has inductance, but no resistance or capacitance, and does not dissipate energy. A real inductor is equivalent to a combination of a significant ideal inductance, some resistance, and capacitance, usually small. The resistance, a necessary property of a wire except at superconducting temperatures, may contribute significantly to the impedance, and may dissipate significant power in some applications. At some frequency, usually much higher than the working voltage, a real inductor behaves as a resonant circuit, and can cause parasitic oscillation.
3.0                   INDUCTOR CIRCUIT ARRANGEMENT
·         parallel circuit
Inductors in a parallel configuration each have the same potential difference (voltage). To find their total equivalent inductance (Leq):
1/Leq=1/L1 + 1/L2 +……+ 1/Ln
series circuit
The current through inductors in series stays the same, but the voltage across each inductor can be different. The sum of the potential differences (voltage) is equal to the total voltage. To find their total inductance:
Leq = L1 + L2 + ….+Ln
These simple relationships hold true only when there is no mutual coupling of magnetic fields between individual inductors.
4.0        INTRODUCTION
This chapter deals with the design methods and the analysis employed in the design of the electronic metal detector system. These analyses are required to make the correct choice of component values for effective performance.
4.1     DESIGN SPECIFICATION
 Power source:
Any two 9v battery PP3 is ideal.
Capacitors:
2 off  220uF 16v electrolytic.
5 off  .01uF polyester.
5 off  .1uF polyester.
Resistors:
All resistors 1/4 watt 5%
6 off  10k
1 off  1K
1 off  2.2M
2 off  39k
Transistors:
All BC 337B. Just about any small signal NPN with a gain of 250+ will do. There are hundreds to choose from.
Audio output:
A 2.5 inch 8 ohm speaker will work but headphones, buzzer or earpiece are preferable, the higher the impedance the better.
4.2                   Power supply Circuit
The main power supply to the circuit is from two 9v batteries connected in series to produce 18v and then regulated and maintained at 12v by using a 7812 voltage regulator.
 power supply circuit
The input to the 7812 regulator is calculated thus
Series connection of batteries is given by pt = p1 + p2 + p3 +…
Therefore the power input to the regulator is pt = p1 + p2
pt = 9+9 =18v
3.1.2                Oscillator Circuit
The oscillator circuit are made up of two different oscillators which are the sensor oscillator and the local or reference oscillator. Their frequencies of oscillation are set at 124khz since they are to operate at the same frequency. The two oscillator circuits are series LC circuit comprising of a BC 337 NPN transistors each for effective oscillation.
The sensor oscillator
To calculate the inductance of the inductor the resonance frequency formula is used
F = ( 2π (LC)1/2 )-1
Where F = frequency in Hertz which is set at 124khz
           L = inductance of the inductor
            C = capacitance of the capacitor
L = 1/ ( 4π2CF2 )
L = 1/ ( 4 x (3.142)2 x0.1×10-6 x (124 x 103 )2 )
L = 16.47µH
Then to calculate the number of turns, Wheeler’s formula for coils is applied
L = N2 r2/ 9r + 10l
Where N = number of turns
r = outer radius of coil (inches)
l = physical length of coil (inches)
L = 16.47outer radius of coil (inches)
l = physical length of coil (inches)
L = 16.47µH
r = C/ 2π    where C = circumference of the coil former
r= 3.6cm/2 π =0.57cm
Converting to inches we have
2.54cm – 1inch
0.57cm -  ?
0.57 / 2.54 =  0.23inches
L = 2.36 inches
N2 =L( 9r + 10l) / r2
     = 16.47( 9×0.23 + 10×2.36 ) / 0.232
N2 = 89 Turns
Applying the resonant frequency formula to calculate the inductance here we have:
L = 1/ ( 4π2CF2 )
Where F = 124khz , C =  0.1µF
L = 1/ ( 4 x (3.142)2 x0.1×10-6 x (124 x 103 )2 )
L = 16.47µH
Then using the Wheeler’s formula to find the number of turns
L = N2 r2/ 9r + 10l
 Where r = C/ 2π  = 52 / 2π
8.27cm == 3.26inches
L = 0.6 cm == 0.24inches
N2 =L( 9r + 10l) / r2
N2 =  16.47 ( 9×3.26 + 10×0.24 ) / 3.262
N = 7 Turns
4.3                   Amplifier Circuit
A common emitter (CE) transistor amplifier was used because of its characteristics which include:
Its output resistance is moderately large (50k or so)
Its current gain (β) is high (50 – 300)
It has high voltage gain of the order 1500 and above
It produces very high power gain of the order of 10,000 times or 40db.
The transistor used is a BC337 NPN transistor.
In a proper design the amplifier circuit operates normally when
VCE = ½ VCC
Also for a CE configuration
VCE = VCC – ICRL
hfe = IC / IB
Where VCE = collector emitter voltage
hfe = absolute minimum gain for the selected transistor which is 100
            IC = collector current
            IB = base current
Therefore RL = (VCC – VCE) / IC
The Voltage gain is given by
AV = ro / re
Where ro = output resistance of the stage
            re = emitter junction resistance
                  25Mv / IE.
4.4                   Beat Frequency Oscillator Technology
The circuit employs two radio frequency oscillators called the search and the reference oscillators and is tuned at the same frequency. the  output of the oscillator is fed into a mixer, which produce a signal that contains the sum and difference frequency components of the two input signals.
        The output from the mixer is fed into a low-pass(gain) filter where the harmonic is removed leaving the difference frequency component to subsist, though at theoretically 0Hz , as a result the output will have no difference. However, when metal is brought into the vicinity of the search coil, the frequency of search oscillators shifts slightly, then a there is a frequency difference, which is within the audio frequency range, appears at the output of the filter. This output is amplified by an audio amplifiers and fed to a loud speaker which produces sound output thus indicating the presence of metal       
5.0                   TESTING AND ANALYSIS
The following test was performed on the project circuit to ascertain the condition of the different stage and the project as a whole:
Short Circuit Test
The connections were checked with a multimeter set in continuity to ensure no short circuit occurs. The test was done and no short circuit was found.
Open Circuit Test
The various connections were checked for open circuit and none was found using multi meter.
Functional Test
 The different voltage value and current value were measured at each stages and all were found in confirmation with the design specifications.
Insulation Test
Insulator test was carried out in all units of the circuit especially those units that require         adequate insulation. Example, coil used in the oscillators.
SYSTEM  PERFORMANCE AND TEST RESULT
The  metal detector was used to test for various sizes of metal at various distance  from the search coil and the following result were obtained.
(i)     The lager the metal, the louder the sound output from the loud speaker and  smaller the metal , the lower the sound output from the loud speaker – though this also dependent on the size of the search coil.
(ii)   The closer the distance  between the search head and  the metal, the greater the sound output from  the loud speaker  and the farther the distance the fainter the sound output from the loud speaker, to extent the sound die off at some critical distance where theoretically the magnetic field due to the search head is zero.
6.0                   CONCLUSION
The beat frequency oscillator (BFO) principle is one of the reliable simple and cast effective principles of building a metal detector .though some are paid for these seemingly advantages and they includes.
(i)     Low sensitivity
(ii)   Short range of detection. Though depended on the size of search coil.
(iii) Not be able to discriminate metals
All these is nothing at all,It is interesting to know that the design and construction of metal detector is a success. This is because the project when tested produced the desired effect. In particular, this research work had made the principle of electromagnetic induction very clear to me as well as to any average literate person around me. In general, with the invention of metal detectors, the stress of one indulging in locating metallic components in a workshop has been reduced drastically. Also the embarrassment banks and other establishment cause their customers has been solved as some of the metal detectors are mounted on door entrances so as to trigger up an alarm when a metal is detected on s person trying to enter.
                        REFERENCES
1          Edeko, F.O, “Electronics circuit design material”  2008
2          A textbook of electrical technology by B.L. Theraja and A.K. Theraja, S. Chard and company, 2005.
3          Study of electronic components by J.A. Smith (2nd edition) , 1999
4          Electronic circuit analysis and design by Donald A. Neumann, Mc Grawhill Book Company, USA 1996.
5          Amplifiers comparators and special functions, Texas instrument, Data book volume B, Custom Printing Company’s,1997.

Microphone Amplifier Circuit using LM10

The reference, with a 500 kHz unity gain bandwidth, is used as a preamplifier with a gain of 100. Its output is fed through a gain control potentiometer to the op amp which is connected for a gain of 10. The combination gives a 60 dB gain with a 10 kHz bandwidth, unloaded, and 5 kHz loaded at 500 Ohm. Input impedance is 10 kOhm. Potentially, using the reference as a preamplifier in this fashion can cause excess noise. However, because the reference voltage is low, the noise contribution, which adds root mean square, is likewise low. Here is a schematic drawing:
One point to observe with this connection is that the signal swing at the reference output is strictly limited. It cannot swing much below 150 mV nor closer than 800 mV to the supply. Further, the bias current at the reference feedback terminal lowers the output quiescent level and generates an uncertainty in this level. These facts limit the maximum feedback resistance (R5) and require that R6 be used to optimize the quiescent operating voltage on the output. Even so, the fact that limited swing on the preamplifier can reduce maximum output power with low settings on the gain control must be considered.
In this design, no DC current flows in the gain control. This is perhaps an arbitrary rule, designed to insure long life with noise free operation. If violations of this rule are acceptable, R5 can be used as the gain control with only the bias current for the reference amplifier (<75 nA) flowing through the wiper. This simplifies the circuit and gives more leeway on getting sufficient output swing from the preamplifier.


Decorative light Controller

Dimmer control is often used to change the brightness of the light with AC. Bidirectional thyristor(TRIAC) is used for controlling current. The circuit which controls a thyristor using a variable resister and a capacitor is common. The circuit introduced on this page is a circuit which controls a thyristor by software of PIC.
It is also possible to make control the electric bulb on a Christmas tree bright gradually and dark gradually. Blink control of various patterns can be performed.


Hardware

Circuit drawing

Pattern drawing

Circuit explanation

Parts explanation
Software

Flow chart

List

Processing explanation
Equipment work

Operation check

Making process

Trouble shooting

















Simple Current Regulator Circuit Using LM10


The current regulator is a bit unusual in that the supply current of the IC flows through the sense resistor and does not affect accuracy as long as it is less than the desired output current. It is also possible to use remote amplifiers with two-wire signal transmission, as was done with the comparators. Remote sensors can be particularly troublesome when low-level analog signals are involved. Transmission problems include induced noise, ground currents, shunting from cable capacitance, resistance drops and thermoelectric potentials. These problems can be largely eliminated by amplifying the signal at the source and altering impedances to levels more suitable for transmission. Here is a schematic drawing :

Circuit explanation of Stepper Motor controller

Motor driving circuit

This is the circuit which drives the coil of stepper motor. There are circuits which drive coil, coil, coil and coil respectively.
Darlington connection-type transistor is used for the drive of the coil. As for the Darlington connection, 2 stages of transistors are connected inside in series. The "hfe" of this transistor is the multiplication of the "hfe" of each transistor inside. In case of 2SD1209K which was used this time, the hfe is over 4000. Because the ratio of the input electric current and the output current is big, the rising edge and the falling edge of the control signal can be made sharp.
The diode to be putting between the collector and the power is for the protection of the transistor. When the transistor becomes OFF from ON, the coil of the motor tries to continue to pass an electric current and generates high voltage. An electric current by this voltage is applied to the diode and the high voltage which applies over the transistor is prevented.
Speed control circuit
  This is the circuit which controls the rotational speed of the motor.
TR1 becomes ON condition when RB7 becomes H level. In this condition, the electric charge of capacitor C1 flows through the transistor and the voltage of the both edges of the capacitor becomes 0 V almost.
When RB7 becomes an L level, the transistor becomes OFF condition. In this condition, the electric current flows through VR1 and R4 into capacitor C1 and the charging to the capacitor begins. The voltage of the both edges of the capacitor becomes high gradually as charging is done. As for the change of this voltage, refer to "Integration circuit".
The voltage of the capacitor is detected by RB5. The software of PIC interrupts the control of the motor until it checks RB5 after making RB7 an L level and RB5 becomes H level. When making the value of VR1 small, the charging time of the capacitor is short and the control of the motor becomes quick. The control of the motor becomes slow when making VR1 big. The speed control range can be changed by changing the value of the capacitor.

Start/stop circuit
This is the circuit for the clockwise rotating, the counterclockwise rotating or stopping a motor. The baton switch of the non lock is used. Pull-up resistor is used for the port to become H level when the switch is OFF. The RB port of PIC16F84A has an internal pull up feature. However, because RB5 is used for the voltage detection of the capacitor at the circuit this time, an internal pull up feature isn't used. If using RA port for the voltage detection of the capacitor, the RB internal pull up feature can be used. The circuit this time put an external pull-up resistor in the relation of the pattern.

Oscillator
4-MHz resonator is used because the circuit this time doesn't need high-speed operation.

Power supply circuit
The purpose of this circuit is to keep power supply voltage to PIC to 5V when the power of the stepper motor is more than 5V.
Because the operating voltage of the stepper motor to be using this time is about 5V, the power supply voltage is +5V. In this case, the voltage which is applied to PIC becomes less than 5V because of the voltage drop (about 1V) of the regulator. In case of PIC16F84A, the operation is possible even if the power falls to about 3V because the operating voltage range is from 2V to 5.5V. It is enough in the 100-mA type.
 
 
 

Transmitter Precision Thermocouple Amplifier Circuit

This circuit is shows how a low drift preamplifier can be added to improve the measurement resolution of a thermocouple. The preamp is powered from the reference regulator, and bridge feedback is used to bias the preamp input within its common mode range. Cold junction compensation is provided with the offset voltage set into A1, it being directly proportional to absolute temperature. The maximum drift specification for the preamp is 0.2 µV/°C. For this particular circuit, an equal drift component would result for 0.004%/°C on the reference, 0.001%/°C mismatch on the bridged
feedback resistors (R2–R4) or 3 µV/°C on the op amp offset voltage. Here is a schematic drawing:

The op amp drift might be desensitized by raising the preamp gain (lowering R7–R9), but this would require raising the output voltage of the reference regulator and the minimum terminal voltage. In this application, the preamp is run at a lower voltage than standard parts are tested with, and the maximum supply current specified is high. However, there should be no problem with the voltage; and a lower, maximum supply current can be expected at the lower voltage. Even so, some testing may be in order.

Sunday, June 26, 2011

DC motor 12V speed controller circuit with explanation

A very simple encoder circuit for a dc motor can be constructed using this circuit diagram . As you can see in the circuit diagram , the system shown consists of the HA-2542, a small 12-Vdc motor, and a position encoder. During operation, the encoder causes a series of ''constant-width" pulses to charge CI. The integrated pulses develop a reference voltage, which is proporţional to motor speed and is applied to the inverting input of HA-2542, The noninverting input is held at a constant voltage, which represents the desired motor speed. A difference between these two inputs will send a corrected drive signal to the motor, which completes the speed control system loop.
As you can see the circuit requires few external components , but because of the encoder wheel it has a limitations of use .If you put a pulley under the encoder wheel you can command the speed of other device , by connecting the (motor and other device ) using a belt