I have been using version Moquitto v 1.5.7 and ESP32 software based on Module 7.
Now I have installed Moquitto on another RP and it is now v 2.0.11. I can´t get in contact with the broker now. Should I do something else.
Best Regards Håkan
Here are the instructions to make it work.
1) Open an SSH connection with your Raspberry Pi and run the following command:
sudo nano /etc/mosquitto/mosquitto.conf
2) It will open the mosquitto.conf file. Move to the end of the file using the arrow keys and paste the following two lines:
3) Then, press CTRL-X to exit and save the file. Press Y and Enter.
4) Reboot your Raspberry Pi with the following command:
5) Close putty and open again after a few seconds to run the mosquito broker again.
This time, the ESP should connect to the broker.
Can you tell me the exact step in which you have issues with that version? What happens exactly?
When I install Moquitto according to your instructions I now will get version 2. I have read that this version is not recommended for beginners.
When I try to publish a topic I´m not getting an acknowledgement and I can´t read the topic at the receiver.
Is it possible to change the install routine to get Mosquitto version 1.5 or 1.6 or could I change the publish and subscribe routines?
I haven’t tried the new Mosquitto version.
But, in theory, it should work.
When you say you “can’t read the topic at the receiver”, what happens exactly?
I have seen that Mosquitto 2.0 needs some additional configurations to work: https://mosquitto.org/documentation/migrating-to-2-0/
I’ll try it and see if I get it working.