With the improvement of residents' living standards and the enhancement of meteorological awareness, automatic weather stations have been vigorously developed in recent years. The automatic weather station requires a visual human-machine interface that can both publish dynamic weather data as well as send control commands to weather stations. Therefore, it is very important that the automatic weather station has a visualized liquid crystal display control module.
In order to save hardware resources, the STM32F103VET6 microcontroller is used to drive the 7-inch touch screen as the hardware platform of the display control module. For multitasking, the UC/OS-II operating system has been migrated and modified. At the same time, the interface design software interface UCGUI can be transplanted to realize the visualization man-machine interface. The automatic weather station control module that can be tailored by software and hardware can meet the task requirements of the automatic weather station work site, and also reduce the waste of hardware and software resources, and give full play to the advantages of embedded products in the industrial control field.
2, the overall system block diagramUsing STM32F103VET6 as the main controller chip, the TFT screen driver and touch driver are used to drive the 7-inch touch screen. The overall block diagram of the system is shown in Figure 1.
Porting UC/GUI and UC/OS-II for this CPU is the key to this article. The LCD driver and touch driver cooperate with the interface function provided by UCGUI to build a visual human-computer interaction interface, and transplant UC/OS-II suitable for multi-tasking of this series of CPUs.
Figure 1 system as a whole
3, drive touch screen hardware circuit designBased on a comprehensive consideration of price and performance, STM32F103VET6 was selected as the main controller chip. STM32F103 series CPU adopts CORTEX-M3 core, the maximum working frequency is 72MHz, it has 256~512KBFLASH program memory, parallel LCD interface, compatible with 8080/6800 mode.
The LCD module uses the Innolux AT070TN90 series TFT screen. The liquid crystal display module is composed of an LCD panel, a SSD1963 control circuit, a power supply and a voltage regulator circuit, and a backlight control circuit. The SSD1963 control circuit includes a SSD1963 control chip, which is responsible for communicating with the processor, refreshing the internal memory according to the data transmitted by the processor, and controlling the LCD panel to refresh the display.
The interface between the TFT display and the STM32F103 is shown in Figure 2.
Figure 2 Interface circuit between TFT display and STM32F103
The surface of the TFT display is attached with a four-wire touch screen controlled by XPT2046. The Y+, Y-, X+, and X- of the touch screen are respectively connected to the four pins of the XPT2046. When the screen is pressed, the step-by-step 12-bit A/D converter with a 125KHz conversion rate inside the XPT2046 performs 2 A/D conversions to calculate the touch position, and then transmits it to the CPU in SPI bus mode.
1800W Carbon Fiber Heater,3 Steps Carbon Fibre Patio Heater,Carbon Fibre Room Heater,Carbon Fibre Radiant Heater
Foshan Shunde Josintech Electrical Appliance Technology Co.,Ltd , https://www.josintech.com