SmartGPU2-LCD480X320Touch-CommandSet

SMART GPU 2 3.5” TOUCH
Command Set
Vizic Technologies ©2014 111
2.9.14 Erase Dir/File 45hex ‘E’ ascii
Commands (host)
3 bytes + Dir or File name with “.ext” +
1byte(NULL).
1.- 0x46 (hex), F (ascii). *FAT command.
2.- 0x45 (hex), E (ascii). (Erase Dir/File)
3.- 0x4F Security un-lock byte.
3 up to N (Dir/File name including extension).
N+1.- 0x00 (hex) NULL ascii.
Responses (device)
1 byte File ACK + 1 byte Command ACK
1.- 0xXX (hex) - Refer to “File ACK List”.
2.- 0x4F (hex), O (ascii) success ACK.
0x46 (hex), F (ascii) fail NAK.
Description
This Command Erases/Deletes an existing
Directory or File from the microSD card current
directory path. The Security un-lock byte, it’s a
simple security byte that avoids unwanted delete
operations.
When deleting a Directory, it must be empty or
command will fail.
When deleting a File, it must be closed and not
allocated under any Workspace block to avoid
any data corruption.
If Directory or File to erase doesn’t exist during
an Erase Dir/File command, this will fail with
INVALID NAME.
Example (sent commands)
Example 1:
<46,45,4F,30,31,32,33,2E,74,78,74,00> Erase
File “0123.txt”.
Example 2:
<46,45,4F,41,42,43,2E,77,78,6C,00> Erase File
“ABC.wxl”.
Example 3:
<46,45,4F,72,6F,63,6B,00> Erase the Dir “rock”.
All data is in hex.