MGLS12864 Structure Features MGLS12864 and MCU SPCE061A hardware interface debugging

In many SCM application systems, LCDs are widely used in terminal display man-machine interfaces. The dot-matrix LCD can display characters and numbers, display graphics, curves and Chinese characters, and can achieve a variety of animation display effects, making the man-machine interface more friendly, and the use of operation more flexible and convenient. MGLS12864 is a relatively common graphic liquid crystal display module with built-in HD612 02 controller on the market. It has the advantages of low power consumption, small size, light weight, simple structure, and easy to use. SPCE061A is a 16-bit microprocessor developed by Sunplus after SPCE500A. The CPU core adopts a 16-bit μ'nSP microprocessor chip, which is more integrated and cost-effective than the MCS-51 series microcontrollers, and is more flexible and convenient to use.

This paper describes the structure characteristics of the dot matrix LCD MGLS12864 and the instruction system of the controller HD61202, and specifically design and debug the hardware interface circuit and software program of MGLS12864 and SPCE061A. After the actual operation, the liquid crystal display module works reliably and meets the design requirements.

1 How Does the MGLS12864 Work?

The MGLS12864 display module has two HD61202 built-in column drivers and one HD61203 as a row driver that can display 64 KB dot-matrix patterns. The number of dots is 64 lines & TImes; 128 lines, each screen can display 4 lines & TImes; 8 characters (16 & TImes; 16 dots per character). With 64 KB of internal memory, the display is divided into 8 pages.

1.1 Pin Characteristics

The MGLS12864 pin features are shown in Table 1.

Structural Features of MGLS12864 Debugging of MGLS12864 and SPCE061A Hardware Interfaces


According to the pin characteristics of Table 1, the MGLS12864 module has 18 pins. Pins 1 and 2 are two chip select signals. The definition of the combination function is: CS1, CS2 is 00 to prohibit use, and 01 is to select the left area, 10 When the right zone is selected, 11 o'clock is selected; 3 pins are the power supply ground Vss; 4 pins are the power supply voltage Vdd; 5 pins are the liquid crystal display driving power supply V0; 6 pins are the data command selector RS; 7 pins are Read/write select signal R/W; 8 pins enable signal E; 9~16 pins are data bus DB0~DB7, which can be easily connected with the microcontroller; 17 and 18 pins provide power for backlight.

1.2 HD61202 Instruction System

MGLS12864 controller HD61202 built-in 4096-bit (64 & TImes; 64) display RAM, each bit of RAM corresponds to a point on the LCD screen light, dark state, HD61202 through a series of operating instructions to achieve control of the display screen. The HD61202 instruction system is shown in Table 2.

Structural Features of MGLS12864 Debugging of MGLS12864 and SPCE061A Hardware Interfaces

(1) Display switch setting: When D=1, the LCD displays the contents of RAM, and when D=0, the display is turned off;

(2) Display starting line setting: L0 ~ L5 are values ​​in the range of 0 ~ 3FH (0~63 lines);

(3) page address setting: P0 ~ P2: setting page number (0 ~ 7), shows a total of 64 lines of RAM divided into 8 pages, 8 lines per page;

(4) column address settings: C0 ~ C5: set the display column address 0 ~ 3FH (0 ~ 63 lines);

(5) Controller status: Internal operation at BUSY=1, normal status at BUSY=0, display OFF at ON/OFF=1, open at ON/OFF=0, reset at REST=1, REST=0

Normal state. In the BUSY and REST states, all instructions other than the read status instruction do not contribute to the HD61202. Check BUSY status before operating HD61202 to determine if HD61202 can be operated;

(6) Read/write data instruction The column address is automatically incremented by 1 each time a read/write operation is performed. Before performing a read operation, there must be an empty read operation, followed by reading the data before reading out the data in the cell to be read.

PU Leather Phone Case

Pu Leather Phone Case,Pu Leather Iphone Case,Best Pu Leather Phone Case,Pu Leather Phone Case For Sale

Guangzhou Jiaqi International Trade Co., Ltd , https://www.make-case.com