From dcd780ba5dc2e5d4239204309eb3953f7bd27b50 Mon Sep 17 00:00:00 2001 From: anlicheng <244108715@qq.com> Date: Mon, 16 Dec 2024 19:55:04 +0800 Subject: [PATCH] fix donghuoliren config --- apps/iot/src/iot_device.erl | 5 ++++- config/sys-dev.config | 4 ++-- config/sys-prod.config | 4 ++-- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/apps/iot/src/iot_device.erl b/apps/iot/src/iot_device.erl index 370a7bf..da8234d 100644 --- a/apps/iot/src/iot_device.erl +++ b/apps/iot/src/iot_device.erl @@ -261,7 +261,10 @@ handle_cast({ai_event, EventType, Params}, State = #state{device_uuid = DeviceUU Timestamp = iot_util:current_time(), case Timestamp >= LastTimestamp + Interval of true -> - iot_ai_router:route_uuid(DeviceUUID, EventType, Params), + %% todo + lager:debug("[iot_device] device_uuid: ~p, ai_event triggered last_timestamp: ~p, current_timestamp: ~p", + [DeviceUUID, LastTimestamp, Timestamp]), + % iot_ai_router:route_uuid(DeviceUUID, EventType, Params), {noreply, State#state{ai_event_ttl = maps:put(EventType, Timestamp, EventTTL)}}; false -> lager:debug("[iot_device] device_uuid: ~p, ai_event trigger less than interval: ~p, last_timestamp: ~p, current_timestamp: ~p", diff --git a/config/sys-dev.config b/config/sys-dev.config index 374c090..d76c4b8 100644 --- a/config/sys-dev.config +++ b/config/sys-dev.config @@ -91,8 +91,8 @@ {url, "https://xsdc.njau.edu.cn/hq-cyaqjg/rest/rgkSmart/push"}, {token, <<"aB3$dEfGhiJkLmNoPqRsTuVwXyZ!@#4f5e6d7c8b9a0f1e2d">>}, {locations, [ - {"32981253076969472017320929999562", "诚苑餐厅一楼1F"}, - {"32981271601113088017320930441218", "诚苑餐厅一楼1F"} + {"0516103021011022700001", "诚苑餐厅一楼1F"}, + {"0516103021011022700002", "诚苑餐厅一楼1F"} ]} ]}, diff --git a/config/sys-prod.config b/config/sys-prod.config index 1b33417..c5fdb6c 100644 --- a/config/sys-prod.config +++ b/config/sys-prod.config @@ -68,8 +68,8 @@ {url, "https://xsdc.njau.edu.cn/hq-cyaqjg/rest/rgkSmart/push"}, {token, <<"aB3$dEfGhiJkLmNoPqRsTuVwXyZ!@#4f5e6d7c8b9a0f1e2d">>}, {locations, [ - {"32981253076969472017320929999562", "诚苑餐厅一楼1F"}, - {"32981271601113088017320930441218", "诚苑餐厅一楼1F"} + {"0516103021011022700001", "诚苑餐厅一楼1F"}, + {"0516103021011022700002", "诚苑餐厅一楼1F"} ]} ]},