Anda di halaman 1dari 40

WIRELESS CONTROLLED HOME APPLAINCE USING DUAL TONE MULTIPLE FREQUENCY

1. Introduction 2. Design Model 3. Circuit design 4. Power supply 5. Micro controller board 6. DTMF Decoder MT 8870DE 7. Relay logic 8. Capacitor 9. LED 10. Resistor 11. Complete Circuit diagram 12. Software. 13. Conclusion 14. Bibliography

The basic aim of our project is to achieve automation using remote sensing via service providers i.e. through the normal cell phone network. Home automation (also called smart homes or domestics) is a field within building automation, specializing in the specific automation requirements of private homes and in the application of automation techniques for the comfort and security of its residents. Although many techniques used in building automation (such as light and climate control, control of doors and window shutters, security and surveillance systems, etc.) are also used in home automation, additional functions in home automation can include the control of multi-media home entertainment systems, automatic plant watering and pet feeding, automatic scenes for dinners and parties, and a more user-friendly control interface. When home automation is installed during construction of a new home, usually control wires are added before the interior walls are installed. These control wires run to a controller, which will then control the environment. This can be achieved either using cell phone or landline connection, through which we would call the other phone situated at the remote location or at home, and by pressing the keys we would be controlling home appliances.When a digit is pressed the caller generates two frequencies which would be decoded by MT8870 IC hence adding brain to the complete system with the help of microcontrollers. The Project module consists of following sections. 1. 2. 3. 4. 5. 6. Power Supply Section. Micro controller board DTMF board Mobile Relay Interface section Software

This system is developed on an ATmega16 micro controller. The tone generated by phone is decoded into 4 bit value by DTMF board .This 4-bit acts as input to Transmitter section .Transmitter section transmits the data of DTMF board to micro controller serially .The receiver section is connected to relay circuit .The output of receiver section acts as input to relay circuit .Depending upon the problem statement micro controller is programmed to control the appliances. .To control the operation of appliances we are using transistor as a switch concept and relay logic .When relay is energized the appliance connected to that very relay gets on .The LCD panel is there to show the current status of appliances i.e. it is on or off

Power supply section

Pinout of the 7805 regulator IC. regulator IC. 1. Unregulated voltage in 2. Ground 3. Regulated voltage out

Pinout of the 7812

1. Unregulated voltage in 2. Ground 3. Regulated voltage out

The power supply designed for catering a fixed demand connected in this project. The basic requirement for designing a power supply is as follows, 1.The voltage levels required for operating the devices is +5volt. Here +5Volt required for operating microcontroller. And as well as transmitters and receivers. 2. The current requirement of each device or load must be added to estimate the final capacity of the power supply. The power supply always specified with one or multiple voltage outputs along with a current capacity. As it is estimate the requirement of power is approximately as follows, Out Put Voltage = +5Volt, Capacity = 1000mA required for drivers and amplifiers and ir

The power supply is basically consisting of three sections as follows, 1. 2. 3. Step down section Rectifier Section Regulator section

Design principle: There are two methods for designing power supply, the average value method and peak value method. In case of small power supply peak value method is quit economical, for a particular value of DC output the input AC requirement is appreciably less. In this method the DC output is approximately equal to Vm. A full wave bridge rectifier is designed using two diodes and the output of the rectifier is filtered with a low pass filter. The capacitor value is decided so that it will back up for the voltage and current during the discharging period of the DC output. In this case the output with reference to the center tap of the transformer is taken in to consideration, though the rectifier designed is a full wave bridge rectifier but the voltage across the load is a half wave rectified output. The Regulator section used here is configured with a series regulator LM78XX the XX represents the output voltage and 78 series indicates the positive voltage regulator 79 series indicates the negative regulator for power supply. The positive regulator works satisfactorily between the voltage XX+2 to 40 Volt DC. The output remains constant within this range of voltage. The output remains constant within this range of voltage. Circuit connection: - In this we are using Transformer (12-0-12) v / 1mA, IC 7805, diodes IN 4007, LED & resistors. Here 230V, 50 Hz ac signal is given as input to the primary of the transformer and the secondary of the transformer is given to the bridge rectification diode. The positive output of the bridge rectifier is given as i/p to the IC regulator (7805) through capacitor (1000uf/25v). The o/p of the IC regulator is given to the LED through resistors to act as indicator.

Circuit Explanations: - When ac signal is given to the primary of the transformer, due to the magnetic effect of the coil magnetic flux is induced in the coil (primary) and transfer to the secondary coil of the transformer due to the transformer action. Transformer is an electromechanical static device which transformer electrical energy from one coil to another

without changing its frequency. Here the diodes are connected to the two +12volt output of the transformer. The secondary coil of the transformer is given to the diode circuit for rectification purposes. During the +ve cycle of the ac signal the diodes D1 conduct due to the forward bias of the diodes and diodes D2 does not conduct due to the reversed bias of the diodes. Similarly during the ve cycle of the ac signal the diodes D2 conduct due to the forward bias of the diodes and the diodes D1 does not conduct due to reversed bias of the diodes. The output of the bridge rectifier is not a power dc along with rippled ac is also present. To overcome this effect, a low pass filter is connected to the o/p of the diodes (D1 & D2). Which removes the unwanted ac signal and thus a pure dc is obtained. Here we need a fixed voltage, thats for we are using IC regulators (7805).Voltage regulation is a circuit that supplies a constant voltage regardless of changes in load current. This ICs are designed as fixed voltage regulators and with adequate heat sinking can deliver output current in excess of 1A. The o/p the full wave rectifier is given as input to the IC regulator through low pass filter with respect to GND and thus a fixed o/p is obtained. The o/p of the IC regulator (7805) is given to the LED for indication purpose through resistor. Due to the forward bias of the LED, the LED glows ON state, and the o/p are obtained from the pin no-3. .

1 IC7805 3
330R

+5VDC

2
12-0-12 LED

230VAC 50Hz

3
IC7812
470R

+12VDC

IN4007

2
1000uF/35V LED

GND

POWER SUPPLY SECTION

Microcontroller board consists of ATmega16 with 10 f capacitor connected to pin AREF and gnd.

Features: The ATmega16 is a low-power CMOS 8-bit microcontroller based on the AVR enhanced RISC architecture. By executing powerful instructions in a single clock cycle, the ATmega16 achieves throughputs approaching 1 MIPS per MHz allowing the system designed to optimize power consumption versus processing speed. The AVR core combines a rich instruction set with 32 general purpose working registers. All the 32 registers are directly connected to the Arithmetic Logic Unit (ALU), allowing two independent registers to be accessed in one single instruction executed in one clock cycle. The resulting architecture is more code efficient while achieving throughputs up to ten times faster than conventional CISC microcontrollers. The ATmega16 provides the following features: 16K bytes of In-System Programmable Flash Program memory with Read-While-Write capabilities, 512 bytes EEPROM, 1K byte SRAM, 32 general purpose I/O lines, 32 general purpose working registers, a JTAG interface for Boundary-scan, On-chip Debugging support and programming, three flexible Timer/Counters with compare modes, Internal and External Interrupts, a serial programmable USART, a byte oriented Two-wire Serial Interface, an 8-channel, 10-bit ADC with optional differential input stage with programmable gain (TQFP package only),a programmable Watchdog Timer with Internal Oscillator, an SPI serial port, and six software selectable power saving modes. The Idle mode stops the CPU while allowing the USART, Two-wire interface, A/D Converter, SRAM, Timer/Counters, SPI port, and interrupt system to continue functioning. The Power-down mode saves the register contents but freezes the Oscillator, disabling all other chip functions until the next External Interrupt or Hardware Reset. In Power-save mode, the Asynchronous Timer continues to run, allowing the user to maintain a timer base while the rest of the device is sleeping.

The ADC Noise Reduction mode stops the CPU and all I/O modules except Asynchronous Timer and ADC, to minimize switching noise during ADC conversions. In Standby mode, the crystal/resonator Oscillator is running while the rest of the device is sleeping. This allows very fast start-up combined with low-power consumption. In Extended Standby mode, both the main Oscillator and the Asynchronous Timer continue to run. The device is manufactured using Atmels high density non-volatile memory technology. The On-chip ISP Flash allows the program memory to be reprogrammed in-system through an SPI serial interface, by a conventional non-volatile memory programmer, or by an On-chip Boot program running on the AVR core. The boot program can use any interface to download the application program in the Application Flash memory. Software in the Boot Flash section will continue to run while the Application Flash section is updated, providing true ReadWhile-Write operation. By combining an 8-bit RISC CPU with In-System SelfProgrammable Flash on a monolithic chip, the Atmel ATmega16 is a powerful microcontroller that provides a highly-flexible and cost-effective solution to many embedded control applications. The ATmega16 AVR is supported with a full suite of program and system development tools including: C compilers, macro assemblers, program debugger/simulators, in-circuit emulators, and evaluation kits.

Digital supply voltage. GND Ground. Port A (PA7..PA0) Port A serves as the analog inputs to the A/D Converter.

Port A also serves as an 8-bit bi-directional I/O port, if the A/D Converter is not used. Port pins can provide internal pull-up resistors (selected for each bit). The

Port A output buffers have symmetrical drive characteristics with both high sink and source capability. When pins PA0 to PA7 are used as inputs and are externally pulled low, they will source current if the internal pull-up resistors are activated. The Port pins are tri-stated when a reset condition becomes active, even if the clock is not running. Port B (PB7..PB0) Port B is an 8-bit bi-directional I/O port with internal pull-up resistors (selected for each bit). The Port B output buffers have symmetrical drive characteristics with both high sink and source capability. As inputs, Port B pins that are externally pulled low will source current if the pull-up resistors are activated. The Port B pins are tri-stated when a reset Condition becomes active, even if the clock is not running. Port B also serves the functions of various special features of the ATmega16. Port C (PC7..PC0) Port C is an 8-bit bi-directional I/O port with internal pull-up resistors (selected for each bit). The Port C output buffers have symmetrical drive characteristics with both high sink and source capability. As inputs, Port C pins that are externally pulled low will source current if the pull-up resistors are activated. The Port C pins are tri-stated when a reset condition becomes active, even if the clock is not running. If the JTAG interface is enabled, the pull-up resistors on pins PC5 (TDI), PC3 (TMS) and PC2 (TCK) will be activated even if a reset occurs. Port C also serves the functions of the JTAG interface and other special features of the ATmega16 as listed on page 61. Port D (PD7..PD0) Port D is an 8-bit bi-directional I/O port with internal pull-up resistors (selected for each bit). The Port D output buffers have symmetrical drive characteristics with both high sink and source capability. As inputs, Port D pins that are externally pulled low will source current if the pull-up resistors are activated. The Port D pins are tri-stated when a reset condition becomes active, even if the clock is not running. Port D also serves the functions of various special features of the ATmega16. RESET Input. A low level on this pin for longer than the minimum pulse length will generate a reset, even if the clock is not running. The minimum pulse length is 0.1 vcc. Shorter pulses are not guaranteed to generate a reset. XTAL1 Input to the inverting Oscillator amplifier and input to the internal clock operating circuit. XTAL2 Output from the inverting Oscillator amplifier. AVCC AVCC is the supply voltage pin for Port A and the A/D Converter. It should be externally Connected to VCC, even if the ADC is not used. If the ADC is used, it should be connected to VCC through a low-pass filter. AREF AREF is the analog reference pin for the A/D Converter.

Integrated circuit Microchips (EPROM memory) with a transparent window, showing the integrated circuit inside. Note the fine silver-colored wires that connect the integrated circuit to the pins of the package. The window allows the memory contents of the chip to be erased, by exposure to strong ultraviolet light in an eraser device. In electronics, an integrated circuit (also known as IC, microcircuit, microchip, silicon chip, or chip) is a miniaturized electronic circuit (consisting mainly of semiconductor devices, as well as passive components) that has been manufactured in the surface of a thin substrate of semiconductor material. Integrated circuits are used in almost all electronic equipment in use today and have revolutionized the world of electronics. A hybrid integrated circuit is a miniaturized electronic circuit constructed of individual semiconductor devices, as well as passive components, bonded to a substrate or circuit board.

This circuit detects the dial tone from a telephone line and decodes the keypad pressed on the remote telephone. The dial tone we heard when we pick up the phone set is call Dual Tone Multi-Frequency, DTMF in short. The name was given because the tone that we heard over the phone is actually making up of two distinct frequency tones, hence the name dual tone. The DTMF tone is a form of one way communication between the dialer and the telephone exchange. Keypad Dial Tone Frequency Table In the early days, our phone system used to be operated by human operator in a telephone exchange room. The caller will pick up the phone, giving instruction to the operator to connect their line to the destination over the other end of the telephone. As

more and more people find phone technology a useful communication tools, line connection use human operator has become a tedious task. As technology matures, pulse/dial tone method was inverted for telephony communication. It uses electronics and computer to assist in the phone line connection. Basically on the caller side, it is a dial tone generator. When a key is being pressed on the matrix keypad, it generates a unique tone consisting of two audible tone frequencies. For example, if the key '1' is being press on the phone, the tone you hear is actually consisting of a 697 Hz & 1209 Hz sine signal. Pressing key '9' will generate the tone form by 852 Hz & 1477 Hz. The frequency use in the dial tone system is of audible range suitable for transmission over the telephone cable. On the telephone exchange side, it has a decoder circuit to decode the tone to digital code. For example, the tone of 941 Hz + 1336 Hz will be decoded as binary '1010' as the output. This digital output will be read in by a computer, which will then act as a operator to connect the caller's telephone line to the designated phone line. The telephone exchange center will generate a high voltage signal to the receiving telephone, so as to ring the telephone bell, to notify the receiving user that there is an incoming call. This project article focus on a simple DTMF (dual tone multi frequency) decoder circuit. This circuit can be interface to a computer, allowing caller to computer interaction. Many communication application can be build for example, a computerize call receiving/diverting phone network system. Remote control to Home/Office electrical appliances using a telephone network. DTMF is a popular project especially in DSP (digital signal processing) subject. DSP software algorithm can be implementing to generate as well as to decode DTMF tone. It is very interesting, and I will try to cover that aspect in near future. For now we do the hardware way.

These are the decoder output table for the given dial tone detected. Notice that there is key tone for A B C and D. These are special tones which are normally not found on our telephone. It is a common standard build into the decoder chip. The circuit is relatively simple and straight forward, and all components can be easily found.

CIRCUIT DIAGRAM:

A relay is an electrically operated switch. Electric current through the coil of the relay creates a magnetic field which attracts a lever and changes the switch contacts. The coil current can be on or off so relays have two switch positions and they are double-throw (changeover) switches. It consists of a coil of wire surrounding a soft iron core, an iron yoke, which provides a low reluctance path for magnetic flux, a movable iron armature, and a set, or sets, of contacts; two in the relay pictured. The armature is hinged to the yoke and mechanically linked to a moving contact or contacts. It is held in place by a spring so that when the relay is de-energized there is an air gap in the magnetic circuit. In this condition, one of the two sets of contacts in the relay pictured is closed, and the other set is open.

Types of relay Latching relay A latching relay has two relaxed states (bitable). These are also called 'keep' or 'stay' relays. When the current is switched off, the relay remains in its last state. This is achieved with a solenoid operating a ratchet and cam mechanism, or by having two opposing coils with an overcenter spring or permanent magnet to hold the armature and contacts in position while the coil is

relaxed, or with a remnant core. In the ratchet and cam example, the first pulse to the coil turns the relay on and the second pulse turns it off. In the two coil example, a pulse to one coil turns the relay on and a pulse to the opposite coil turns the relay off. This type of relay has the advantage that it consumes power only for an instant, while it is being switched, and it retains its last setting across a power outage. Reed relay A reed relay has a set of contacts inside a vacuum or inert gas filled glass tube, which protects the contacts against atmospheric corrosion. The contacts are closed by a magnetic field generated when current passes through a coil around the glass tube. Reed relays are capable of faster switching speeds than larger types of relays, but have low switch current and voltage ratings. See also reed switch. Mercury-wetted relay A mercury-wetted reed relay is a form of reed relay in which the contacts are wetted with mercury. Such relays are used to switch low-voltage signals (one volt or less) because of their low contact resistance, or for high-speed counting and timing applications where the mercury eliminates contact bounce. Mercury wetted relays are position-sensitive and must be mounted vertically to work properly. Because of the toxicity and expense of liquid mercury, these relays are rarely specified for new equipment. See also mercury switch. Polarized relay A Polarized Relay placed the armature between the poles of a permanent magnet to increase sensitivity. Polarized relays were used in middle 20th Century telephone exchanges to detect faint pulses and correct telegraphic distortion. The poles were on screws, so a technician could first adjust them for maximum sensitivity and then apply a bias spring to set the critical current that would operate the relay. Machine tool relay A machine tool relay is a type standardized for industrial control of machine tools, transfer machines, and other sequential control. They are characterized by a large number of contacts (sometimes extendable in the field) which are easily converted from normally-open to normallyclosed status, easily replaceable coils, and a form factor that allows compactly installing many relays in a control panel. Although such relays once were the backbone of automation in such industries as automobile assembly, the programmable logic controller (PLC) mostly displaced the machine tool relay from sequential control applications. Contactor relay A contactor is a very heavy-duty relay used for switching electric motors and lighting loads. High-current contacts are made with alloys containing silver. The unavoidable arcing causes the contacts to oxidize and silver oxide is still a good conductor. Such devices are often used for motor starters. A motor starter is a contactor with overload protection devices attached. The overload sensing devices are a form of heat operated relay where a coil heats a bi-metal strip, or where a solder pot melts, releasing a spring to operate auxiliary contacts. These auxiliary contacts are in series with the coil. If the overload senses excess current in the load, the coil is

de-energized. Contactor relays can be extremely loud to operate, making them unfit for use where noise is a chief concern. Solid-state relay

Solid state relay, which has no moving parts

25 amp or 40 amp solid state contactors A solid state relay (SSR) is a solid state electronic component that provides a similar function to an electromechanical relay but does not have any moving components, increasing long-term reliability. With early SSR's, the tradeoff came from the fact that every transistor has a small voltage drop across it. This voltage drop limited the amount of current a given SSR could handle. As transistors improved, higher current SSR's, able to handle 100 to 1,200 amps, have become commercially available. Compared to electromagnetic relays, they may be falsely triggered by transients. Solid state contactor relay A solid state contactor is a very heavy-duty solid state relay, including the necessary heat sink, used for switching electric heaters, small electric motors and lighting loads; where frequent on/off cycles are required. There are no moving parts to wear out and there is no contact bounce due to vibration. They are activated by AC control signals or DC control signals from Programmable logic controller (PLCs), PCs, Transistor-transistor logic (TTL) sources, or other microprocessor controls. Buchholz relay A Buchholz relay is a safety device sensing the accumulation of gas in large oil-filled transformers, which will alarm on slow accumulation of gas or shut down the transformer if gas is produced rapidly in the transformer oil. Forced-guided contacts relay A forced-guided contacts relay has relay contacts that are mechanically linked together, so that when the relay coil is energized or de-energized, all of the linked contacts move together. If one set of contacts in the relay becomes immobilized, no other contact of the same relay will be able to move. The function of forced-guided contacts is to enable the safety circuit to check the status of the relay. Forced-guided contacts are also known as "positive-guided contacts", "captive contacts", "locked contacts", or "safety relays". Overload protection relay One type of electric motor overload protection relay is operated by a heating element in series with the electric motor. The heat generated by the motor current operates a bi-metal strip or melts solder, releasing a spring to operate contacts. Where the overload relay is exposed to the same environment as the motor, a useful though crude compensation for motor ambient temperature is provided. Pole & Throw

The diagram on the package of a Circuit symbols of relays. "C" denotes the common terminal in SPDT and DPDT types

DPDT AC coil relay

Since relays are switches, the terminology applied to switches is also applied to relays. A relay will switch one or more poles, each of whose contacts can be thrown by energizing the coil in one of three ways: Normally-open (NO) contacts connect the circuit when the relay is activated; the circuit is disconnected when the relay is inactive. It is also called a Form A contact or "make" contact. Normally-closed (NC) contacts disconnect the circuit when the relay is activated; the circuit is connected when the relay is inactive. It is also called a Form B contact or "break" contact. Change-over (CO), or double-throw (DT), contacts control two circuits: one normallyopen contact and one normally-closed contact with a common terminal. It is also called a Form C contact or "transfer" contact ("break before make"). If this type of contact utilizesmake before break" functionality, then it is called a Form D contact. The following designations are commonly encountered: SPST - Single Pole Single Throw. These have two terminals which can be connected or disconnected. Including two for the coil, such a relay has four terminals in total. It is ambiguous whether the pole is normally open or normally closed. The terminology "SPNO" and "SPNC" is sometimes used to resolve the ambiguity. SPDT - Single Pole Double Throw. A common terminal connects to either of two others. Including two for the coil, such a relay has five terminals in total. DPST - Double Pole Single Throw. These have two pairs of terminals. Equivalent to two SPST switches or relays actuated by a single coil. Including two for the coil, such a relay has six terminals in total. The poles may be Form A or Form B (or one of each). DPDT - Double Pole Double Throw. These have two rows of change-over terminals. Equivalent to two SPDT switches or relays actuated by a single coil. Such a relay has eight terminals, including the coil. The "S" or "D" may be replaced with a number, indicating multiple switches connected to a single actuator. For example 4PDT indicates a four pole double throw relay (with 14 terminals). Applications Relays are used to and for: Control a high-voltage circuit with a low-voltage signal, as in some types of modems or audio amplifiers, Control a high-current circuit with a low-current signal, as in the starter solenoid of an automobile, Detect and isolate faults on transmission and distribution lines by opening and closing circuit breakers (protection relays), Isolate the controlling circuit from the controlled circuit when the two are at different potentials, for example when controlling a mains-powered device from a low-voltage switch. The latter is often applied to control office lighting as the low voltage wires are easily installed in

partitions, which may be often moved as needs change. They may also be controlled by room occupancy detectors in an effort to conserve energy, Logic functions. For example, the Boolean AND function is realized by connecting normally open relay contacts in series, the OR function by connecting normally open contacts in parallel. The change-over or Form C contacts perform the XOR (exclusive or) function. Similar functions for NAND and NOR are accomplished using normally closed contacts. The Ladder programming language is often used for designing relay logic networks. o Early computing. Before vacuum tubes and transistors, relays were used as logical elements in digital computers. See ARRA (computer), Harvard Mark II, Zuse Z2, and Zuse Z3. o Safety-critical logic. Because relays are much more resistant than semiconductors to nuclear radiation, they are widely used in safety- critical logic, such as the control panels of radioactive waste-handling machinery.

The relay driver is design by using a BC547 transistor. The Microcontroller cant supply more than 10mA current. So driver section is very much required. BC547 has a typical current gain of 200 and maximum current capacity of 1A. So a typical base current of 200 mA can trigger to on the relay.

Relays are one of the oldest, simplest, and yet, easiest and most useful devices. Before the advent of the mass produced transistor, computers were made from either relays or vacuum tubes, or both. A relay, quite simply, is a small machine consisting of an electromagnet (coil), a switch, and a spring. The spring holds the switch in one position, until a current is passed through the coil. The coil generates a magnetic field which moves the switch. It's that simple. You can use a very small amount of current to activate a relay, and the switch can often handle a lot of current. The relay we are going to look at is the Bosch 5 pin relay. Bosch is a German manufacturing conglomerate (who also happen to own Bosch Telekom and Blaupunkt), but they are not the only manufacturer of this relay. There are several other companies such as Siemens (stop laughing) and Potter & Brumfield. I don't know why they call it the Bosch type relay, but dammit, I don't give a shit either. The Bosch 5 pin relay is the most widely used and versatile relay, and it can handle up to 30 amps, which is more than suitable for most applications.

Looking at the diagram to the right, we see the pinout of the relay. Note that each pin is numbered, 85, 86, 87, 87a, and 30. The 30 pin is set perpendicular to the other pins to let you know where each pin is at (although, most relays are labeled at the bottom). 85 and 86 are the coil pins. Normally, it doesn't matter which way you pass the current, because if you hook it up backwards, the coil will still activate the relay. However, relays sometimes have an odd tendency to turn themselves back on briefly. To counter this, a diode (a one way switch) is placed between 85 and 86. This is referred to as a tamping diode. A diode wall have a very high resistance in one direction, and a very low resistance in the opposite direction. When a tamping diode is used, it is important that you hook the coil up according to polarity. If a tamping diode is used, and you hook it up backwards, you will essentially be shorting a wire out, which sucks, because you can and will burn something up. 30, 87, and 87a are the other three pins. 87 and 87a are the two contacts to which 30 will connect. If the coil is not activated, 30 will always be connected to 87a. Think of that pin as "87, always connected". When current is applied to the coil, 30 is connected to 87. 87 and 87a are never connected to each other. Here, polarity does not

ever matter. You can connect 30 up to positive or negative, and that is what you will get out of 87 or 87a. Refer to the picture at left, and perhaps it will make the relay a tad simpler. As you can see, the coil is in no way connected to the switch part of the relay. This can allow you to completely isolate one circuit from another. You can even use a separate power supply to control the relay. Now let's talk about applications. One common use of a relay is for multiple amplifiers. Normally, if you run any more than three audio components off your decks remote output, it is recommended that you use a relay to provide higher currents. Also, if you wanted to power something like a fan, or neon lighting, you need a relay to keep up with the higher demands these devices place on your remote. Take a minute and guess if you can see how it is done. All you have to do is connect 85 to your decks remote output wire, and 86 to ground. Then, connect 30 to a fused 12 volts source, and 87 to your outgoing remote line. Remember that the relay can carry up to 30 amps, but if your wire can only handle 10 amps, you should use a 10 amp fuse. 87a is not used, but I recommend taping up that pin, or pulling the wire out of the base, so that it does not short out. That is one of many applications for this one type of relay, and it demonstrates really well the use of a relay as a switch. One other use of this relay is to select. Remember that when the relay is not energized, 87a and 30 are connected. Say for instance, that you wanted to be able to run

