diff --git a/TC1/http_server/web_log.h b/TC1/http_server/web_log.h index ecd8132..3e6eada 100644 --- a/TC1/http_server/web_log.h +++ b/TC1/http_server/web_log.h @@ -24,6 +24,7 @@ char* GetLogRecord(); #define web_log(format, ...) \ LOG_TMP = (char*)malloc(sizeof(char)*LOG_LEN); \ now = time(NULL); \ + now += 28800; \ strftime(time_buf, TIM_LEN, "[%Y-%m-%d %H:%M:%S]", localtime(&now)); \ snprintf(LOG_TMP, LOG_LEN, "%s"format, time_buf, ##__VA_ARGS__); \ SetLogRecord(&log_record, LOG_TMP); \ diff --git a/TC1/main.h b/TC1/main.h index 7ba600b..6d0aa0c 100644 --- a/TC1/main.h +++ b/TC1/main.h @@ -4,7 +4,7 @@ #include "mico.h" #include "micokit_ext.h" -#define VERSION "v0.11.0" +#define VERSION "v0.11.1" #define TYPE 1 #define TYPE_NAME "zTC1" diff --git a/TC1/timed_task/timed_task.c b/TC1/timed_task/timed_task.c index 8fd7451..c709905 100644 --- a/TC1/timed_task/timed_task.c +++ b/TC1/timed_task/timed_task.c @@ -103,7 +103,8 @@ char* GetTaskStr() { char buffer[26]; struct tm* tm_info; - tm_info = localtime(&tmp_tsk->prs_time); + time_t prs_time = tmp_tsk->prs_time + 28800; + tm_info = localtime(&prs_time); strftime(buffer, 26, "%Y-%m-%d %H:%M:%S", tm_info); sprintf(tmp_str, "{'prs_time':'%s','socket_idx':%d,'on':%d},",