projects
/
weathermon.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
1) Переход на доставку без гарантии (старые данные копить нет смысла)
[weathermon.git]
/
bin
/
weathermon
diff --git
a/bin/weathermon
b/bin/weathermon
index d16f871c18671c0d0e3bcb8e573889463132cdaf..cc58def4232fd28424b8699c89b7e8a2c24d3629 100755
(executable)
--- a/
bin/weathermon
+++ b/
bin/weathermon
@@
-186,7
+186,10
@@
function processJson(str)
return '{'..name..'}'
end
end)
return '{'..name..'}'
end
end)
- mqtt_client:publish(mqtt_path,v)
+ if not mqtt_client:socket() then
+ mqtt_client:reconnect()
+ end
+ mqtt_client:publish(mqtt_path,v,0,0)
mqtt_client:loop()
end
end
mqtt_client:loop()
end
end
@@
-249,7
+252,7
@@
function processLine(str)
return '{'..name..'}'
end
end)
return '{'..name..'}'
end
end)
- mqtt_client:publish(mqtt_path,v)
+ mqtt_client:publish(mqtt_path,v
,0,0
)
mqtt_client:loop()
end
end
mqtt_client:loop()
end
end
@@
-290,7
+293,7
@@
function processLine(str)
return '{'..name..'}'
end
end)
return '{'..name..'}'
end
end)
- mqtt_client:publish(mqtt_path,msg_body)
+ mqtt_client:publish(mqtt_path,msg_body
,0,0
)
mqtt_client:loop()
end
if alarm_exec then
mqtt_client:loop()
end
if alarm_exec then