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 how to get started
#1
Hi there,

It's my first time using MQTT and I am a bit lost. I want to connect 2 LM and share group addresses between them, but after reading more and more posts about that, I have achieved nothing.

Steps that I followed:

- I have installed and configured MQTT broker app in one of my LMs;
- I have created a resident script and group addresses as showed here: https://forum.logicmachine.net/showthrea...6#pid10926 , pointing to localhost where the broker is, and to the broker IPs at the other;
- I have installed MQTT Explorer in my PC to monitoring everything;
- I'm stuck at this step, because I don't see anything at MQTT Explorer and I don't know what to do appart of changing group address values.

Can anybody help me or share a tutorial?

Thanks in advance!
Reply
#2
Does the objects in your script exists? Any errors?
On the client LM with broker in use ip 127.0.0.1
------------------------------
Ctrl+F5
Reply
#3
(27.04.2023, 08:17)Daniel Wrote: Does the objects in your script exists? Any errors?
On the client LM with broker in use ip 127.0.0.1

Yes, I have created the same objects included in the script just to avoid any bug on my side (indeed I have tried with different data types as I don't know if that is relevant). 

The LM log shows "* arg: 1  * string: mqtt connect status * arg: 2  * bool: true * arg: 3  * number: 0 * arg: 4  * string: connection accepted * arg: 5  * number: 0 * arg: 6  * nil".

And yes, on the client with the installed broker I use the localhost IP.
Reply
#4
Post your full script.
Reply
#5
I do not know why, but, while I was taking the screenshots to post them for you, everything started to work flawlessly  Huh .
Anyway, if anybody needs some help about this topic, just use this post.

Thank you admins!
Reply


Forum Jump: