Presentation on theme: "EE 413 Communication Electronics Capstone Design Project (Motion Detector Alarm Dialer) Instructor Dr. Pao Lo Liu Group Members Chee Fai NG (3032-0373)"— Presentation transcript:
EE 413 Communication Electronics Capstone Design Project (Motion Detector Alarm Dialer) Instructor Dr. Pao Lo Liu Group Members Chee Fai NG ( ) Jia Quan Cheok ( ) EE Department University at Buffalo
Project Title: Automatic Dial Alarm System Objectives:- To design and build application circuits using microcontroller. To understand how a dial alarm system work. To build a motion detector and understand how it work. To learn and understand PIC language which use to program the microcontroller.
How The Dial Alarm Circuit Work This dial alarm system consists of motion detector as an input. A trigger pulse will send by the motion detector once it sense any movement occurs within the coverage area. This trigger pulse will turn on a BC 557 transistor and deliver power to microcontroller. Microcontroller will then start to execute the program.
How The Dial Alarm Circuit Work (Cont.) The LED in the opto-coupler will be turns on and causes the line to be “picked up” by using a high gain Darlington transistor. The microcontroller then dials two pre set phone numbers to alert the listener by sent down a “Hee Haw” signal. A microphone with high gain amplifier also connected to the phone line to detect conversation or movement in the target area. The two numbers are then called again before the alarm closes down.
Dial Alarm Circuit
Dial Alarm Circuit (Cont.) Turn on circuit Tone detector DTMF wave shaping circuit High gain audio amplifier Opto-coupler Microcontroller
Turn On Circuit Need 6v power supply. Turn on the circuit by motion detector Microcontroller, diode and 100k resistor are the component use to keep the “turn on” circuit on. To ensure the alarm only carries out one alarm operation and resets and ready for another trigger pulse, the trigger device must be AC coupled to the circuit. The “turn on” circuit work by charging the top electrolytic Energy from the electrolytic flows into the base of the BC557 transistor and allows current to flow between collector and emitter leads and activates the rest of the project.
Tone Detector Use to detect any tone about 500Hz on the phone line like DTMF. Alarm will be turn off when tone is detected. The circuit amplifies the signal on the phone line and turns on a transistor. Biasing components keep the transistor off. When there is a signal, the transistor turns on and collector goes low and cause the 4.7uF electrolytic discharged via diode. At the same time, the 4.7uF electrolytic is getting charged via 100k resistor. The electrolytic will be fully discharged and will be detected by the microcontroller as low if the frequency of the signal is high enough.
DTMF wave-shaping circuit Dual Tone Multiple Frequency (DTMF) – waveform must be in sine wave. To convert a square wave into sine wave produce by the microcontroller. Waveform is form by charging and discharging capacitor by using a resistor. Two tones are produced separately by the microcontroller and then combined after wave shaping in order to reduce the interference between the two waveforms. The 10mH choke is used to smooth out the shape of the waveform and increased the dialing accuracy.
High Gain Audio Amplifier Build by two transistors which used to pick up sounds in the target area during the alarm activation. It is directly coupled to the phone line via a bridge. Any change in impedance of any components connected to the phone line will cause signal sent down the line. A 20mV signal from the microphone will produce 1000mV signal on the collector of the first transistor and passed to the output transistor. Amplitude of the waveform across the output transistor is about 2-3V. The pre-amplifier section is powered by the 5V supply where as the output transistor is driven from the phone line. Audio amplifier is off when the DTMF tone is sent down the line.
Opto-coupler It is used to picks up the phone line. The LED in the opto-coupler will be turned on when the motion sensor is activated. The LED turns on a phototransistor inside the opto-coupler and reduces the resistance between collector and emitter leads of the phototransistor and this pulls the base of a Darlington transistor towards the positive rail.
Microcontroller It is an 8-pin chip with 5 input/output lines and one output- only line. The output lines change from low-to-high-to-low very fast. The program set inside the microcontroller determines what happens on each lines and parts around it are use to adapt or modify or amplify a signal to suit the microcontroller or phone line.
Flow Chart Turn Off DTMF 2 nd Number Turn Off DTMF 1 st Number Detect Audio Hee Haw Detect Audio Hee Haw Detect Audio Start End Hee Haw Repeat second time
Multi Chip Programmer
What used to trigger the Dial Alarm System? Temperature/Voltage Level module Monitor temperature or voltage level presets Pressure map Listen-in Module Listen in to the area being protected Motion Module Detect moving persons and trigger the Dial Alarm.
PIR Movement Detector Pyro-electric infra-red movement detector centers around a Pyro-electric(‘body heat’) infra-red sensor & a KC778B controller chip. KC778B provides amplification, filtering, clock, comparators a daylight detector and a voltage regulator. PIR sensor three lead high impedance sensor. Requires a Fresnel beam focusing lens. Fresnel lens break up observation area into optical zones so a heat source moving from one optical zone to another generate heat waves on PIR detector’s surface. Lower gain circuit & excellent lens system
PIR Detector Schematic
Circuit Description There are three main sensitivity controls built into circuit:- Movement Sensitivity: Heart of this part PIR sensor Connected to pin 2, 7, & 8 of the KC778B. Pin 7 pyro drain reference, Pin 8 pyro source input. Control/adjust the sensitivity/”range” for the PIR sensors. The sensitivity controlled at pin 2, which is a PIR sensitivity input pin. Using a trimpot (potentiometer), P1(referred in the previous circuit) When P1 adjusted where equals the sensor drain potential (pin 7) (~0.5V), sensitivity max. When connected to ground,(~0.125V), sensitivity min.
Daylight Sensitivity: Adjust the sensor to be active for just the night and inactive during the daytime. This sensitivity controlled by another trimpot P2 and a LDR (light dependent resistor) which is connected to pin 12 on the microchip. (pin12 silicon photo diode input pin) P2 used to control how sensitivity the LDR to be against light. LDR has very high resistance (million of ohms) when no light, and significantly low resistance when illuminated (hundred of ohms). The Toggle terminal been configured to give user an exit delay about 30s so have time to leave the room after turning it on. Optional feature Could be disable by connect pin 12 to Vcc.
Pulse on-time Adjust: This part adjust the output pulse from between 1.5 seconds upwards when movement detected. The amount of time delay controlled by another trimpot P3 connected at pin 18 &19 of the KC778B chip (off timer OSC pins). Minimum time delay can be build by connect directly the pins 18 & 19 with no external capacitors and resistors. A terminal block then connected from the output pin from the chip where output signal from here is connected to the input of the Dial Alarm circuit.
KC 778B Controller Chip PIR Front End Amplifiers & Noise cancellation circuit Switched capacitor Bandpass Filter Oscillator & Synchronizatio n Citcuitry Threshold comparators & Timing circuitry Daylight Detector Amplifier and Comparator Voltage Regulator Sensitivity Adj Offset Filter Pyro (D) Pyro (S) Gain Select Anti Alias DC Cap Fref R C Daylight Sense Daylight Adjust LED OUTPUT V Reg
KC 778B Controller Chip (Cont’d) The heart of the whole circuit as the motion detection IC. Optimum with the electrical signals from the PIR sensors which have very low frequency (0.1 to 10 Hz) and bandwidth. Operating voltage is 4 – 15V. With the 78L05 voltage regulator we connected in pin 1(Vcc), the input voltage should be around 9 – 12V.
PIR Movement Detector (building and testing) When building up the system, we used ~2.5” by 3.5” PC Board. Be aware of the right polarity of capacitors, transistor, LEDs and the PIR sensors. Components especially the controller chip and PIR sensor could damaged easily it placed incorrectly. The PIR sensor, LDR and Fresnel lens are mounted on the copper side of PCB (opposite side of all components) So, the system be easily placed (e.g. in a box) with the lens poking out with the electronics on top of the PCB for easy access.
All components except PIR sensor, LDR and Fresnel lens on top of PCB PIR sensor, LDR and Fresnel lens mounted back of PCB
After building the whole circuit, we tested it in the electronics lab. We applied a 9V transistor battery to Vcc pin of the chip. Connect a voltmeter to the Output pin. When power applied, waited about 30 seconds and wave hand in front of PIR sensor. The LED indicator light, and the Voltmeter from the output jump from zero volts to 9 volts in the screen. When no movement detected, the LED light off and the voltmeter value back to zero.
Graphs Obtained from Testing needed warm up 30 seconds exit delay by the configured toggle terminal block (pin15 on chip) – detector not operate. Movement detected – LED light ~20s where the output voltage ~ 9V. No movement – LED light off where output voltage ~ 0V.
Question??? Finally the PIR movement detector ready to be cascade to the Dial Alarm circuit! Became a Motion Detector Alarm Dialer!