Circuit design of multi-machine wireless short-range communication system based on single-chip microcomputer
Source: InternetPublisher:已注销 Updated: 2021/08/21
The rapid development of modern communication technology has led to the use of wireless communication methods for data transmission in many application fields. The circuit composed of codec chips PT2262 and PT2272 is widely used in various types of wireless remote controls, wireless alarms, toys and other small electrical devices due to its small size, low power consumption, strong functions, and low cost. However, this kind of circuit is rarely used in communication of multiple bytes of data and has certain limitations. This article mainly introduces the use of 433 MHz high-frequency transmitting module and receiving module to produce multi-machine wireless ASCII code format SMS communication. This communication method is to define a wireless transmission protocol based on the 433MHz high-frequency transmitting module and receiving module to realize multi-byte data communication between any two machines.
Host circuit design
Since the amount of programs involved in the system is relatively large, the storage capacity of the Flash program memory must not be too small; to store the transmitted and received text messages, an EEPROM data memory module is used. The contents stored in the EEPROM data memory will not be lost when the power is turned off. ; Receiving and decoding requires pulse width capture and comparison functions, and the capture/compare/pulse width modulation CCP module is required; independent timers are required for transmission, reception and clock, and the number of required timers is not less than 3. Based on the design needs, Microchip's PICl6F877A chip is used as the main controller of the system. The circuit is mainly composed of a main control chip, a crystal oscillator circuit and an online simulation interface, as shown in Figure 2. In the design, three interfaces, MCLR, RB6, and RB7, are used as online simulation interfaces.
Design of transmitting and receiving circuits
Using 433 MHz high frequency transmitting and receiving modules. The 433 MHz high-frequency transmitting circuit starts to oscillate and transmit high-frequency signals with constant amplitude when the control pin is at high level, and stops oscillating when the control pin is at low level. Therefore, the control pin can be used to complete amplitude keying (ASK modulation) of the high-frequency circuit, which is equivalent to amplitude modulation with a modulation degree of 100%. When the receiving module receives a 433 MHz constant-amplitude high-frequency signal, the signal pin outputs a high level, otherwise it outputs a low level. Therefore, the high and low level changes of the receiving signal pin will correspond to the high and low level changes of the transmitting control pin. Multiple receiving modules can receive signals from the same transmitting module at the same time, enabling one machine to send and multiple machines to receive at the same time. The circuit shown in Figure 3 is a transmitting and receiving module for a high-frequency 433 MHz carrier. When the control pin B5 is high in the 433 MHz high-frequency transmitting circuit, the transistor T1 is turned on, and the T2 emitter is grounded to start oscillating and transmit a high-frequency 433 MHz signal with equal amplitude; when the control pin B5 is low, it stops. oscillation. Therefore, control pin B5 can be used to complete amplitude keying (ASK modulation) of the high-frequency circuit, which is equivalent to amplitude modulation with a modulation degree of 100%. When the receiving module receives a high-frequency signal with a constant amplitude of 433 MHz, the signal pin outputs a high level to the C2 port. If it does not receive a high-frequency signal with a constant amplitude of 433 MHz, it outputs a low level. Therefore, the high and low level changes of the receiving signal pin will correspond to the high and low level changes of the transmitting control pin. For example, if the waveform shown in Figure 4 is input to the B5 pin, the same waveform will appear on the C2 pin of the receiving module. Note that the control signals of B5 and C2 are respectively sent by RB5 and RC2 of the main control chip PICl6F877A.
Design of LCD Peripheral Control Circuit
Using Nokia 3310 LCD display module. The LCD is an 84&TImes48 dot matrix LCD screen. One screen can display 4&TImes7 (12&TImes12 dot matrix) Chinese characters, or 6&TImes14 (6×8 dot matrix) English, numbers, punctuation marks and other characters. This LCD display is light, thin, short, has low power consumption, and is often used for mobile phone display. The LCD peripheral circuit is shown in Figure 5.
In this design, the Nokia 33lO LCD is powered by 3 V. Among them, pin 1 is the power pin, pin 6 is the ground wire, pin 2 is SCLK, and pin 3 is SDIN. Pin 4 is the data/address selection terminal, giving high and low levels to pin 4 respectively, which can control the microcontroller to write data or write commands to the Nokia 3310 LCD. Pin 5 is the enable terminal and is active at low level. Pin 8 is the reset terminal and is active at low level. Pin 11 is connected to the positive stage of the backlight power supply, and pin 12 is connected to the control stage of the backlight power supply. 9. Pin 10 is the speaker that comes with the Nokia 3310 LCD. The sound effect of this speaker controlled by a microcontroller is not ideal, so a DC built-in oscillation buzzer is used instead. In order to avoid the impact of the buzzer and backlight on the LCD power supply when they are working, the buzzer and backlight are powered by a 5 V power supply, which is separate from the LCD power supply.
The design method described in this article integrates encoding and decoding technology, communication protocol technology, anti-interference technology, text message editing technology, and liquid crystal dot matrix display technology. Any two machines can send text messages of 70 ASCII characters to each other, and text messages can be edited like ordinary mobile phones. The machine can be named by the user to distinguish it from other machines, realizing one-to-one communication. Universal names can also be used ( "WDX") realizes one-to-multiple machine communication. You can store a sent text message, a newly received text message and old text messages. The entire system has a friendly human-computer interaction interface, similar to an ordinary mobile phone system, with operation prompts and easy operation. The layered protocol used in this design can easily replace the wireless communication module with other wireless modules with better performance.
- Circuit diagram of intermittent cockroach killer
- Frequency signal tracking circuit (phase-locked loop circuit) composed of CD4046
- How to build an internet-connected traffic meter
- Electronic mosquito repellent circuit diagram
- DIY a temperature and humidity monitoring system
- CF1 (CF2) DC power supply circuit
- T4163A single column coordinate boring machine electrical schematic circuit (2)
- CM6123 lathe electrical control circuit_3
- Portable alcohol tester circuit diagram
- Main circuit of transformer composite thyristor pulse power supply
- How does an optocoupler work? Introduction to the working principle and function of optocoupler
- 8050 transistor pin diagram and functions
- What is the circuit diagram of a TV power supply and how to repair it?
- Analyze common refrigerator control circuit diagrams and easily understand the working principle of refrigerators
- Hemisphere induction cooker circuit diagram, what you want is here
- Circuit design of mobile phone anti-theft alarm system using C8051F330 - alarm circuit diagram | alarm circuit diagram
- Humidity controller circuit design using NAND gate CD4011-humidity sensitive circuit
- Electronic sound-imitating mouse repellent circuit design - consumer electronics circuit diagram
- Three-digit display capacitance test meter circuit module design - photoelectric display circuit
- Advertising lantern production circuit design - signal processing electronic circuit diagram