A design of energy-saving power-off protection circuit based on single-chip microcomputer

Publisher:trendsetter9Latest update time:2009-10-28 Source: 现代电子技术Keywords:MCU Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
Electricity brings economic benefits to human beings and is convenient and environmentally friendly, but we should save electricity, pay attention to safety, and prevent fires. Energy saving is a major issue to reduce costs and improve economic benefits. Paying attention to safety when using electricity and preventing fires are issues we need to pay attention to at all times. According to some social phenomena that cause fires, an energy-saving power-off protection circuit based on a single-chip microcomputer is designed.

1 Hardware structure design

The hardware circuit is shown in Figure 1. S1 is a manual power switch; S2 is closed when pressed and disconnected when released; when S2 is pressed, the microcontroller starts running, and after about 2 seconds, KM is closed, and AC 220 V can continuously power the electrical equipment. After 5 minutes of power supply, the microcontroller controls the power supply according to the information detected by the sensor; when a certain sensor detects information that makes P1.1 high, P1.0 outputs a 5 V high level to pin 3 of U4, while pin 2 of U4 is only 1.5 V, so that pin 1 of U4 outputs a high level to turn on VT1 and VT2, so that the 12 V DC power supply can power the coil of relay JZC-36F, and KM is closed, so that AC 220 V can normally power the electrical equipment. When the sensor detects the information that makes P1.1 a low level, after a delay of 1 minute, P1.1 is detected again. If P1.1 is a low level for 5 consecutive minutes, P1.0 outputs a low level to pin 3 of U4, and pin 1 of U4 outputs a low level to the base of VT1. VT1 is cut off, VT2 is cut off, the coil of relay JZC-36F is de-energized, KM is disconnected, and the AC 220 V power supply is cut off.

VD3 and VD4 are isolation diodes for line-OR operation, VD2 is a protection diode, VD1 is used to raise the emitter potential of VT1, and VT2 must use a high-power transistor, such as the JE9051 silicon medium-power transistor. In order to make the relay operate reliably, two power supplies, +5 V and +12 V, are designed in the circuit. The models or parameters of the components are shown in Table 1.

2 Sensor signal processing circuit

The sensor signal processing circuit is shown in Figure 2. The human infrared sensor is used to detect infrared rays of a specific wavelength emitted by the human body, and to perform non-contact detection at a long distance. Its operating voltage is 3 to 15 V. When a human body enters the sensor sensing area, the sensor receives a human infrared signal with a frequency of 0.1 to 8 Hz, and pin 2 outputs a weak AC signal.

The output signal of the sensor pin 2 is amplified in two stages and then output from pin 1 of U6. The signal amplitude is 0.5-5 V and the DC component is 3 V. U7, D5, D6, R14, R15, R16, and R17 form a dual-gate voltage comparator. If there is no signal output from pin 1 of U6, pin 2 of U7 is 3.3 V, pin 3 of U7 is 2.7 V, and pin 1 of U7 outputs a low level. When the output of pin 1 of U6 is greater than 4 V or less than 2 V, pin 1 of U7 outputs a high level to the CPU.

3 Software Design

The program flow chart is shown in Figure 3. When it is necessary to turn on the electrical equipment, press S2 for about two seconds to start the single-chip microcomputer, make P1.0 high, and close KM to continuously power the electrical equipment; make P1.1 high, and set P1.1 to input state. Start to detect P1.1 after 5 minutes. If P1.1 is high, make P1.0 high, assign R0 to 05H, and return to detect P1.1 again; if P1.1 is low, delay 1 minute, if R0 minus 1 is not 0, return to detect P1.1 again, if R0 minus 1 is 0, make P1.0 low, and cut off the power supply of the electrical equipment.

The reference source program is as follows:


4 Application Examples

The following example illustrates the application of this design. In a home, according to the structure of the living room, find a suitable location and install the actual circuit shown in Figure 1 in a closed box, which should be both convenient to operate and beautiful. S1 in Figure 1 can be replaced by the user's main power switch, and 4 to 6 human infrared sensors can be installed to detect whether there is anyone in the living room from different directions. The power supply of all electrical equipment in the living room except lighting is output from the AC 220 V output terminal in Figure 1. In this way, after the electrical equipment in the living room is started, if there is no one in the living room for 5 consecutive minutes, the power supply of the living room area will be automatically cut off, which not only saves electricity, but also prolongs the use time of electrical equipment, and can effectively prevent the occurrence of electrical fires.

