mirror of
https://gitee.com/dgiiot/dgiot.git
synced 2024-12-05 05:37:40 +08:00
fix: modbus_rtu format_value
This commit is contained in:
parent
38e189d9f9
commit
3b063d34c8
@ -553,7 +553,7 @@ format_value(Buff, #{<<"dataForm">> := #{
|
||||
}}) ->
|
||||
IntLen = dgiot_utils:to_int(Len),
|
||||
Size = max(2, IntLen) * 8,
|
||||
<<Value:Size, Rest/binary>> = Buff,
|
||||
<<Value:Size/binary, Rest/binary>> = Buff,
|
||||
{Value, Rest};
|
||||
|
||||
format_value(Buff, #{<<"dataForm">> := #{
|
||||
|
@ -128,6 +128,7 @@ stop(#{
|
||||
dgiot_cron:save(default_task, #{
|
||||
<<"id">> => <<"task/", Channel/binary, "/", DtuId/binary>>,
|
||||
<<"count">> => 0}),
|
||||
del_pnque(DtuId),
|
||||
dgiot_task_worker:stop(#{<<"channel">> => Channel, <<"dtuid">> => DtuId})
|
||||
end, Page)
|
||||
end,
|
||||
@ -153,6 +154,7 @@ stop(#{
|
||||
dgiot_cron:save(default_task, #{
|
||||
<<"id">> => <<"task/", Channel/binary, "/", DtuId/binary>>,
|
||||
<<"count">> => 0}),
|
||||
del_pnque(DtuId),
|
||||
dgiot_task_worker:stop(#{<<"channel">> => Channel, <<"dtuid">> => DtuId})
|
||||
end, Page)
|
||||
end,
|
||||
|
Loading…
Reference in New Issue
Block a user