With the rapid development of China's economy, more and more families are buying cars, but with the increase of car theft cases. Although most vehicles are equipped with anti-theft systems, they are generally sound and light warnings. Once the distance between the person and the vehicle is too far, the owner will not be able to know the stolen vehicle in time and lose many alarm opportunities. If the owner has a GSM mobile phone that sends and receives short messages, the anti-theft system can realize real-time alarms, and the GPS can determine the location information of the specific vehicle, so that it is easy to find the lost car.
This article refers to the address: http://
1 core controller section
1.1 Introduction to STR710F Microcontroller
The STR71X is an on-chip microcontroller with integrated Flash and RAM. It is based on the high-performance ARM7TDMI core with rich peripherals and enhanced I/O capabilities. All devices in the family include on-chip high-speed single-voltage flash memory and high-speed RAM memory. Thanks to the embedded ARM core, the STR71X is compatible with all ARM tools and software.
1.2 STR710F microcontroller overall structure
The overall structure of the STR710F microcontroller is shown in Figure 1. The internal bus and two APB buses closely connect the system-on-chip and peripheral resources. Among them, the internal bus is the main system bus, connected to the CPU, memory and system clock; APB1 bus is connected to high-speed peripherals, APB2 bus is connected to system peripherals and interrupt control. The I/O ports include three 16-bit ports, P0, P1, and P2. The other peripheral interface pins are multiplexed with the I/O port pins. This processor supports the CAN bus function, which has important applications in automotive electronics.
2 GPRS Modem Introduction
The development system selects Wavecom's pj_q2403 next-generation GSM/GPRS dual-mode module. It adopts compact design and is fully compatible with the previous generation TC35 products, providing users with a simple, embedded wireless GPRS connection. The module's GPRS permanent online function provides the highest data transmission rate, small size, low power consumption, and can provide data, voice, SMS, and fax functions. It can be widely used for remote sensing measurement and record transmission, telematics, and telephone. This module is an ideal solution for high-speed data transmission, widely used in POS terminals and scanners, security systems, remote telemetry and information processing systems, tracking management systems, traffic control and navigation systems, portable control devices, GPRS; support EGSM900/ GSM1800 dual-band, support GPRSClass8/GPRSClassB, AT command direct control; CSD state maximum rate is 14.4 kbps, GPRS state maximum rate is 86.5 kbps.
2.1 GPRS service
GPRS was proposed by BT Cellnet in the United Kingdom as early as 1993 and is one of the implementations of the GSM Phase2+ specification. It is a GSM-based mobile packet data service that provides users with IP or X.25 connectivity for mobile packets. GPRS superimposes a new network based on the existing GSM network, and adds some hardware devices and software upgrades on the network to form a new network logic entity, providing end-to-end, wide-area wireless IP connectivity. Generally speaking, GPRS is a high-speed data processing technology. It is based on packet switching. Users can use GPRS to use various high-speed data services, including E-mail for Internet browsing. GPRS is a new GSM data service that provides a connection between mobile users and data networks, providing high-speed wireless IP and X.25 services to mobile users. Due to the use of packet switching technology, each user can simultaneously occupy multiple The wireless channel, the same wireless channel can be shared by multiple users, and resources are effectively utilized. GPRS technology 160 kbps of ultra-fast transmission can almost achieve wireless Internet access to the company's ISDN effect, to carry the Internet with you.
2.2 GPRS connection GPRS principle
The command interface provided by GPRS complies with the specifications of GSM07.05 (short message service and cell broadcast service data terminal equipment and data circuit terminal equipment) and GSM07.07 (AT command system of GSM mobile equipment). The ARM7 processor establishes a communication link through an AT command sent from the serial port. The instruction format of the AT command set starts with AT. The following are some AT commands commonly used to connect GPRS services.
After the above command is successful, the communication service with GPRS is established, and a communication link is established with the data center, and the data of the user data device can be sent and received at any time.
3 car anti-theft system structure and function
The car anti-theft system is mainly composed of an ARM7-based development board, a GPRS module, a GPS module, and a detection circuit.
3.1 Signal Acquisition
The signal acquisition system uses the sensor detection circuit to sense the effect of the outside world on the car, and collects and detects the effective signal. Usually, the vehicle is damaged and stolen in the following forms: 1 the body, the door, the window encounters a collision or a knock; 2 the door, the engine cover, the rear cargo door are abnormally opened; 3 the electrical circuit is damaged; 4 The car thief invades the car, or uses the stolen key to turn on the vehicle; 5 drag the vehicle or lift the vehicle off the ground when the anti-theft function is not removed.
This system mainly detects the vibration generated by the vehicle body by opening the door in an abnormal form (for example, opening the door with a fake key or forcibly opening the door), and then generating an electrical signal to the system. At this time, the position signal determined by the GPS can transmit specific vehicle position information to the vehicle owner or the center console through the GPRS module, which is beneficial for the owner to find the lost vehicle. At the same time, through the remote control control can realize the switch door, arming, disarming, controlling the opening trunk, controlling the car search, controlling the vibration alarm function, and the owner can leave no warm tone when leaving the car. When illegally starting or suffering damage, the vehicle control CPU sends a text message and a telephone call to the owner and the service center, the car alarm emits a voice alarm, and the four turn signals are continuously flashed, and the car can be automatically turned off.
3.2 Monitoring Center
The monitoring center is designed as a website, and its juice machine can be connected to the Internet via GPRS Modem as a server or data terminal. For the solution of the IP address problem, you can apply for a private IP address, or you can obtain the IP address on the Internet and send it to the other party via a short message. After the emergency device finds an emergency, it connects to the computer in the data center on the Internet network through the GPRS network. In the process of data transmission, both parties must know the IP address of the other party in order to exchange data, and the IP addresses of both parties should be directly accessible on the Internet. This requires the IP address of the control center computer to be independent on the Internet, not the IP address of the local area network.
Under normal circumstances, there are many kinds of connection between the control center computer and the Internet. The IP obtained by dial-up Internet access is dynamic and different every time. This requires the IP of the data center computer to be notified to the anti-theft device system before communication. The short message service can be used to send the IP of the data center computer to the SIM card in an agreed form, and the system reads the IP value from the SIM card. If the IP of the data center computer is fixed, it can be written when the anti-theft device system is initialized.
3.3 Vibration detection
The vibration detection sensor interface circuit is shown in Figure 3. The timer of the STR710FZ2T controller has a capture function. Use TimerA's capture pin (this pin is connected to R2), first set to the falling edge capture; after entering the falling edge capture interrupt, record the capture time of the falling edge as the start of the low time calculation; then set to the rising edge capture , enter the capture interrupt again to calculate the low level duration. Since this time may exceed the time of the clock overflow, it is necessary to record the number of overflows in the overflow interrupt, and calculate it when calculating the low time width.
When the low time width is obtained, it can be judged according to the time width whether an alarm is needed. If the time width is too narrow, it will be ignored; if the low time width enters the alarm range, the weighting will be performed, and the alarm will not be immediately reported, but the weighted values ​​will be accumulated, and if the weighted sum reaches the alarm limit, the alarm will be given, and Turn off capture interrupts. After this treatment, the false alarms often appear in the past anti-theft systems will be greatly reduced.
3.4 Hall sensor detection
The application schematic of a single Hall switching device is shown in Figure 4. Due to the extremely low power consumption of the A3210ELH, the maximum operating current is less than 3 mA, which can be directly driven by the I/O port of the microprocessor. At the input close to the chip A3210ELH, the bypass capacitor C1 should be set to 0.1μF to reduce the effects of external noise and internal ripple on the sensor signal. The output bypass capacitor C2 provides energy for the output transition signal and R1 is used for protection therebetween.
4 system software design
The software part is written in the embedded C language of the microcontroller, as shown in Figure 5. The software flow chart focuses on the vibration (anti-theft) detection part and the preparation of GPRS communication.
5 Conclusion
In summary, the vehicle intelligent anti-theft monitoring system based on GPRS and GPS is a brand-new car anti-theft device that utilizes the increasingly perfect global mobile communication network and ARM control technology. After mastering this technology, it is easy to promote it to building equipment safety monitoring, vehicle monitoring and dispatching, field data collection and monitoring, water and water monitoring, environmental remote monitoring, heating system monitoring, water pipe network monitoring and pipeline gas Monitoring and other places where the real-time requirements of the field data are not high. Its biggest advantage is the use of a public mobile communication network, which can quickly build a network, reliable communication, and low investment. With the development of China's mobile communication network, its application prospects are good.
Mini 500Puffs,Mini 500Puffs Disposable,Mini 500Puffs Disposable Vape,Mini 500Puffs Grape
Lensen Electronics Co., Ltd , https://www.lensenvape.com