1 System Hardware Design
1.1 System Block Diagram
Design - A wireless transmission system based on the GSM communication module, using the SIM900A communication module and the LPC2378 controller to make a wireless Modem, and cooperate with the serial port terminal to send and receive SMS data, and use this Modem and the GSM network as a link to achieve long-distance data transmission. The design block diagram is shown in Figure 1.
1.2 Design of control module
The core chip of the control module is LPC2378, which is a 32-bit ARM7TDMI-S based microcontroller with a reduced instruction set and ultra-low power consumption launched by NXP Semiconductors (NXP). It is suitable for applications that require serial communication for various purposes. Due to its low power consumption, rich on-chip peripherals and convenient and flexible development methods, it has become a research hotspot in many single-chip microcomputer series. Its main features are: low voltage, ultra-low power consumption; operating voltage range of 3.0~3.6 V; 10-bit A/D converter on chip; 4 32-bit timers with flexible clock settings; the operating frequency of the on-chip crystal oscillator is between 1 and 24 MHz. It has 4 UART serial ports, which is convenient for users to communicate with multiple machines. It provides a total of 5 data ports from P0.0 to P4.0, which can provide users with more processing functions. Among the peripheral data ports provided, 4 have interrupt functions. It has a JTAG simulation debugging interface to facilitate software debugging. The chip can provide more memory, with 512 kB of on-chip Flash, and also provides more RAM for calculation processing.
1.2.1 Power supply
In this system, the LPC2378 microcontroller needs to be powered by 3.3 V and 1.8 V, so the National Company's LM117-33 and LM117-18 chips are used to achieve the voltage reduction from 5 to 3.3 V and 3.3 to 1.8 V. The LED light turns on after the power is turned on, indicating the power on and off; the capacitor is used for filtering to reduce interference to the input end. The power supply schematic is shown in Figure 2.
[page]
1.2.2 Serial communication and buttons
LPC2378 has two serial ports, USART1 is connected to SIM900A, and USART0 is connected to the host computer. The data to be transmitted by the host computer is temporarily stored in the microcontroller through serial port 0, and then finally transmitted to the SIM900A module through serial port 1, thereby realizing wireless data transmission. Although the working level of the serial port pin of the SIM900A module is CMOS level, and the working voltage of the serial port pin of the microcontroller is TTL level, the high and low level logic judgment level of the microcontroller can be connected to the pin of SIM900A, so the serial port line of the SIM900A module can be directly connected to the serial port 1 of the microcontroller, while the serial port 0 needs a MAX3232 for level conversion to communicate with the host computer, as shown in Figure 3.
1.3 Communication module design
SIM900A is a new generation of wireless communication GSM/GPRS module launched by SIMCom. It can quickly, safely and reliably realize data, voice transmission, short message service (SMS) and fax in the system solution. The working voltage of the module is 3.2~4.8 V, and the working frequency band is EGSM 900 MHz and DCS 1 800 MHz. SIM900A supports GPRS multi-slot class 10/class 8 (optional) and GPRS coding formats CS-1, CS-2, CS-3 and CS-4. The maximum power consumption of the frequency band is 2 W (900 MHz) and 1 W (1 800 MHz) respectively.
SIM900 A adopts power saving technology design, so the minimum current consumption in Sleep mode is only 1.0 mA. Common working modes include Sleep, Idle, Talk and other modes. With a size of only 24 mm × 24 mm × 3 mm, SIM900A can meet the space requirements of almost all user applications, such as M2M, data transmission systems, etc. SIM900A is SMT packaged, based on STE single chip solution, using ARM926EJ-S architecture, to achieve two-way transmission of power connection, instructions, data, voice signals, and control signals.
Keyboard and SPI display interface allow users to flexibly design customized applications. Main serial port and debug serial port can help users easily develop applications. One audio interface, including a microphone input and a speaker output. Programmable general input and output interface (GPIO). SIM900A has built-in TCP/IP protocol, and the extended TCP/IPAT command allows users to easily use TCP/IP protocol, and it is widely used in data transmission.
1.3.1 Power supply part
SIM900A uses a single power supply of VBAT with a voltage of 3.4 to 4.5 V. In some cases, the burst of signal transmission will cause voltage drop, and the peak current consumption will reach 2 A. Therefore, the power supply must be able to provide enough current of 2 A. To power SIM900A, Micrel's LDO MIC29302BT is used to achieve voltage reduction from 5 to 4 V, as shown in Figure 4.
[page]
1.3.2 SIM card circuitThe interface level of the SIM card is provided by the voltage regulator inside the module, and the normal voltage value is 2.8 V or 1.8 V. After reset, all pins output low level. The 6-pin SIM card circuit is shown in Figure 5.
1.3.3 LCD and keyboard interaction
The operation results of the control module can be displayed on the LCD, and the keyboard can be used to debug and set the period.
2 Software Design
2.1 AT Command
System Program Flow The focus of software design is on the programming of the single-chip microcomputer. By writing different AT commands to SIM900A, various functions can be completed, such as network login, reading the phone number on the SIM card, sending and receiving messages, deleting messages, etc. Here we focus on the sending of Chinese text messages.
2.2 PDU encoding rules
At present, the Text and PDU (Protocol Data Unit) modes are commonly used to send short messages. The code for sending and receiving text messages using the Text mode is simple and easy to implement, but the biggest disadvantage is that Chinese text messages cannot be sent and received; while the PDU mode not only supports Chinese text messages, but also English text messages. PDU mode can use three encodings for sending and receiving text messages: 7-bit, 8-bit and UCS2 encoding. 7-bit encoding is used to send ordinary ASCII characters, 8-bit encoding is usually used to send data messages, and UCS2 encoding is used to send Unicode characters. The general PDU code consists of 13 items: A, B, C, D, E, F, G, H, I, J, K, L, and M. In the GSM standard, Chinese characters are encoded using PDU, so Chinese characters need to be encoded before they can be sent out.
A: Short message center address length, 2-digit hexadecimal number (1 Byte); B: Short message center number type, 2-digit hexadecimal number; C: Short message center number, the length of B+C will be determined by the data in A; D: File header byte, 2-digit hexadecimal number; E: Message type, 2-digit hexadecimal number; F: Called number length, 2-digit hexadecimal number; G: Called number type, 2-digit hexadecimal number, the value is the same as B; H: Called number, the length is determined by the data in F; I: Protocol identifier, 2-digit hexadecimal number; J: Data encoding scheme, 2-digit hexadecimal number; K: Validity period, 2-digit hexadecimal number; L: User data length, 2-digit hexadecimal number; M: User data, its length is determined by the data in L. J is set to use UCS2 encoding, which is Unicode characters for Chinese and English.
2.3 Program flow
3 Conclusion
The system has been debugged and runs stably during the debugging process. The design cost and use cost are low. It can be widely used in remote security monitoring, PLC data acquisition and transmission, smart meters, vehicle communications, wireless POS, wireless medical, home anti-theft and other wireless transmission and automatic alarm systems. In the coming era of the Internet of Things, the application of wireless communication systems will play a key role.
Previous article:Design and implementation of digital signal source based on LPC2132
Next article:Design of touch screen touch point data acquisition system based on LPC2210
Recommended ReadingLatest update time:2024-11-16 15:18
- Popular Resources
- Popular amplifiers
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- Learn about ADI's smoke detection solutions and apply for free samples!
- EEWORLD University Hall----TI Smart Speaker and Sound Bar- Audio Session
- I would like to ask a question about circuit design.
- TMS320F28335 SVPWM source program
- Using TI DLP technology to drive structured light systems for bin picking accuracy
- Help, AltiumDesigner suddenly doesn't work
- Help: D11, D13 selection, thank you
- I see this device is always used in the circuit drive part such as motor controller
- Keil simulator plays RTT multi-threaded lighting
- Sensor circuit problem