添加开机通知配置项 config.BOOT_NOTIFY

This commit is contained in:
Mizore 2023-01-16 19:39:50 +08:00
parent c8dc8d3c13
commit 7d0fa89224
2 changed files with 7 additions and 2 deletions

View File

@ -38,5 +38,8 @@ return {
QUERY_TRAFFIC_INTERVAL = 1000 * 60 * 60 * 6, QUERY_TRAFFIC_INTERVAL = 1000 * 60 * 60 * 6,
-- --
-- 定时基站定位间隔, 单位毫秒, 设置为 0 关闭 -- 定时基站定位间隔, 单位毫秒, 设置为 0 关闭
LOCATION_INTERVAL = 1000 * 60 * 30 LOCATION_INTERVAL = 1000 * 60 * 30,
--
-- 开机通知
BOOT_NOTIFY = true,
} }

View File

@ -82,7 +82,9 @@ sys.taskInit(
sys.waitUntil("COORD_INIT_DONE", 1000 * 20) sys.waitUntil("COORD_INIT_DONE", 1000 * 20)
-- 开机通知 -- 开机通知
util_notify.send("#BOOT") if config.BOOT_NOTIFY then
util_notify.send("#BOOT")
end
-- 定时查询流量 -- 定时查询流量
if config.QUERY_TRAFFIC_INTERVAL and config.QUERY_TRAFFIC_INTERVAL >= 1000 * 60 then if config.QUERY_TRAFFIC_INTERVAL and config.QUERY_TRAFFIC_INTERVAL >= 1000 * 60 then