Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

simple python example using paho #2

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

simple python example using paho #2

wants to merge 2 commits into from

Conversation

jcockhren
Copy link

No description provided.

@jcockhren
Copy link
Author

@jameswhite

@jameswhite
Copy link

root@planck:/var/cache/git/standing-water# pip install paho
Downloading/unpacking paho
  Could not find any downloads that satisfy the requirement paho
Cleaning up...
No distributions at all found for paho
Storing debug log for failure in /root/.pip/pip.log

@jameswhite
Copy link

pip install paho-mqtt works d'oh!


MQTT_HOST = 'localhost'

client.tls_set('/etc/ssl/private/ca.crt',

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by convention, the ca cert is in /etc/ssl/certs/ not /etc/ssl/private

@jameswhite
Copy link

@jcockhren it seems to be connecting but not publishing or subscribing. Just connects then exits.

I think it needs a client.loop_forever() e.g. https://eclipse.org/paho/clients/python/

@jcockhren
Copy link
Author

@jameswhite that's honestly something I was wondering if it'll be ok to leverage given it's blocking. I'll correct the things.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants