4G module acquisition and transmission system design

The system uses 4G data transmission module, DHT11 temperature and humidity collection sensor and STM32 microprocessor to design a data collection and transmission system based on 4G transmission module. The data acquisition terminal collects the temperature and humidity in the environment, connects to the RS485 pin of the 4G data transmission module, and transmits it to the cloud server through the virtual serial port for data monitoring.

With the development of communication technology, the transmission rate of data information is constantly increasing. In recent years, the coverage of 4G communication signals has become higher and higher, and communication efficiency has reached a high level. With the development of Internet of Things technology, 4G data transmission module (Data transmission unit, DTU) also occupies a very important position in the Internet of Things system. Data collection, transmission and storage can be seen everywhere in all walks of life. This system selects temperature and humidity, which has attracted more attention, as the collection object. In a communication environment with smooth 4G network, this system can be widely used in temperature and humidity monitoring places, and other types of data collection sensors can be expanded according to actual needs.

1. System Framework System

It consists of a data collection and transmission terminal, a 4G wireless transmission module and a PC. The data collected by the data collection and transmission terminal transmits the data to the cloud server through the 4G module. The system structure block diagram is shown in the figure.

2. System hardware design

The hardware design of this system mainly lies in the data collection and transmission terminal, which uses the 32-bit high-precision main control chip STM32F103RCT6 produced by ST (STMicroelectronics), the DHT11 temperature and humidity collection sensor and the 4G DTU-ZHC401C of Zongheng Intelligent Control.

3. System software design

3.1 STM32, RS485 and DHT11 system design The hardware design part of the program is written in C language using the MDK-Keil5 development platform. The main software design overall flow chart is shown in the figure.

1) Serial port initialization and delay function initialization, set the baud rate value to 115200; set the interrupt priority group, enable the serial port interrupt, and set the interrupt priority group to 2-bit preemption priority and 2-bit response priority. Each interrupt can be set to a preemption priority of 0~3.

The response priority is 0~3, and the timer interrupt uses TIM3 interrupt;

2) Enter the timer interrupt, initialize the DHT11 module, collect temperature and humidity at three locations and convert them in sequence;

3) Set the number of RS485 receiving buffer bytes and load the converted temperature data into the line interface.

Keywords: wireless terminal

Свяжитесь с нами