buydisplay.com
EastRising
4.2.3 Button Picture Setting and Display Command
Table 4-3: Button Picture Setting Command
Command
Function
Code
No.
Command
Parameter
Command Description
Button Picture
Display
Setting
A0h
#nn:
P(2), PNG(1), X(2), Y(2),
CM1(1), NU1(1), CM2,
NU2, CM3, NU3, CM4,
NU4, CM5, NU5, CM6,
NU6, CM7, NU7, CM8,
NU8
Display picture P at position (X, Y), PNG
= 1 means the background is
transparent (PNG), and PNG = 0 is not.
When touch Button picture P, the TFT
Panel will automatically execute the
CM command, and NU is the serial
number after the CM command. This
command can execute 8 sets of
commands simultaneously.
Cancel Button
Picture
A1h
nn
Cancel the A0h command.
For examples, input below command in
“UartTFT.ini”
:
80h #01: 3, 0, 180, 20
// display P3 at (180, 20)
88h #00: 3, 50, 100, Gif-1
// display GIF-1 at (50, 100), with speed
@30ms
A0h #00:
7, 1, 50, 50,
0x80, 0x01, 0x88, 0x00
// display P7 at (50, 50) 7 when touch P7, it will execute command 80h 01, and 88h 00 to
play Gif
After compiling the setup command, the host sends the display commands
A0h and 00
to TFT
Panel through UART, then the TFT will display the 7th picture at (50, 50) (with transparent
background), and when press on the 7th pictures, the TFT will execute the commands
80h and
01
, then the third picture will be displayed on the TFT (180, 20) (refer to Section 4.2.1).
Meanwhile, the TFT panel will display GIF-1 at (50, 100), shown as in the figure below.
Figure 4-7A: A0h Command Example
If the host sends the display commands
A1h and 00
to TFT Panel through UART, then the
original command
A0h 00
function(Button picture and touch control) will be cancelled.