ramb
Hi,
I need some help connecting to a public MQTT broker. If you provided some hints into the right direction, I'd greatly appreciate it.
 
This is my setup, when I simulate it, the variable mqtt_connected stays FALSE forever.
[203128%2F8716515%2Fmceclip0]
 
FYI:
This is on macOS 14.4.1, Apple Silicon, OpenPLC Editor 3.0 Release 2024-01-25.
 
EDIT:
The built-in example "MQTT_send" also doesn't work. MQTT Explorer, for example, is able to connect just fine.
 
EDIT 2:
Just updated Editor to Release 2024-04-03: Still same behavior.
thiagoralves
You need to run this on a hardware board. It won't run on simulation.
Reply 0 0
ramb
Gotcha, I didn't know that it wouldn't run in a sim. Thanks and solved
Btw: Which Protocols does the MQTT clietn support? Is this only the MQTT (TCP) protocol or does it also support e. g. ws / wss ?
Reply 0 0
thiagoralves
By the way, update your editor. You’ll get more stability on the live debugger for the hardware boards and a new MQTT example project on the file->examples menu
Reply 1 0
soura
You need to run this on a hardware board. It won't run on simulation.
Hi @ThiagoAlves, would we be able to use the OpenPLC runtime to execute the MQTT_SEND function on a Raspberry Pi?
Reply 0 0
thiagoralves
Reply 1 0
Reply