your subs in bridged mode, but then switch them the two channel mode when the amp starts to run hot. This will take two relays. The amp we use in this example is a two channel which will combine the right channel negative with the left channel positive for bridged mode, and we are using two single voice coil subwoofers. In either configuration (bridged or two channel), the left channel positive will always connect to the left woofers + terminal, and the right channels terminal will always connect to the right woofer -. The other terminals we have to play with. Connect the left woofer relay's 30 pin to the - terminal on the woofer, and connect the right woofer relay's 30 pin to the + terminal on the woofer. Then, connect the left woofer relay's 87a pin to the - terminal on the amp, and the right woofer relay's 87a pin to the + terminal on the amp. Now, connect the left woofer relay's 87 pin to the - terminal on the right woofer, and connect the right woofer relay's 87 pin to the left woofers + terminal. Finally, connect the 86 pins of each relay together and ground it, and connect both 85 pins of each relay together, then to a

switch, which is connected to a fused 12 volt source. Sound complicated? I hope the diagram helps make it seem simple. With the relays at rest, the amp is running in two channel mode. However, flipping the switch places the woofers in parallel, and safely breaks the connection with the two terminals that are unused. This is not seamless: When you flick the switch, you will hear a pop much like you hear when you plug a woofer in while it's getting juice. Some amps only produce a small pop, but cheap amps tend to make a big deal out of this. On a side note, you can use a thermistor to automatically switch the relays. Relays really are not a big deal. They are relatively easy to use, and are very forgiving of stupidity. For many applications, a relay is the only way to go.

CAPACITOR A capacitor or condenser is a passive electronic component consisting of a pair of conductors separated by a dielectric. When a voltage potential difference exists between the conductors, an electric field is present in the dielectric. This field stores energy and produces a mechanical force between the plates. The effect is greatest between wide, flat, parallel, narrowly separated conductors. An ideal capacitor is characterized by a single constant value, capacitance, which is measured in farads. This is the ratio of the electric charge on each conductor to the potential difference between them. In practice, the dielectric between the plates passes a small amount of leakage current. The conductors and leads introduce an equivalent series resistance and the dielectric has an electric field Capacitors are widely used in electronic circuits to block the flow of direct current while allowing alternating current to pass, to filter out interference, to smooth the output of power supplies, and for many other purposes. They are used in resonant circuits in radio frequency equipment to select particular frequencies from a signal with many frequencies. Strength limit resulting in a breakdown voltage.

OPERATION A capacitor consists of two conductors separated by a non-conductive region. The non-conductive substance is called the dielectric medium, although this may also mean a vacuum or a semiconductor depletion region chemically identical to the conductors. A capacitor is assumed to be selfcontained and isolated, with no net electric charge and no influence from an external electric field. The conductors thus contain equal and opposite charges on their facing surfaces and the dielectric contains an electric field. The capacitor is a reasonably general model for electric fields within electric circuits. An ideal capacitor is wholly characterized by a constant capacitance 'C', defined as the ratio of charge 'Q' on each conductor to the voltage 'V' between them:

C = capacitance in farads( F) Q = charge in coulombs (C) V = Volts (V) Sometimes charge build-up affects the mechanics of the capacitor, causing the capacitance to vary. In this case, capacitance is defined in terms of incremental changes:

In SI units, a capacitance of one farad means that one coulomb of charge on each conductor causes a voltage of one volt across the device. Capacitance Capacitance is the measure of the capacitors ability to store charge. The unit for capacitance is the Farad (F). The capacitance of a capacitor is one farad if coulomb of charge when the voltage across its terminals is 1Volt. TYPES OF D IELECTRIC AIR GAP Air-gap capacitors have a low dielectric loss. Large-valued, tunable capacitors that can be used for resonating HF antennas can be made this way. its stores one

CERAMIC The main differences between ceramic dielectric types are the temperature coefficient of capacitance, and the dielectric loss. C0G and NP0 (negative-positive-zero, i.e. 0) dielectrics have the lowest losses, and are used in filters, as timing elements, and for balancing crystal oscillators. Ceramic capacitors tend to have low inductance because of their small size. NP0 refers to the shape of the capacitor's temperature coefficient graph (how much the capacitance changes with temperature). NP0 means that the graph is flat and the device is not affected by temperature changes. GIMMICK These capacitors are made by twisting together 2 pieces of insulated wire. Values usually range from 3 pF to 15 pF Usually used in homemade VHF circuits for oscillation feedback TRIMMER These capacitors have a rotating plate (which can be rotated to change the capacitance) separated from a fixed plate by a dielectric medium. Typically values range from 5 pF to 60 pF. GLASS These capacitors are used to form extremely stable and reliable capacitors. PAPER Common in antique radio equipment, paper dielectric and aluminium foil layers rolled into a cylinder and sealed with wax. Low values up to a few F, working voltage up to several hundred volts. Energy storage Work must be done by an external influence to move charge between the conductors in a capacitor. When the external influence is removed, the charge separation persists and energy is stored in the electric field. If charge is later allowed to return to its equilibrium position, the energy is released. The work done in establishing the electric field, and hence the amount of energy stored, is given by:[10]

