//#include "sys.h" //#include "usart.h" #include <string.h> #include "dianchuan.h" #include "app4g.h" #include "project_config.h" #include "cjson_middleware.h" DianChuan_Frame DianChuanTxFrame = {0}; DianChuan_Frame DianChuanRxFrame = {0}; /* SOP LEN CMD SESSION_ID DATA SUM 1Byte 1Byte 1Byte 6Bytes n 1Byte */ void DianChuan_ConstructTxCmdFrame(DianChuan_Frame *frame,u8 cmd,u8 *session_id,u8 *data,u8 datalen) { u8 i =0; if(frame == NULL) { return; } else memset(frame,0,sizeof(DianChuan_Frame)); frame->sop = DIANCHUAN_TX_SOP; frame->len = 0; frame->cmd = cmd; frame->len ; frame->sum = cmd; if(s