Design of LCD voltage display oscilloscope system

Publisher:sigma28Latest update time:2021-04-23 Source: eefocusKeywords:LCD Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

This design takes ARM7 microprocessor as the core, and uses high-speed A/D in ARM7 as pressure measurement unit, which improves the reliability of data transmission; data results are displayed in real time through LCD, and the display mode is friendly and intuitive; RAM and UART are used to store and transmit data respectively, realizing long-term storage of monitoring data and communication transmission with PC. Instruments using 31/2-bit or 41/2-bit segment LCD digital displays are not uncommon, but the functions of segment LCD displays are relatively limited. For multi-functional intelligent instruments, dot matrix LCD display modules are used to provide richer and more flexible display content. Dot matrix LCD display module is a display device that integrates display, control and drive. In order to simplify the circuit and give full play to the performance of ARM, a 320×240 16-level grayscale LCD is used.


System overall design


This system requires the software to complete the following functions.


Real-time data acquisition function. The system is required to be able to collect real-time data of external voltage.


Sampling data processing function. After the system completes real-time data acquisition, it needs to process the data in real time. Real-time processing mainly involves high-speed A/D conversion of external voltage and then dynamic display. The system can also use buttons to dynamically modify the alarm setting value.


LED display and RTC function. This experiment makes full use of the LED display and real-time clock functions.


Alarm processing function. Compare the real-time data with the maximum voltage measurement value set by the human-machine dialogue, and then make an alarm action.


Display maximum value function: Save and display the maximum value in real-time data.


By using the EEPROM read and write data function, the system can read 110 bits of real-time data from the last operation when powered on, and use it as the historical data for this operation. The system can also store the current 110 bits of real-time data by pressing a button.


Serial port data sending function: The system can send 100-bit real-time data to the host computer through the serial port by pressing a button.


In order to realize the clear module structure of the system, this system adopts μC/OS-II operating system. According to the above requirements, this system divides the software into 4 functional modules: A/D acquisition module, LED display and key processing module, LCD display module, alarm, storage and serial port processing module. The sampling module completes the sampling and storage of real-time data; the main function of the LED display key processing module is to process the sampled data and convert them into meaningful parameters; the LCD display module displays various parameters on the LCD; the alarm, storage and serial port processing module mainly processes the real-time data accordingly. Figure 1 is the overall structure diagram of the overall system design.



Figure 1 System overall block diagram


System hardware composition and functions


1 LCD display part


Liquid crystal display (LCD) has many advantages that other displays cannot match, such as low power consumption, small size, light weight, and thin thickness. It is widely used in terminal display and human-machine interface of microprocessor-based instruments and intelligent devices such as monitoring and control. STN LCD - Most of the monochrome LCDs sold on the market are of this type. STN LCD can choose STN LCD module with built-in LCD driver/controller. TFT LCD - commonly known as "true color" liquid crystal. TFT LCD usually must choose bus-type LCD display, or external ARM LCD driver board can also be used. In short, it must be able to connect to a microcontroller or arm.


2 LED display and keyboard module


The keyboard display part uses the 8-bit LED digital display and 8-bit keyboard input that we are most familiar with. Figure 2 is the circuit diagram of the self-made LED display and keyboard module. It uses the SPI bus of Philips, which is simple and practical, and has five pins.



Figure 2 LED display and keyboard module


System software design


1 Design Concept


In this simple oscilloscope system, we use the high-performance ARM LPC2138, because the ARM processor has a very fast processing speed and it has 4 A/D conversion channels. We know that Fpclk in ARM is the frequency of ARM peripherals. Under normal circumstances, it is 1/4 of the operating frequency of the ARM core, but we can modify and set Fpclk to be equal to the frequency Fcclk of the ARM core. Then we set the A/D conversion function to be non-frequency-divided, and we can set the sampling accuracy to 8 bits. In this way, the time for each A/D conversion is equal to 9 times the operating frequency of the ARM core, so the time for each A/D conversion is quite fast. At this time, we use two-way A/D interval sampling, so that the time for each A/D conversion is shortened by half. Theoretically, the sampling time for each A/D conversion is about 2μs. In this way, the response speed of this system to the external voltage is improved by a level, so the A/D performance of this system is relatively high.


2 Division of tasks


According to the principle of task division, six tasks are analyzed: delayed creation sampling task, sampling task, alarm task, real-time clock display task, serial port task, and sampling data display task. Among them, the sampling task has the highest priority of 4, the sampling data display task has a priority of 7, the serial port task has a priority of 8, the alarm task has a priority of 9, and the real-time clock display task has a priority of 10. In order to perform initialization work, the initialization and tasks of the target board, the creation of mutex semaphores, and semaphores are added to the delayed creation sampling task.


