Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 1587

Python • Re: MQTT on Raspberry Pi 3B+ - Subscribe two different topics with Python

$
0
0
Is it possible that two simple MQTT subscribing Python scripts could not run along without blocking each other?
There should be no blocking.
As you did not post your code, some general remarks
- follow the examples, see https://pypi.org/project/paho-mqtt/#getting-started note the mqttc.loop_forever()
- perhaps there is a problem with the influx database connection. For a test, bypass the database access and check if you still see delay.
- perhaps set a distinct client_id in mqtt.Client() constructor in each of the programs.

Statistics: Posted by ghp — Mon Jun 02, 2025 4:49 pm



Viewing all articles
Browse latest Browse all 1587

Trending Articles