Design and implementation of vehicle-mounted wireless anti-theft alarm device based on SIM300

Publisher:MysticalEssenceLatest update time:2012-03-01 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

With the continuous expansion of the monitoring scope, the traditional wired monitoring alarm can no longer meet the needs of users. However, with the development of the GSM network, the hardware implementation of the remote network monitoring alarm system has become possible, and it is expected to replace the traditional monitoring alarm system controlled only by a single machine. This paper designs a remote wireless alarm monitoring system based on the GSM network in response to current needs. The basic idea is to connect the single-chip microcomputer and the SIM300 communication module through the serial port to realize the mutual communication between the single-chip microcomputer and the SIM300. The SIM300 module is equipped with a SIM card slot, which can realize the function of mutual communication with various users. The system is connected with vibration, infrared, sound and other types of sensors. When the car is in an alarm, the sensor transmits the alarm signal to the single-chip microcomputer. After the single-chip microcomputer judges and processes it, it sends an alarm text message to the user, or directly dials the alarm phone. If the situation is urgent, the user can directly send the SMS password, and the single-chip microcomputer controls the relay to cut off the line or oil circuit to stop the car from running, thereby realizing remote control and effectively ensuring the safety of the car.

1 Hardware circuit design

The hardware part of this design includes the microcontroller main control module, LCD display, key circuit, power supply circuit, signal acquisition circuit and control circuit. The system structure block diagram is shown in Figure 1.

1.1 MCU control circuit

The system uses the STC89C52 microcontroller, which is a low-power, high-performance CMOS 8-bit microcontroller with 8 KB system programmable Flash memory. This type of microcontroller has a high cost-effectiveness and is widely used in various fields such as industrial control, instrumentation, communication equipment, and household appliances [1].

1.2 GSM module circuit

This system uses the SIM300 module, in which the 16th pin of the SIM300 is connected to the network indicator light (LED) to indicate the strength of the SIM300 signal, and the 17th pin is connected to the P3.3 of the microcontroller. When it works, the microcontroller first sends a low-level signal to put the module in working state. 43, 41, and 49 are serial communication interfaces, which are respectively connected to the P3.0, P3.1, and P3.2 of the microcontroller. Pins 1, 3, 5, 7, and 9 are connected to a 4.2 V power supply. SIM300 and the microcontroller are connected through a serial port. The microcontroller control system can send AT commands to the SIM300 module to control its working state [2-3].

1.3 Keyboard, display and external storage circuit

This system uses a 4-row 3-column matrix keyboard, where the row lines are connected to P1.0~P1.3, the column lines are connected to P1.4~P1.6, and the column lines are connected to the +5 V power supply through a 10 k? resistor. There are 12 keys in total, which are set to 0~9, *, # and other key numbers.

This system uses LCD12864 liquid crystal display module, which can display 4 lines of Chinese characters or characters per screen, used to display prompt information and mobile phone numbers.

This system requires the user's preset mobile phone number to be stored during use, so an external memory is required. In the case of small storage information, AT24C02 can be used.

1.4 Sensor and relay circuit

This system uses vibration sensors, infrared sensors, and sound sensors to work together to effectively avoid system false alarms and misreporting.

The relay circuit is used to cut off the oil circuit or circuit and control the running state of the car. When the user sends a control command with a mobile phone, a certain port of the microcontroller outputs a high-level signal to control the relay. When the alarm is lifted, just send a release command to restore the normal operation of the car.

2 Software Design

The main program flow chart is shown in Figure 2.

3 Monitoring and alarm process

3.1 Setting process

The user needs to set the mobile phone number and SMS center number when using it for the first time. Turn on the power and follow the prompts on the LCD display to preset the number through the keyboard. The local SMS center number and personal control number need to be set. The set numbers are stored in the external memory. After the preset program is completed, the microcontroller sends an AT command to SIM300 to control it to send a verification SMS "Setting successful" to the preset number. If it is not the first time to use, if the number is not reset within 10 seconds after the prompt to enter the password, the number setting stage will be automatically skipped and normal monitoring will begin. The setting process is shown in Figure 3 [4].

3.2 Monitoring process

When SIM300 is in working state, if there is an abnormal situation in the car, such as the door is opened, the window is broken, the strong vibration or sound is generated, etc., as long as one of the sensors is triggered, the level of the microcontroller pin connected to the sensor will change (from low level to high level). This change is used as a signal. After the microcontroller determines that it is an alarm signal, the microcontroller will control SIM300 to send a text message to the preset personal monitoring number, for example: "Your car has an emergency, please check it in time." The monitoring process is shown in Figure 4.

3.3 Control Flow

When SIM300 is in working state, if an emergency occurs, such as a car being stolen, the fuel tank valve needs to be closed urgently to stop the car. Edit the text message "Close" and send it to the SIM card connected to SIM300. After receiving the text message, SIM300 stores the information in the SIM card. The microcontroller sends a command to read the message just received, including the incoming signal code, the length of the text message, the content of the text message, etc. The microcontroller parses it into a PDU code to determine whether the incoming signal code is the preset user control number. If not, the subsequent work is stopped and the command is considered invalid. The microcontroller sends a command to SIM300 to delete the text message; if it is a preset number, check whether the text message meets the preset command. If not, stop the subsequent work and delete the text message; if it meets, execute the corresponding command, that is, the level of the microcontroller pin connected to the relay changes (from low level to high level), and deletes the text message at the same time (so that each received text message in the SIM card is stored in the first position, which is convenient for reading next time). The output signal is then amplified by the signal amplifier to reach the voltage that makes the relay work normally, cut off the fuel tank supply switch, and stop the car. The control flow is shown in Figure 5 [5].

After debugging of software and hardware, all functions of this system can be well realized, effectively ensuring the safety of the car. This system combines the single-chip microcomputer with the SIM300 functional module, making full use of the mature GSM mobile communication network and overcoming many limitations of ordinary monitoring systems. This idea can also be used in the fields of household appliances, agricultural large-scale production, etc. This solution has many advantages such as saving wiring resources, wide control range, strong versatility, and high cost performance.

Reference address:Design and implementation of vehicle-mounted wireless anti-theft alarm device based on SIM300

Previous article:Blind spot detection function doubles the new generation of Focus active safety
Next article:A look at automotive safety design from Freescale's SafeAssure functional safety solution

Latest Automotive Electronics 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号