3 Analysis of shared resources


In this test requirement, the sampled data must be displayed on the LCD screen in real time and can also be uploaded to the host computer through the serial port. Therefore, resource synchronization methods must be adopted, otherwise the time may be disrupted. There are generally two ways to achieve resource synchronization: turn off interrupts; use mutually exclusive semaphores. Mutually exclusive signals are used in this test.


4 Behavioral synchronization


In this test, two behavior synchronizations are used. The first is the display of sampled data. The test requires that the currently sampled data be displayed on the LCD screen, so in the data display task, you need to wait for the signal that the sampling task is completed. When the sampling is completed, send the signal to display the current sampling result. The second is to query the historical records. The records will be displayed only when the user wants to query the historical records, so set the waiting query signal in the historical record query task. Only when the tasks cooperate and coordinate with each other can the predetermined effect be achieved, so that the synchronization of tasks can be achieved.



Figure 3 Sampling task flow chart


5 Software Design Module Flowchart


The embedded operating system is the interface between the embedded system hardware and the application software. Its use can improve the efficiency of software development, and its reliability and stability directly affect the system's operating performance. This software design uses the open source μC/OS-II multi-task real-time operating system. As a real-time microkernel, μC/OS-II is actually an efficient task scheduler. The scheduling is thread-level. The scheduling strategy is to use a static priority allocation method and a preemptive scheduling principle. In order to realize the basic task scheduling function, μC/OS-II provides the necessary inter-task communication means, including semaphores, mailboxes, etc. In order to realize task delay, it also has basic clock management.


Keywords:LCD Reference address:Design of LCD voltage display oscilloscope system

Previous article:ARM Linux development phase summary
Next article:Research on Wireless Monitoring System Based on Embedded Windows CE5.0

Recommended ReadingLatest update time:2024-11-16 14:30

AT89S51I2C Control PCF8576 Segment LCD Module
After a long period of tinkering, this segment code screen in my hand can finally display numbers according to my requirements. This small digital screen has been in my hands for a long time. I remember that I bought it when I just started playing with single-chip microcomputers. At that time, I spent 3 yuan to buy an
[Microcontroller]
AT89S51I2C Control PCF8576 Segment LCD Module
A LCD display technology based on DSP
  1 Introduction   With the development of electronic product integration, liquid crystal displays are more widely used in portable instruments to display images or texts.   At the same time, in today's information age, digital image processing technology has increasingly higher requirements for real-time performanc
[Embedded]
Program for 51 MCU to drive 1602 LCD
/********************************************************************* File name: lcd1602.c File function: lcd1602 LCD driver *********************************************************************/ #include "lcd1602.h" /********************************************************************* Function: Read LCD status
[Microcontroller]
Digital voltmeter made of LCD1602+ADC0809
  //******************************** //Digital voltmeter made by LCD1602+ADC0809 //Interface mode: bus extension //Author: Zeng Xianyang //Website: http://hi.baidu.com/zxymcu //******************************** #include #define ADC0809Addr 0x78ff #define LCDWriteComAddr 0xa7ff  #define LCDWr
[Microcontroller]
Foxconn responds to Wisconsin: Never promised to build LCD factory
In October, Wisconsin rejected Foxconn's subsidy application on the grounds that the company failed to build the LCD factory stipulated in the contract signed with the state. However, Foxconn said in its latest filing that it had never promised to build an LCD factory in the contract.     Foxconn has already built a
[Embedded]
Foxconn responds to Wisconsin: Never promised to build LCD factory
Power management optimization for small backlight screens
Analogic Tech has announced the launch of the AAT282X active matrix thin-film transistor (TFT) liquid crystal display ( LCD ) DC/DC converter product group, including a W LED driver and VCOM buffer, providing a fully integrated power solution for p
[Power Management]
BOE releases 4K-level strip screen, narrow frame design becomes the trend of high-end supermarkets
In addition to LCD screen optical fingerprint recognition, BD Cell low-power panel, and 8K ultra-clear panel, BOE recently released the world's first 1209mm long and 63mm wide strip screen, referred to as 1209mm, with an aspect ratio of approximately 20:1.   BOE Vice President Yuan Feng described it as truly a “big sw
[Embedded]
BOE releases 4K-level strip screen, narrow frame design becomes the trend of high-end supermarkets
1602LCD display driver for ATMEGA128
The power supply of this experimental development board is 5V. MCU source program: //1602 LCD display driver for ATMEGA128 //Compilation environment ICCAVR 7.16A //System clock 7.3728MHZ, set the fuse bit to external high frequency quartz crystal oscillator, start time 4.1ms //Edited by Zhongxing Electronic Componen
[Microcontroller]
1602LCD display driver for ATMEGA128
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号