Nowadays, short message services are becoming more and more popular. Various telephone manufacturers are competing to design and develop short message terminal phones. In order to cooperate with the special integrated chip for short message terminals developed by our institute, we have designed and developed a fixed telephone that can send and receive short messages. In addition to the caller ID function, this phone can also receive FSK format text messages transmitted by the information center, and can upload information in both DTMF and FSK formats. It has a better human-computer interface and can use the pinyin input method to edit the text message content. It can store 200 calls, 200 downloaded text messages, and realize functions such as phone number search, downloaded text message reading, clock display, etc. The following will first introduce the design of the system from the hardware aspect.
Hardware parts
Figure 1 System hardware block diagram
Figure 2 CAS detection principle circuit The
hardware principle block diagram of the system is shown in Figure 1. The functions of each part are described below.
CPU control part
The system uses 80C31 as the main control CPU, which is responsible for the program flow of the entire system. It has an external 32K RAM, 64K EPROM, and an ATMEL AT29C040A as the storage for phone books, short messages, and secondary font fonts.
CAS detection circuit
The CAS detection principle circuit is shown in Figure 2. In SMS calls, CAS signal detection is essential, but ordinary phones and caller ID phones in the past did not have this function, and chips with CAS tone detection function are also relatively rare in the market. Therefore, we designed a CAS tone detection circuit, which has a good effect in practical applications (see Figure 3).
Figure 3 Actual CAS detection circuit
CAS is a DTMF signal with a frequency of 2130/2750Hz, so two separate filters are used. If it is CAS, the outputs of points A and B are both high, generating a CAS interrupt. In the figure, SIGNAL is a DTMF signal, and CAS_CON is a CAS tone detection control circuit. When CAS_CON=1, CAS tone is detected; when CAS_CON=0, CAS tone is not detected. When CAS is detected, CASINT outputs a high level.
EPLD integrated control circuit
The external control circuit uses ALTERA's EPM7128QC160, which integrates all the 74 series and 4000 series chips used in the design. It has 160 pins, which can meet the needs of the input and output signals in the system. It greatly reduces the PCB area, is very convenient for debugging, and improves the overall reliability of the system. [page]
The other parts are all ready-made chips or mature circuits, so they are not described here. The
software
adopts modular design, and each module can be designed and debugged separately. There are mainly keyboard processing module, system state conversion module, phone processing module (including FSK short message processing and sending), LCD display module, interrupt processing module (CAS, FSK, ringing, on-hook detection and FSK short message reception). Except for the interrupt processing module, the other four modules are called cyclically in the main program.
Keyboard processing module
The phone and CPU use the same key to work, and the CPU controls the key transfer direction through the analog switch. When making a normal call or picking up the phone, the key value is passed to the dial chip in the phone; when hanging up, it is passed to the CPU for processing. The CPU keeps monitoring whether a key is pressed. When a key is pressed, the system state transition flag is set to 1, otherwise it is 0. For ease of use, four more keys are added than ordinary phones: cancel key (key_C), main menu key (key_M), select key (key_OK), and input method switch key (key_CH).
System state transition module
This is the core control part of the whole system. It switches between states and processes key values within states according to the different states of the buttons and the system. When the system state conversion flag is 1, enter this module. According to the different key values, corresponding processing is performed. The main states set by the system are: initial state (S_init), main menu state (S_mainmenu), phone book state (S_menu1), short message state (S_menu2), system setting state (S_menu3), add phone number state (S_addphone_1), add phone name state (S_addphone_2), add phone storage location state (S_addphone_3), find phone state (S_lookphone), SMS editing state (S_edit_sm), send SMS state (S_send_sm), read SMS state (S_read_sm), etc.
LCD Display Module
This part is displayed according to the state of the system. It mainly includes the display of menus, the display of edited Chinese characters and characters, the display of downloaded text messages, and the display of text messages and incoming call ID numbers. The most difficult part of the display is the display of Chinese characters and ASCII codes in text messages, because Chinese characters are displayed in full width and ASCII codes are displayed in half width. Otherwise, the display effect is not good, and the starting position of the display during page turning is also involved. The program flow used in the development is shown in Figure 4.
Figure 4 LCD display module flow chart
telephone processing module
This part is responsible for processing SMS calls, caller ID calls, and ordinary calls. When a ring comes, the call processing program is entered. The FSK signal sent by the exchange center is received, and according to the content of the signal, it is determined whether it is a short message or a caller ID call. For a short message, a reply message is sent and transferred to the short message processing module; when it is a caller ID (CALLER ID) call, the phone number will be displayed on the LCD. If no FSK information is received, it is determined to be an ordinary call. (The system does not consider the downlink DTMF format in the caller ID call for the time being). Figure 5 is its program flow chart.
Figure 5 Phone processing program diagram
Interrupt processing program (CAS, FSK, ringing, off-hook)
In the interrupt processing program, the reception of FSK signal, CAS signal, ringing and on-hook detection are mainly processed, and the corresponding flag position is set to 1 for the main program processing. Among them, the reception of FSK signal first uses the query method to synchronize FSK information, and after synchronization, it is received by the serial port of 51 single-chip microcomputer.
Conclusion
The designed fixed telephone network short message terminal has the ability to upload messages and receive short message terminal downlink messages (Class C terminal), meeting the requirements of "Technical Specifications for Short Message Transmission Based on Fixed Networks". It provides a verification platform for the dedicated integrated chip for short message terminals.
Previous article:Design and implementation of CAN module based on LPC2131 processor
Next article:Design of Embedded Vision System Based on Linux
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!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- 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
- LM358 increases the load capacity, and the output 1mA becomes 10mA
- Switching Converter Loop Design Guide - From Analog to Digital Control
- Another question about the network port
- Several questions about device address and CRC check
- 【TI recommended course】#Lecture on basic knowledge of electronic circuits#
- Questions about DAC zero scale and midscale
- Downloading files will cause the wireless mouse to freeze?
- [D-Gesture Recognition Device] Design Report Sharing of Topic D
- About FlexRay Communication Test
- Thank yourself