O'Reilly logo

Internet of Things with Python by Gastón C. Hillar

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Publishing messages to a Mosquitto broker with a Python client

We have the code that is going to be running in the Intel Galileo Gen 2 board to process the command messages received from the Mosquitto message broker. Now, we are going to code a Python client that will publish messages to the "iot-python-gaston-hillar/temperature" channel. This way, we will be able to design applications that can talk to IoT devices with MQTT messages. Specifically, the applications will be able to communicate through a Mosquitto message broker with Python code in the publisher and in the subscriber devices.

We can run the Python client on another Intel Galileo Gen 2 board or in any device that has Python 2.7.x installed. In addition, the code will run with Python ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required