add comment

This commit is contained in:
Cloud Wu
2017-03-25 15:05:39 +08:00
parent 6289b2b8e4
commit 570a8356e6

View File

@@ -38,6 +38,8 @@ fill_header(lua_State *L, uint8_t *buf, int sz) {
/* /*
The request package : The request package :
first WORD is size of the package with big-endian
DWORD in content is small-endian
size <= 0x8000 (32K) and address is id size <= 0x8000 (32K) and address is id
WORD sz+9 WORD sz+9
BYTE 0 BYTE 0
@@ -45,7 +47,7 @@ fill_header(lua_State *L, uint8_t *buf, int sz) {
DWORD session DWORD session
PADDING msg(sz) PADDING msg(sz)
size > 0x8000 and address is id size > 0x8000 and address is id
DWORD 13 WORD 13
BYTE 1 ; multireq , 0x41: multi push BYTE 1 ; multireq , 0x41: multi push
DWORD addr DWORD addr
DWORD session DWORD session
@@ -59,7 +61,7 @@ fill_header(lua_State *L, uint8_t *buf, int sz) {
DWORD session DWORD session
PADDING msg(sz) PADDING msg(sz)
size > 0x8000 and address is string size > 0x8000 and address is string
DWORD 10 + namelen WORD 10 + namelen
BYTE 0x81 ; 0xc1 : multi push BYTE 0x81 ; 0xc1 : multi push
BYTE namelen BYTE namelen
STRING name STRING name
@@ -335,6 +337,8 @@ lunpackrequest(lua_State *L) {
} }
/* /*
The response package :
WORD size (big endian)
DWORD session DWORD session
BYTE type BYTE type
0: error 0: error