|
Hi, I'm trying to change my page to another one by the serial command,
and tried a few ways to change my page
Before asking about my trouble, as far as I know, I think 'page' is the number of 'location' value on DGUS2,
is it correct ? I need to change my location 0 to another like 1, 2, 3....
First trial was announced at the document, T5L_DGUSII-Application-Development-Guide-V2.5.pdf.
5.1 System Variable Interface
System variable address range: 0x0000-0x0FFF.
0x84 PIC_Set R/W 2
D3: 0x5A = enable page operation once, The CPU is clearedafter
processing. D2: Processing Mode. 0x01=page switch (Display the image specified in the image storageareatothe current background page). 0x02=This mode is reserved and not supported.
Instruction example:
5A A5 07 82 0084 5A01 0001, display the 01 serial number pictureunderthe background picture ICL file (if the serial number pictureIDof thesentinstruction does not exist, the instruction operation judgment will not takeeffect.)
I tried to send : 5A A5 07 82 0084 5A01 0001
And nothing changed in my screen. It's still on the 0 page. '0002' and '0003' also are no way..
So, I tried to find another way and found a library.
https://github.com/dwinhmi/DWIN_DGUS_HMI/blob/master/src/DWIN.cpp
// Change Page
- void DWIN::setPage(byte page){
- //5A A5 07 82 00 84 5a 01 00 02
- byte sendBuffer[] = {CMD_HEAD1, CMD_HEAD2, 0x07, CMD_WRITE, 0x00, 0x84, 0x5A, 0x01, 0x00, page};
- _dwinSerial->write(sendBuffer, sizeof(sendBuffer));
- readDWIN();
- }
复制代码 It's same one with the document. So I guess above my first trial should be work as expected even it's failed..
But, I found another method on Youtube.
DWIN K600+ Tutorial: Directly change page or via command---from DWIN Technology
https://youtu.be/zGT8GTcvjLs?t=70
5a a5 04 80 03 0001
I tried to send "5a a5 04 80 03 0001" but nothing changed in this time too.
Could you let me know how to change my page to another ?
|
|