Jason ZHANG EN DGUS V5.10 User Guide
User Manual:
Open the PDF directly: View PDF
.
Page Count: 59
Professional, Creditable, Successful
DGUS_SDK User Guide_V5.1
Beijing DWIN Technology Co., Ltd.
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
Contents
1. DGUS_SDK Instruction........................................................................................................................................................ 4
1.1 Operation of DGUS_SDK.......................................................................................................................................... 4
1.2 Main Interface of DGUS_SDK_V5.1........................................................................................................................5
2. Basic Steps for DGUS_SDK Operation.............................................................................................................................7
2.1 Create a new project.................................................................................................................................................. 7
2.1.1 Start a new project...........................................................................................................................................7
2.1.2 Select corresponding resolution and save the path.................................................................................. 8
2.1.3 Add images....................................................................................................................................................... 8
2.1.4 Create a CONFIG.TXT file for setting system parameters.......................................................................9
2.2 Configure touch functions........................................................................................................................................ 11
2.3 Configure variable display....................................................................................................................................... 12
2.4 Create configuration files.........................................................................................................................................13
2.5 Download....................................................................................................................................................................14
3. Main Functions of DGUS_SDK.........................................................................................................................................15
3.1 Touch Config..............................................................................................................................................................16
3.1.1 Popup Window...............................................................................................................................................16
3.1.2 Variable Data Input....................................................................................................................................... 17
3.1.3 Incremental Adjustment................................................................................................................................18
3.1.4 Slider Adjustment...........................................................................................................................................19
3.1.5 RTC..................................................................................................................................................................20
3.1.6 Basic Touch Control...................................................................................................................................... 21
3.1.7 Return Key Code........................................................................................................................................... 22
3.1.8 ASCII Input......................................................................................................................................................23
3.1.9 Firmware Parameter Settings......................................................................................................................24
3.1.10 Status sync-returned...................................................................................................................................26
3.2 Variable Config..........................................................................................................................................................28
3.2.1 Variable Icon...................................................................................................................................................28
3.2.2 Animation Icon................................................................................................................................................29
3.2.3 Slider................................................................................................................................................................30
3.2.4 WordArt........................................................................................................................................................... 31
3.2.5 Image Animation............................................................................................................................................ 32
3.2.6 Icon Rotation.................................................................................................................................................. 33
3.2.7 Data Variable..................................................................................................................................................34
3.2.8 Text Display.................................................................................................................................................... 35
3.2.9 Digital RTC Display....................................................................................................................................... 36
3.2.10 Analog Clock Display..................................................................................................................................37
3.2.11 Dynamic Trend Curve................................................................................................................................. 38
3.2.12 Table Display................................................................................................................................................39
3.2.13 Basic Graphic Display................................................................................................................................ 40
3.2.14 Special Industrial Application.................................................................................................................... 42
3.2.15 Bit Variable Icon...........................................................................................................................................43
3.2.16 Timer Variable..............................................................................................................................................45
3.2.17 RollText......................................................................................................................................................... 46
4. Commands........................................................................................................................................................................... 47
4.1 Data Frame................................................................................................................................................................ 47
Beijing DWIN Technology Co., Ltd.
2
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
4.2 Command Set............................................................................................................................................................47
4.3 Register...................................................................................................................................................................... 47
4.4 VP & SP......................................................................................................................................................................49
4.4.1 VP (Variable Pointer).................................................................................................................................... 49
4.4.2 SP (Stack Pointer).........................................................................................................................................51
4.5 Examples....................................................................................................................................................................53
4.5.1 Access Register of DGUS............................................................................................................................54
4.5.1.1 Write Data into Register..................................................................................................................54
4.5.1.2 Read Data from Register................................................................................................................ 54
4.5.1.3 Response from the DGUS module............................................................................................... 54
4.5.2 Access Variable SRAM.................................................................................................................................55
4.5.2.1 Write Data into variable SRAM...................................................................................................... 55
4.5.2.2 Read Data from variable SRAM.................................................................................................... 55
4.5.2.3 Response from the DGUS module............................................................................................... 55
4.5.3 Dynamic Trend Curve Display.....................................................................................................................55
4.5.4 Basic Graphic Display...................................................................................................................................56
Beijing DWIN Technology Co., Ltd.
3
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
1. DGUS_SDK Instruction
1.1 Operation of DGUS_SDK
(1) DGUS (DWIN Graphical Utility Software) is an intelligent GUI design software for DWIN DGUS LCM with K600+ kernel. As
be helpful to interface of display design faster than ever, diversified display effects can be achieved easily and rapidly with much less
programming. The variables in use are defined by software DGUS_SDK v5.1 that is accessed by controller via address. All
parameters and images can be downloaded via SD card which stores related .bin files to make your design into real application.
(2) Install DGUS_SDK_V5.1:
Unzip DGUS_SDK_V5.1.zip, and click DGUS ToolV5.1.exe to run it.
(.net Framework 2.0 is required to run the software).
(3) Variable Definition
VP (Variable Pointer): The addresses of variables in variable SRAM (56KB). Users can set buttons with defined VP,
to change the value in this address and display contents corresponding with the value in VP address.
SP (Stack Pointer): the address of definitions, starting address of description data of variables. Change the value in
particular address to modify variable properties. Take function as example.
Data
Add.
Definition
Description
Length
0x00
0x5A03
2
0x02
*SP
2
Stack pointer, default setting is 0xFFFF.
0x04
0x0007
2
The whole process length (in terms of words).
0x06
0x00
*VP
2
Variable pointer.
0x08
0x01
X,Y
4
Top-left coordinate of text, left aligned.
0x0C
0x03
Icon0
2
Icon ID corresponding to 0, the sequence is “0123456789-.”.
0x0E
0x04:H
Icon_Lib
1
Address of icon file.
0x0F
0x04:L
Icon_Mode
1
0x10
0x05:H
Int_Num
1
Length of integer digits.
0x11
0x05:L
Dec_Num
1
Length of decimal digits.
0x12
0x06:H
VP_Data_Mode
1
0x00: integer (2 bytes), 0x01: long integer (4 bytes).
ICON display mode.
0x00: transparent, others: opaque.
E.g.: If SP valued as 0x5000 for WordArt variable, VP parameter will be saved in the ADDRESS of 0x5000. Variable position
parameters will be saved in 0x5001-0x5002
(4) If you need to handle with icons, please drop icon files into Icon Generator to make icon file running in DGUS correctly.
(5) How to select area for buttons & variables.
A. Input coordinates directly.
or
B. Drag the button/variable with mouse.
(6) Define SP address for variables.
Beijing DWIN Technology Co., Ltd.
4
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
SP defines the description of variable settings; to reduce overlap of SP address is necessary. There is overlap judging
embedded, Configuration files won’t be created with failure message when it comes an overlap of SP address.
(7) Import existing DGUS config. files into new project.
A. Create a new project.
B. Add pictures.
C. Import config files.
D. Copy icon files into folder.
Note: Frame header is self-defined by users. In this document, A5 5A is taken as frame header for instance.
1.2 Main Interface of DGUS_SDK_V5.1
a)
Click to activate the window below:
b)
Select resolution and path for your project.
Beijing DWIN Technology Co., Ltd.
5
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
Screen Property Set.
E.g. for:
DMT80480T070_06WT.
Color T: 16bit.
Resolution 80480: 800x480.
Navigation Bar:
New
Create a new project.
Open
Open an existing project (.hmi file).
Save
Save the current project.
Save As
Save the current project in a new folder.
Close
Close the current project.
Variables Preview
Preview buttons & variables
Resolution
Modify resolution of project.
Generating
Modify system configuration and save the settings in config.txt. Refer to illustration
Configuration file
below.
Import Config.
Import existing config. files to the current project.
Export Variables
Generate and for quick view of buttons &
variables.
System Properties
Modify system properties and save the settings in config.txt. Refer to illustration
below
DGUS Configuration File
Download <13Touch_Control_Config.bin>, <14Variable_Config.bin>, and the image;
Download
debug commands via serial port.
Help
Help documents.
Align Left
Align the selected buttons and variables to left.
Align right
Align the selected buttons and variables to right.
Align Top
Align the selected buttons and variables to top.
Align bottom
Align the selected buttons and variables to bottom.
Auto Width
Adjust the selected buttons & variables at same width.
Auto Height
Adjust the selected buttons & variables at same height.
Vertical centered
Adjust the selected buttons & variables at the vertical center.
Horizontal centered
Adjust the selected buttons & variables at the horizontal center.
Copy
(Ctrl + C): copy
Paste
(Ctrl + V): paste
Delete
(delete): delete
Front
Place the button or variable at front layer.
Back
Place the button or variable at backward layer.
SP Address Setting
Set SP for variables.
Variables Preview
Preview buttons & variables
Show Text
show the names of buttons & variables or not.
Reference:Inputted data will be sent via serial port only when both in System Config. Window and settings in buttons properties are ticked.
Beijing DWIN Technology Co., Ltd.
6
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
Tool Bar:
Switching between "Touch Config" & "Variable Config" & Edit Tools using Navigation bar, or shortcut key F2, F3,F4.
2. Basic Steps for DGUS_SDK Operation
2.1 Create a new project
2.1.1 Start a new project
Open the DGUS_SDK_V5.1--------> Click “New Project” button to start a new project.
Beijing DWIN Technology Co., Ltd.
7
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
2.1.2 Select corresponding resolution and save the path
2.1.3 Add images
Images indicating here are what to be displayed as background with “.bmp” format required.
Image naming rules: ID + Name. bmp (name as optional)
For example, “0_Data Input.bmp” or “0.bmp”
Beijing DWIN Technology Co., Ltd.
8
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
2.1.4 Create a CONFIG.TXT file for setting system parameters
Step into setting such system as baud rate, backlight, as well as cycle time etc.
Export Configuration File – “CONFIG. txt”
Beijing DWIN Technology Co., Ltd.
9
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
For the value and functions of each parameters, please refer to the chapter 1.2 of the DGUS Dev. Guide_V5.1—CONFIG. TXT
Beijing DWIN Technology Co., Ltd.
10
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
If the frame header is set as R3=5A RA=A5, please use the software “Serial debugging assistant sscom32 " sending command
below for verifying all images works fine.
5A A5 04 80 03 00 01( 00 01 signify images switching to No1.)
Later, check if images No1 switched successfully. (format must be .bmp naming started from”00”).
There are config.txt failed or com port out of work in the event of images switch failure. Please affirm parameter for config.txt
again including frame header, baud rate etc.
2.2 Configure touch functions
Select the “Touch Config” from pull-down menu-------> Add touch function, as “Data Input” -------> Drag a square on your button
as follow yellow area -------> Set the properties, such as button effect, key value, etc.
Beijing DWIN Technology Co., Ltd.
11
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
2.3 Configure variable display
Select the “Variable Config” from pull-down menu -------> add the display function, as “Data Variable” ------->Drag a blue square
on area, the variable will be displayed based on the upper-right coordinates.--------> Set the properties of variable as font color, font
ID.
Beijing DWIN Technology Co., Ltd.
12
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
2.4 Create configuration files
Click the “Generating Configuration File” button, it will create a touch control configuration file and a variable configuration file.
Their default file names are “13Touch_Control_Config.bin” and” 14Variable_Config.bin “which cannot be renamed, or the project
can’t be opened properly.
Please note that 13&14 bin file must be dropped in corresponding DWIN_SET folder if file downloaded via UART, otherwise
pop-up red warning will show up warning correct file are not found.
Beijing DWIN Technology Co., Ltd.
13
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
2.5 Download
When you completed above steps, it will create a DWIN_SET folder and a project named DWprj.hmi in the path you selected
before.
The DWIN_SET folder includes as follow:
Beijing DWIN Technology Co., Ltd.
14
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
Copy the DWIN_SET folder into the SD card root directory ------> Powered on DGUS LCM------> Insert SD card into the slot of
LCM, the configuration files will be downloaded automatically.
Note: During downloading, don’t turn off the LCM, the screen will blink to blue then back to the first image after completion
3. Main Functions of DGUS_SDK
Touch Config : users can use DGUS_SDK software to add buttons on screen, including Popup Window, Variable Data
Input, Incremental Adjustment, Slider Adjustment, RTC Setting, Touch Control, Return Key Code, and ASCII Input. Buttons are
shown as yellow rectangles in DGUS_SDK_V51. Users can also add press effect for buttons.
Variable Config : users can use DGUS_SDK to add variables on screen, including Variable Icon, Animation Icon, Slider,
WordArt, Image Animation, Icon Rotation, Data Variable, Text Display, RTC Display, Analog Clock Display, Dynamic Trend Curve
Display, Table Display, and Basic Graphic Display, Bit Icon, Timer Variable. Variables are shown as light-blue rectangles in
DGUS_SDK_V51.
Parameter settings: users can use to adjust parameter settings of DGUS module. Parameter with
“0x” in front should be filled with hex numbers.
Beijing DWIN Technology Co., Ltd.
15
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
3.1 Touch Config.
3.1.1 Popup Window
Selected Area: selected button area.
Preview: preview button effect.
Name: name this button for viewing it in .xls (Excel) file.
Data Auto Upload: after pressing the button, key code auto sent to
serial port.
Button Effect: set picture ID for touching effect, -1: null.
VP: variable pointer.
VAR Type:
INT: write key code in VP address (word).
High Byte: write low byte of key code in high byte of VP.
Low Byte: write low byte of key code in low byte of VP.
Bit: write data from last bit of key code into designated bit of VP address.
(0x10 corresponds to VP.0, 0x1F corresponds to VP.F).
Popup Window: set window picture ID and window area.
Image ID: image ID of window picture.
Cut Area: cut area in image ID.
Paste Position: position of window on current screen.
Note: Only buttons will work on popup window.
Illustration of button :
Click button - Window pops up - Select YES/NO.
Beijing DWIN Technology Co., Ltd.
16
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
3.1.2 Variable Data Input
Selected Area: selected button area.
Preview: preview button effect.
Name: name this button for viewing it in .xls file.
Data Auto Upload: after pressing the button, key code auto sent to serial
port.
Button Effect: set picture ID for touching effect, -1: null.
Jump To: switch to a new picture after pressing.
VP: variable pointer.
VAR Type:
INT: integer.
LONGINT: long integer.
High byte: high byte in VP address.
Low byte: low byte in VP address.
Number of INT Bit: length of integer digits.
Number of DEC Bit: length of decimal digits.
Position: data position when typing.
Font Color: data color when typing.
Font ID: address of ASCII font file.
Font Size: horizontal pixel numbers.
Cursor Color: white/black cursor.
Display Mode: masked by (*)/direct display.
Define Keyboard:
Set the keyboard picture ID and the keyboard area.
Image ID: image ID of the keyboard area.
Cut Area: cut area in image ID.
Paste Position: position of the keyboard on current screen.
Enable VAR Input Limitation:
Set limits for inputting numbers.
Notes: Only buttons will work on keyboard: 0x00F1 (Confirm), 0-9 corresponds to 0x0030 - 0x0039, 0x00F0
(Cancel), 0x00F2 (Backspace), 0x002D (+/-), 0x002E (.).
Ignore decimal point while setting range restriction for return value. E.g.: the setting is 3 integer bits and 2 decimal bits, and then
the top limit is 10000, rather than 100.
Inputted data can be displayed by , etc.
Beijing DWIN Technology Co., Ltd.
17
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
Illustration of button :
Click text – Keyboard pops up – Type data – OK.
Click to interrupt input.
3.1.3 Incremental Adjustment
Selected Area: selected button area.
Preview: preview button effect.
Name: name this button for viewing it in .xls file.
Data Auto Upload: after pressing the button, key code auto sent to
serial port.
Button Effect: set picture ID for touching effect, -1: null.
VP: variable pointer.
VAR Type:
0x00: integer.
0x01: high byte in VP address.
0x02: low byte in VP address.
0x10 – 0x1F: adjust value in designated bit of VP address. (0x10
corresponds to VP.0, 0x1F corresponds to VP.F) Step Size must be 0 or 1.
Adjustment Method: ++/--.
Over-limit Operation: stop/ cycle.
Step Size: set step size for +/- buttons.
Min. Value: minimum value for adjustment.
Max. Value: maximum value for adjustment.
Adjusted data can be displayed by , and
etc.
Beijing DWIN Technology Co., Ltd.
18
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
Illustration of button :
Click <+> or <-> to adjust corresponding value.
Hold the button to adjust continually.
3.1.4 Slider Adjustment
Selected Area: selected button area.
Preview: preview button effect.
Name: name this button for viewing it in .xls file.
Data Auto Upload: after pressing the button, key code auto sent to serial
port.
VP: variable pointer.
Value Return Type:
0x00: integer.
0x01: high byte in VP address.
0x02: low byte in VP address.
Direction: horizontal/vertical.
Start Return Value:
The value corresponding to left/top side of slider.
Terminated Value:
The value corresponding to right/bottom side of slider.
This function is only for making touching area for slider. To display it, please
use function.
Adjusted data can be displayed by , etc.
Beijing DWIN Technology Co., Ltd.
19
www.dwin.com.cn
Professional, Creditable, Successful
DGUS_SDK User Guide V5.1
Illustration of button :
Hold the button over 0.5 second and slide the slider to modify number in the right, the value will also be changed.
3.1.5 RTC
Selected Area: selected button area.
Preview: preview button effect.
Name: name this button for viewing it in .xls file.
Data Auto Upload: after pressing the button, key code auto sent to serial
port.
Button Effect: set picture ID for touching effect, -1: null.
Display Position: data position when typing.
Font Color: data color when typing.
Font Lib_ID: address of ASCII font file.
Font Size: horizontal pixel numbers.
Cursor Color: white/black cursor.
Keyboard setting:
Set the keyboard picture ID and the keyboard area.
Image ID: image ID of keyboard area.
Cut Area: cut area in image ID.
Paste Position: position of the keyboard on current screen.
Notes: A keyboard setting is the same as .
Use