Privacy statement: Your privacy is very important to Us. Our company promises not to disclose your personal information to any external company with out your explicit permission.
introduction
At present, urban security systems are getting more and more people's attention, and customers' requirements for the function and performance of security systems are getting higher and higher.
This paper proposes a wireless security system based on GSM and Zigbee technology. The system is characterized by the advantages of GSM and Zigbee wireless network, realizes the wireless network of security system, saves the cumbersome wiring process, and realizes security information. Multi-point, long-distance transmission improves the security, reliability and concealment of security systems.
1 system plan
The main design feature of the system solution is to combine the Zigbee wireless sensor network with the GSM network. The use of a wireless network not only eliminates the trouble of wiring, increases the flexibility of the layout of the security sensor, but also prevents the communication cable from being damaged and improves the security. The overall system structure is shown in Figure 1.
The system embeds the module with the Zigbee protocol into security devices such as passive infrared, glass breakage, door magnetism, smoke and gas leaks, as a node of the wireless sensor network. For example, when a theft occurs, the passive infrared sensor detects that the thief enters the monitoring area, which triggers the interruption of the node chip, thereby activating the node chip, and the chip will automatically send the sent alarm data packet through the Zigbee wireless transceiver module.
The Zigbee Coordinator is the interface between the Zigbee network and the external GSM network. As the core of the system, it is responsible for the management of the entire network and the forwarding of data. It receives the data of the security monitoring node through the transceiver module, and the embedded controller performs the necessary data. The processing is then sent to the security center via the GSM network for fast security alarms.
The whole system can be divided into two parts: Zigbee Coordinator and Zigbee Wireless Sensor Node.
1.1 Zigbee Coordinator
The Zigbee Coordinator has many tasks as the center of the entire system, so the controller responsible for managing the center is highly demanding.
The traditional single-chip microcomputer can not meet the requirements in some aspects. ARM is the first choice to replace the traditional one-chip computer because of its high performance, low power consumption and low cost. This design selects the ARM9 processor STR912FW44X6 chip as the core, and the peripheral expands a series of functional modules, as shown in the whole figure 2.
The STR912FW44X6 is the main control chip. It is a high-performance embedded chip based on ARM966E_S core from STMicroelectronics. It has a computing speed of 96MIPS and supports single-cycle DSP instructions. On-chip integration of 544kB Flash and 96kB SRAM, support for Ethernet, USB, UART, 12C and CAN communication, 80 GPIO, 8 channels 1O bit AI) C, 3-phase motor controller, watchdog timer and 9 programmable DMA channels. The system uses a UART transceiver chip TI's TL16C550 to connect the GSM module to the GPIO of the ARMCPU to implement GSM short message alarm transmission.
The GSM communication module uses the TC35i module of Siemens. The module has stable performance and low price. It has all the functions of GSM wireless communication and supports short message encoding in TEXT and PDU modes. In the RF transceiver, this design uses TI's Zigbee RF transceiver chip CC2420, CC242o adopts OQPSK modulation mode, supports data transmission rate up to 250kbps, and can realize point-to-multipoint fast networking. In addition, the coordinator also designed the RS232 interface, keyboard display and field alarm circuit according to actual needs.
1.2 Zigbee Wireless Sensor Node
The Zigbee wireless sensor node consists of a security sensor and a Zigbee terminal device, as shown in Figure 3. Zigbee terminal equipment uses TI's Zigbee RF transceiver chip CC2430, CC2430 has a high cost performance, integrated Zigbee radio frequency (RF), memory and microcontroller on a single chip.
It uses an 8-bit MCU (8051) with 128kB of programmable flash and 8kB of RAM. It also includes an analog-to-digital converter (ADC), timer, AES128 coprocessor, watchdog timer, 32kHz crystal sleep mode. Timer, power-on reset circuit, brownout detection circuit and 21 programmable I/O pins.
2 Zigbee Technology Introduction
Zigbee is the product of the Zigbee Alliance. This alliance of more than 100 internationally renowned hardware and software companies is working to develop a short-range, low-power, low-rate, low-cost wireless sensor network standard. Wireless Sensor Network (WSN) refers to an embedded wireless network consisting of a large number of sensor nodes with relatively low cost, sensing capability, computing power and real-time communication capability. It is a research and application hotspot in many fields.
3 system software implementation
The GSM communication module TC35i is controlled by the AT command, and the data transmission adopts the short message mode. The encoding and decoding methods of AT commands and short messages are the key to the software design of this system. The following focuses on the two.
3.1 Introduction to AT Command
The AT (AttenTIon) instruction set is the industry standard for modem communication interfaces, and most mobile phones on the market today support the AT command set specified in GSM 7.05. The instruction set was released by ETSI (European Telecommunications Technical Committee) and contains control instructions for SMS. The general GSM module supports the AT command, so the computer or the single chip can directly send the AT command to the GSM module through the serial port, thereby conveniently implementing the sending, receiving and management of the short message SMS.
3.2 Short message encoding
There are 3 modes for controlling short messages: BlockMode; PDUMode; TextMode. Currently, PDUMode has replaced BlockMode, TextMode does not support Chinese and most mobile phones do not support this mode. In China, both the mobile phone and the GSM module support the PDU mode. To meet the versatility of the system, the short message of the system uses PDUMode. So what is the PDU mode? Simply put, it is a way to send or receive a mobile phone SMS. On the surface of the PDU string is a string of ASCII codes consisting of numbers and letters o~9 and A~F. They are 8-bit hexadecimal numbers or BCD code decimal numbers. The PDU string contains not only the message itself, but also many other information, such as the SMS service center number, the target number, the reply number, the encoding method, and the service time. The PDU string structure sent and received is not identical. The PDU encoding format of the short message is described below (Table 1, Table 2).
SCA: The address of the SMS center, for example, Xi'an is +8613800290500;
FO: file byte header, set to 11 when texting;
MR: information type, usually 00;
DA: destination address;
0A: sender address;
PID: protocol indicator, usually takes O0;
DCS: data encoding scheme, O0 is 7-bit encoding, F6 is 8-bit encoding, and O8 is double-byte encoding;
VP: expiration date;
UDL: the length of the user data, that is, the length of the actual short message content;
UD: User data, ie SMS content;
SCTS: Short message center timestamp.
3.3 Sending and receiving short messages
To send and receive short messages, and to exchange information between the GSM module and the mobile phone, the information must first be encoded and decoded in the PDU format. This system uses Unicode encoding. Unicode is a unified character encoding standard that encodes characters in double bytes. This Unicode feature is that all characters are represented by two bytes, not only Chinese uses two bytes, but English also uses two bytes.
The procedure of short message sending and receiving in PDU mode is: set "AT+CMGF=0" to PDU mode; use "AT+CMGS=length", followed by PDU packet to send short message; use "AT+CMGR=serial number" to read Take the received short message.
For example, you need to send the message "Stolen in the home!" to the mobile phone 13991885678. The MCU first sends AT+CMGS=25 to the GSM module through the serial port, waits for the ASCII character "" to be returned, and then outputs the PDU data string and ends with Ctrl+Z.
4 Conclusion
The design scheme provides a flexible and convenient wireless solution for the construction of the security system by means of the short message service of the GSM network and the Zigbee wireless sensor network technology. The system has good scalability and practical value, and can realize all-round security monitoring and protection. The most important point is that the system can reliably communicate with users through the wireless network, which enhances the security and reliability of the system. Sex and concealment.
Email ke pemasok ini
Privacy statement: Your privacy is very important to Us. Our company promises not to disclose your personal information to any external company with out your explicit permission.
Fill in more information so that we can get in touch with you faster
Privacy statement: Your privacy is very important to Us. Our company promises not to disclose your personal information to any external company with out your explicit permission.