系统时间接口
More...
Go to the source code of this file.
|
|
#define | SYS_TIME_NTP_SERVER_KEY1 "ro.time.ntp1" |
|
#define | SYS_TIME_NTP_SERVER_KEY2 "ro.time.ntp2" |
|
#define | SYS_TIME_NTP_SERVER_KEY3 "ro.time.ntp3" |
|
#define | SYS_TIME_NTP_SERVER_DFT_VAL1 "ntp.shu.edu.cn" |
|
#define | SYS_TIME_NTP_SERVER_DFT_VAL2 "ntp1.aliyun.com" |
|
#define | SYS_TIME_NTP_SERVER_DFT_VAL3 "ntp2.aliyun.com" |
|
#define | SYS_TIME_NTP_SERVER_ID_1 "ntp1" |
|
#define | SYS_TIME_NTP_SERVER_ID_2 "ntp2" |
|
#define | SYS_TIME_NTP_SERVER_ID_3 "ntp3" |
|
#define | SYS_TIME_ZONE_KEY "ro.time.timezone" |
|
#define | SYS_TIME_ZONE_DEFAULT "+08:00" /* 默认时区:东八区 */ |
|
#define | SYS_TIME_ZONE_LEN 16 /* 时区字符串长度,如 "+08:00" */ |
|
|
typedef void(* | sys_time_cb_t) (tbox_time_info_t *time_info_t, sys_time_calc_type_t type) |
|
| enum | sys_time_calc_type_t { SYS_TIME_TYPE_MCU_CALC
, SYS_TIME_TYPE_GPS_CALC
, SYS_TIME_TYPE_NTP_CALC
, SYS_TIME_TYPE_TSP_CALC
} |
系统时间接口
- Version
- 1.0.0
- Date
- 2026-07-03
- Copyright
- Copyright © 2026 Shenzhen One IOT World Co., Ltd. All rights reserved.
◆ sys_time_mcu_rtc()
| void sys_time_mcu_rtc |
( |
const uint8_t * | data, |
|
|
uint32_t | len ) |
◆ sys_time_set_by_tsp()
| void sys_time_set_by_tsp |
( |
time_t | ts | ) |
|