Design of intelligent anti-theft system for warehouse area based on AT89S52 and sensor

Publisher:春水碧于天Latest update time:2011-03-10 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
Abstract: This paper designs an intelligent warehouse anti-theft system with pyroelectric infrared sensor and AT89S52 as the core control chip. It can judge the input signal of the infrared sensor according to the set time period and execute the corresponding function subroutine; at the same time, it accepts keyboard input signal to realize human-computer interaction. The system can detect the plane range of 90~140 degrees, and the detection distance can reach up to 15 meters, which can effectively realize the security of the warehouse area.

0. Introduction

Intelligent anti-theft system has become an essential part of warehouse management. Digitalization, wirelessization and integration are the technical development trends of anti-theft systems. For this reason, modern anti-theft systems widely use infrared as sensor signals. Since infrared is invisible light, it has strong concealment and confidentiality. The anti-theft system based on infrared sensor signals has a simple structure and accurate and timely alarm, making it the best choice for security defense. This design mainly designs the basic functions of the intelligent warehouse anti-theft system, which can make judgments on the detected signals in different time periods and realize corresponding functions.

1. System solution

The system requires the following features:

1. The anti-theft system is in anti-theft state during the period from 18:00 to 08:00. When someone enters, an audible and visual alarm is issued and the entry time is recorded;

2. The anti-theft system is in the state of detecting the number of people during the time period of 08:00-18:00. Every time a person enters, it is counted once. When the upper limit of the number of people is reached, an alarm is issued;

3. The anti-theft system is in light control state during the period from 19:00 to 06:00. When it detects someone entering, the light will be turned on, and when no one is there, the light will be turned off.

The intelligent warehouse anti-theft system consists of five units: MCU, infrared signal detection, keyboard control, display unit, and sound and light alarm. The system block diagram is shown in Figure 1.

System Block Diagram


Figure 1 System Block Diagram

2. System Hardware

2.1 Main Control MCU

MCU is the control unit of the system, which completes the processing of input signals such as infrared and keyboard, and sends corresponding instructions to output units such as display, sound and light. MCU uses the single-chip microcomputer AT89S52, which is a low-power, high-performance 8-bit microcontroller with 8k in-system programmable Flash memory to meet the storage needs of user code.

2.2 Infrared signal detection unit

The detection unit uses a human infrared sensing module as a sensor to input alarm signals. The module has a long straight-line detection distance, a wide range, and relatively stable operation. When equipped with a Fresnel lens, the sensor's detection radius can reach 15m. The focal length of the Fresnel lens is generally around 5cm. When in use, adjust the distance between the Fresnel lens and the sensor according to actual conditions. Generally, fix the lens 1~5cm in front of the sensor.

The human infrared sensing module is shown in Figure 2. Pin 1 is connected to the negative pole of the power supply, and pin 3 is connected to the positive pole of the power supply. The power supply is 6~9V DC voltage; pin 2 outputs an alarm signal, the signal amplitude is about 4~6V, high level is effective, the horizontal sensing angle is 90~140 degrees, the vertical sensing angle is 15~30 degrees, the sensing distance is 0.5~15m, W1 can adjust the sensitivity, and W2 can adjust the output delay within the range of 5-120S.

Human infrared sensor module


Figure 2 Human infrared sensing module

After power-on, if someone moves in the sensing area, the module will have continuous pulse output until the person leaves the sensing area and stops outputting after a delay of a certain period of time.

2.3 Sound and light alarm unit

This unit uses a red LED and a blue LED to simulate a warning light, and a passive buzzer to simulate a siren. The effects of the warning light and siren are realized through programming. When there is an alarm signal, the microcontroller sends a command to drive the light-emitting tube and buzzer to realize the alarm function. Another LED realizes the lighting function.

2.4 Keyboard control unit

The keyboard control unit uses 8 independent keys to input data, which can adjust the time, set the upper limit of the number of alarms and release the alarm, thus realizing the human-computer interaction function of the system.

2.5 Display Unit

Considering that the amount of alarm information is not very large, the 8-bit common anode LED digital tube can fully meet the needs. The digital tube is cheap and flexible to program. The dynamic display method can also save the I/O port line of the microcontroller. The system diagram is shown in Figure 3.

System circuit diagram

Figure 3 System circuit diagram

3. System software

When the system is working, the main program is responsible for various initialization operations of the system, checks whether the hardware circuit is normal, and sets the timer. The specific process is shown in Figure 4.

Main program flow chart

Figure 4 Main program flow chart

When the system is working, if the infrared sensor detects someone approaching, a high-level alarm signal will be generated and input to the main control chip. The main program will jump to the corresponding functional area by querying the current time: if it is in the first period, the microcontroller will issue a command to realize the sound and light alarm and record the current time; if it is in the second period, the number of people passing by will be counted; if it is in the third period, the lighting system will be controlled to turn on and turn off the lighting system after the person leaves. The infrared signal judgment subroutine and the timing interruption process are shown in Figure 5.

Infrared signal judgment subroutine and timing interruption process

Figure 5 Infrared signal judgment subroutine and timing interrupt flow

Conclusion

This paper uses a method that combines pyroelectric infrared sensors with single-chip microcomputers to design an intelligent warehouse anti-theft system, and installs it in key warehouses. After actual testing, the system has the advantages of simple structure, low cost, timely and accurate alarm, and good concealment and confidentiality. It can be used in warehouses, shops, homes and property management.

Reference address:Design of intelligent anti-theft system for warehouse area based on AT89S52 and sensor

Previous article:Space vector control variable frequency power supply based on 68HC908MR16 single chip microcomputer
Next article:Using DSP to control high power factor PWM rectifier

Latest Industrial Control 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号