5 Conclusion

The innovation of this article is to design a low-cost energy-saving and power-off protection circuit that can effectively save electricity, extend the service life of electrical equipment, and prevent electrical fires. It can be used at home, in offices, student dormitories, etc., and is easy to install and debug. A large number of practical uses have proved that as long as the sensor is installed in a suitable position, the design can work reliably to achieve the purpose of energy saving and power-off protection. However, different sensors are used for different control purposes. The signal output by the sensor is weak and must be amplified by two stages and a dual-gate voltage comparator. The pulse signal sent to P1.1 should be a strong pulse signal.

Keywords:MCU Reference address:A design of energy-saving power-off protection circuit based on single-chip microcomputer

Previous article:Principle and Application of Buck Dual Output Synchronous Controller LM5642
Next article:Lightning interference and protection to weak current equipment

Recommended ReadingLatest update time:2024-11-17 01:59

Analytical solution for reading measured resistance value from LCD display using single chip microcomputer
1 Introduction In the process of circuit testing, it is often encountered that due to the neglect of the influence of certain small resistances, there is a large error between the experimental data and the theoretical value, thus affecting the test effect. For example, there is often copper resistance in induct
[Microcontroller]
Analytical solution for reading measured resistance value from LCD display using single chip microcomputer
Application of communication between PC and single chip microcomputer
This article is about the application of the communication experiment between computers and single-chip microcomputers. It mainly includes the explanation of the experimental principle, hardware circuit diagram, source program, etc. Contents: 1. Application of MCU serial communication 2. PC controls
[Microcontroller]
Application of communication between PC and single chip microcomputer
Design of B-ultrasound detection tooling based on single chip microcomputer and CPLD
introduction Ultrasound propagates in the human body. Due to the differences in acoustic properties of various tissues in the human body, ultrasound will produce physical characteristics such as reflection, refraction, scattering, diffraction, attenuation, and Doppler frequency shift caused by the relative
[Medical Electronics]
51 single chip microcomputer course design: temperature and humidity alarm based on DHT11
This program is suitable for 51 series single-chip microcomputers. It is mainly used to read the value of DHT11 temperature and humidity module and display it on the digital tube. It also has the function of temperature and humidity alarm. When the preset value is exceeded, the buzzer alarms. It can run perfectly on t
[Microcontroller]
Freescale 16-bit MCU (10) - PIT module test
1. Introduction to PIT module PIT is the abbreviation of Periodic Interrupt Timer Module. The PIT timer of XEP100 MCU is an array of 24-bit timers. It can be used to trigger peripheral devices of MCU, and can also be used to generate periodic interrupts. The PIT module of XEP100 MCU has the following features: 1. 8
[Microcontroller]
Freescale 16-bit MCU (10) - PIT module test
PWM temperature control fan based on 51 single chip microcomputer
#include reg52.h //Include header files. Generally, no modification is required. The header files include the definition of special function registers. #include intrins.h #include stdio.h #include "18b20.h" #include "delay.h" #include "key.h" sbit RS = P2^5; //Define LCD1602 port sbit RW = P2^6; sbit EN = P2^7;
[Microcontroller]
PWM temperature control fan based on 51 single chip microcomputer
Traffic light control system realized by PIC microcontroller
1 Introduction my country's motor vehicles are developing rapidly, but urban road construction is lagging behind due to various historical reasons. Road congestion, obstruction and traffic accidents often occur. How to use today's computer and automatic control technology to effectively guide traffic, improve t
[Microcontroller]
Traffic light control system realized by PIC microcontroller
The first in China! The domestically produced, independently controllable, high-performance automotive-grade MCU DF30 chip is released
On November 10, according to the introduction released by Wuhan Economic and Technological Development Zone, on November 9, the 2024 Annual Conference of Hubei Automotive-Grade Chip Industry Technology Innovation Consortium was held in Wuhan Economic and Technological Development Zone. At the meeting, the
[Automotive Electronics]
The first in China! The domestically produced, independently controllable, high-performance automotive-grade MCU DF30 chip is released
Latest Power Management Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号