mqtt-launcher | Execute shell commands triggered by published MQTT messages | Automation library
kandi X-RAY | mqtt-launcher Summary
kandi X-RAY | mqtt-launcher Summary
Execute shell commands triggered by published MQTT messages
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Process a message
- Run a command on a topic
- Get a value from the configuration
mqtt-launcher Key Features
mqtt-launcher Examples and Code Snippets
Community Discussions
Trending Discussions on mqtt-launcher
QUESTION
I'm using mqtt-launcher (https://github.com/jpmens/mqtt-launcher) to execute commands when a certain MQTT message with the payload "0" was received.
Here is the config
...ANSWER
Answered 2018-Dec-16 at 20:32You have published a message with the payload 0
and the retained bit set.
This means that when ever a client subscribes to that topic the last message with the retained bit set will be delivered to that client.
You can clear the retained message by publishing a message with the retained bit set and a null payload to the same topic. You can do this with the mosquitto_pub command as follows:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install mqtt-launcher
You can use mqtt-launcher like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page