Applications Capacitors have many uses in electronic and electrical systems. They are so common that it is a rare electrical product that does not include at least one for some purpose. Important Things to Know The capacity to store energy is affected by these 4 Factors: The The area of the plates larger area , larger capacity. distance between the plates-Less distance, larger capacity. The type of dielectric (insulating material between the plates. The applied voltage Increase voltage - Increase stored charge. Capacitors have a maximum working voltage. This is a never exceed value. (Be careful not to exceed this voltage or catastrophic breakdown of the capacitor is likely ) Note: Some capacitors can explode in this condition. Some types of capacitors are polarity sensitive. Be careful not to install this type in your circuit the wrong way. It will often destroy the capacitor.

Light-emitting diode(LED) A light-emitting diode (LED) is an electronic light source. LEDs are used as indicator lamps in many kinds of electronics and increasingly for lighting. LEDs work by the effect of electroluminescence, discovered by accident in 1907. The LED was introduced as a practical electronic component in 1962. All early devices emitted low-intensity red light, but modern LEDs are available across the visible, ultraviolet and infra red wavelengths, with very high brightness. LEDs are based on the semiconductor diode. When the diode is forward biased (switched on), electrons are able to recombine with holes and energy is released in the form of light. This effect is called electroluminescence and the colour of the light is determined by the energy gap of the semiconductor. The LED is usually small in area (less than 1 mm2) with integrated optical components to shape its radiation pattern and assist in reflection. LEDs present many advantages over traditional light sources including lower energy consumption, longer lifetime, improved robustness, smaller size and faster switching. However, they are relatively expensive and require more precise current and heat management than traditional light sources.

Type Working principle Invented Electronic symbol

Passive, optoelectronic Electroluminescence Nick Holonyak Jr. (1962)

Pin configuration

Anode and Cathode

Technology

The inner workings of an LED Free electrons moving across a diode fall into empty holes from the P-type layer. This results in a release of energy in the form of photons.

I-V diagram for a diode an LED will begin to emit light when the on-voltage is exceeded. Typical on voltages are 2-3 Volt

Physics Like a normal diode, the LED consists of a chip of semiconducting material impregnated, or doped, with impurities to create a p-n junction. As in other diodes, current flows easily from the p-side, or anode, to the n-side, or cathode, but not in the reverse direction. Charge-carriers electrons and holesflow into the junction from electrodes with different voltages. When an electron meets a hole, it falls into a lower energy level, and releases energy in the form of a photon. The wavelength of the light emitted, and therefore its color, depends on the band gap energy of the materials forming the p-n junction. In silicon or germanium diodes, the electrons and holes recombine by a non-radioactive transition which produces no optical emission, because these are indirect band gap materials. The materials used for the LED have a direct band gap with energies corresponding to near-infrared, visible or near-ultraviolet light. LEDs are usually built on an n-type substrate, with an electrode attached to the p-type layer deposited on its surface. P-type substrates, while less common, occur as well. Many commercial LEDs, especially GaN/InGaN, also use sapphire substrate. Models of led

The LED package is designed and constructed to focus the emitted light outwards.

Advantages Efficiency: LEDs produce more light per watt than incandescent bulbs.[59] Color: LEDs can emit light of an intended color without the use of color filters that traditional lighting methods require. This is more efficient and can lower initial costs. Size: LEDs can be very small (smaller than 2 mm2[60]) and are easily populated onto printed circuit boards. On/Off time: LEDs light up very quickly. A typical red indicator LED will achieve full brightness in microseconds.[61] LEDs used in communications devices can have even faster response times. Cycling: LEDs are ideal for use in applications that are subject to frequent on-off cycling, unlike fluorescent lamps that burn out more quickly when cycled frequently. Dimming: LEDs can very easily be dimmed either by Pulse-width modulation or lowering the forward current. Cool light: In contrast to most light sources, LEDs radiate very little heat in the form of IR that can cause damage to sensitive objects or fabrics. Wasted energy is dispersed as heat through the base of the LED. Slow failure: LEDs mostly fail by dimming over time, rather than the abrupt burn-out of incandescent bulbs.[62] Lifetime: LEDs can have a relatively long useful life. Shock resistance: LEDs, being solid state components, are difficult to damage with external shock, unlike fluorescent and incandescent bulbs which are fragile. Focus: The solid package of the LED can be designed to focus its light. Incandescent and fluorescent sources often require an external reflector to collect light and direct it in a usable manner. Toxicity: LEDs do not contain mercury, unlike fluorescent lamps. Disadvantages High initial price: LEDs are currently more expensive, price per lumen, on an initial capital cost basis, than most conventional lighting technologies. The additional expense partially stems from the relatively low lumen output and the drive circuitry and power supplies needed Temperature dependence: LED performance largely depends on the ambient temperature of the operating environment. Over-driving the LED in high ambient temperatures may result in overheating of the LED package, eventually leading to device failure. Voltage sensitivity: LEDs must be supplied with the voltage above the threshold and a current below the rating. This can involve series resistors or current-regulated power supplies. Light quality: Most cool-white LEDs have spectra that differ significantly from a black body radiator like the sun or an incandescent light. Area light source: LEDs do not approximate a point source of light, but rather a lambertian distribution. So LEDs are difficult to use in applications requiring a spherical light field. LEDs are not capable of providing divergence below a few degrees.

Blue Hazard: There is increasing concern that blue LEDs and cool-white LEDs are now capable of exceeding safe limits of the so-called blue-light hazard as defined in eye safety Blue pollution: Because cool-white LEDs (i.e., LEDs with high color temperature) emit much more blue light than conventional outdoor light sources such as high-pressure sodium lamps, the strong wavelength dependence of Rayleigh scattering means that cool-white LEDs can cause more light pollution than other light sources. Applications of LEDs are diverse. They are used as low-energy indicators but also for replacements for traditional light sources in general lighting, automotive lighting and traffic signals. The compact size of LEDs has allowed new text and video displays and sensors to be developed, while their high switching rates are useful in communications technology.

Resistor
A resistor is a two-terminal electronic component that produces a voltage across its terminals that is proportional to the electric current through it in accordance with Ohm's law:

V = IR
Resistors are elements of electrical networks and electronic circuits and are ubiquitous in most electronic equipment. Practical resistors can be made of various compounds and films, as well as resistance wire (wire made of a high-resistivity alloy, such as nickel/chrome). The primary characteristics of a resistor are the resistance, the tolerance, maximum working voltage and the power rating. Other characteristics include temperature coefficient, noise, and inductance. Less well-known is critical resistance, the value below which power dissipation limits the maximum permitted current flow, and above which the limit is applied

voltage. Critical resistance depends upon the materials constituting the resistor as well as its physical dimensions; it's determined by design. Resistors can be integrated into hybrid and printed circuits, as well as integrated circuits. Size, and position of leads (or terminals) are relevant to equipment designers; resistors must be physically large enough not to overheat when dissipating their power.

Units
The ohm (symbol: ) is a SI-driven unit of electrical resistance, named after Georg Simon Ohm. Commonly used multiples and submultiples in electrical and electronic usage are the milliohm (1x103), kilohm (1x103), and megohm (1x106).

IC7812

manufacturer, and is based on abbreviations (called mnemonics) that help the programmer remember individual instructions, registers, etc. An assembly language family is thus specific to certain physical (or virtual) computer architecture. This is in contrast to most high-level languages, which are (ideally) portable. Micro controller ca not take decisions on their own, they need to be programmed as per the problem statement. We can write program in two languages 1-Assembly language and 2-C language Assembly languages are a type of low level language for programming computers, microprocessors, microcontroller, and other (usually) integrated circuits. They implement a symbolic representation of the numeric machine codes and other constants needed to program a particular CPU architecture. This representation is usually defined by the hardware

The reasons for writing programs in C It is easier and less time consuming to write in C than Assembly C is easier to modify and update You can use code available in function libraries C code is portable to other micro controller with little of no modification Compilers produce hex files that is downloaded to ROM of microcontroller C programming is less time consuming, but has larger hex file size There is no relationship between c programming and assembly programming. Both of them are completely different except both can be compiled in same compiler.To compile code for 8051 series of micro-controllers we can use KEIL and for AVR series of Micro controllers we can use WINAVR. Following are the steps involved in burning program into micro controller. STEP 1 : Write the program in C language in software named AVR STUDIO 4 STEP 2: compile and build it .Actually micro controller understand only .HEX file . so we need to compile and build it .By building the program , a .HEX file is created and this HEX file is burned into the micro controller using programmer .

#include <avr/io.h> #include <avr/delay.h> void main() { DDRA=0xFF; DDRC=0x00; DDRD=0xFF; unsigned char x; while(1) { x=PINC & 0b00001111; if(x==1) { PORTA|=(1<<PA0); PORTD|=(1<<PD0); } else if(x==2) { PORTA&=~(1<<PA0); PORTD&=~(1<<PD0); } else if(x==3) { PORTA|=(1<<PA1); PORTD|=(1<<PD1); } else if(x==4) { PORTA&=~(1<<PA1); PORTD&=~(1<<PD1); } else if(x==5) { PORTA|=(1<<PA2); PORTD|=(1<<PD2); } else if(x==6) { PORTA&=~(1<<PA2); PORTD&=~(1<<PD2); } else if(x==7) { PORTA|=(1<<PA3); PORTD|=(1<<PD3); } else if(x==8) { PORTA&=~(1<<PA3); PORTD&=~(1<<PD3); } else if(x==9) {

PORTA=0xFF; PORTD=0xFF; } else if(x==10) { PORTA=0x00; PORTD=0x00; } else; } }

We have successfully done the interfacing of microcontroller & the PC individually as well as burning the hex code in the microcontroller. We have also done Mobile communication. We have used IC MT8870DE for encoding & decoding of data. We have used relay with transistor & microcontroller.

Bibliography
www.wikipedia.com www.avrfreaks.com www.atmel.com www.google.com

Anda mungkin juga menyukai