This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

MQTT subscribe
#43
I am testing the resident script with 0 sleep interval. It works fine, I receive messages and send messages through tagged grp objects. But let's say I have another function running in a script outside of this resident script.

Code:
function sendToMqtt(message)
-- the code to send something over mqtt on the already established connection --
end

-- script using the function
foo = 1
if foo<2 then
sendToMqtt('less than two')
end

How can I accomplish this without opening a new connection?
Reply


Messages In This Thread
MQTT subscribe - by pentadom - 30.11.2018, 17:39
RE: MQTT subscribe - by admin - 03.12.2018, 08:43
RE: MQTT subscribe - by pentadom - 03.12.2018, 10:18
RE: MQTT subscribe - by Dario - 04.02.2020, 12:10
RE: MQTT subscribe - by admin - 04.02.2020, 12:40
RE: MQTT subscribe - by Dario - 04.02.2020, 16:39
RE: MQTT subscribe - by Tifon - 08.03.2020, 09:33
RE: MQTT subscribe - by admin - 09.03.2020, 08:46
RE: MQTT subscribe - by admin - 19.02.2021, 12:10
RE: MQTT subscribe - by admin - 22.02.2021, 07:24
RE: MQTT subscribe - by admin - 22.02.2021, 08:10
RE: MQTT subscribe - by myg - 25.02.2021, 09:35
RE: MQTT subscribe - by admin - 26.02.2021, 11:59
RE: MQTT subscribe - by admin - 19.03.2021, 09:33
RE: MQTT subscribe - by a455115 - 12.12.2022, 14:05
RE: MQTT subscribe - by admin - 12.12.2022, 16:00
RE: MQTT subscribe - by a455115 - 13.12.2022, 07:23
RE: MQTT subscribe - by admin - 13.12.2022, 08:48
RE: MQTT subscribe - by a455115 - 14.12.2022, 07:09
RE: MQTT subscribe - by admin - 14.12.2022, 08:10
RE: MQTT subscribe - by a455115 - 14.12.2022, 10:05
RE: MQTT subscribe - by admin - 14.12.2022, 12:49
RE: MQTT subscribe - by a455115 - 14.12.2022, 15:04
RE: MQTT subscribe - by admin - 15.12.2022, 08:40
RE: MQTT subscribe - by tomnord - 18.01.2024, 13:16
RE: MQTT subscribe - by admin - 18.01.2024, 13:38
RE: MQTT subscribe - by tomnord - 18.01.2024, 13:51
RE: MQTT subscribe - by tomnord - 23.01.2024, 08:08
RE: MQTT subscribe - by Daniel - 23.01.2024, 08:09
RE: MQTT subscribe - by tomnord - 23.01.2024, 11:01
RE: MQTT subscribe - by Daniel - 23.01.2024, 11:16
RE: MQTT subscribe - by tomnord - 23.01.2024, 12:08
RE: MQTT subscribe - by Daniel - 23.01.2024, 12:41
RE: MQTT subscribe - by FatMax - 31.01.2024, 08:49
RE: MQTT subscribe - by Daniel - 31.01.2024, 09:28
RE: MQTT subscribe - by FatMax - 31.01.2024, 12:49
RE: MQTT subscribe - by admin - 31.01.2024, 12:52
RE: MQTT subscribe - by FatMax - 31.01.2024, 12:59
RE: MQTT subscribe - by admin - 31.01.2024, 13:01
RE: MQTT subscribe - by FatMax - 31.01.2024, 13:18
RE: MQTT subscribe - by admin - 31.01.2024, 13:23
RE: MQTT subscribe - by FatMax - 31.01.2024, 13:31
RE: MQTT subscribe - by admin - 31.01.2024, 13:53

Forum Jump: