Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/artbit/jasper-module-mqtt
Jasper MQTT client module for my HAL9000 Raspberry PI project
https://github.com/artbit/jasper-module-mqtt
jasper jasper-module jasper-modules mqtt mqtt-client
Last synced: 3 months ago
JSON representation
Jasper MQTT client module for my HAL9000 Raspberry PI project
- Host: GitHub
- URL: https://github.com/artbit/jasper-module-mqtt
- Owner: ArtBIT
- License: mit
- Created: 2016-06-18T18:18:43.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-07-22T13:58:01.000Z (over 1 year ago)
- Last Synced: 2024-08-01T12:19:31.085Z (5 months ago)
- Topics: jasper, jasper-module, jasper-modules, mqtt, mqtt-client
- Language: Python
- Homepage:
- Size: 3.91 KB
- Stars: 11
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Jasper-Module-MQTT
Jasper MQTT Module for my [HAL9000 Raspberry PI Instructable](http://www.instructables.com/id/RaspberryPI-HAL9000/)
When triggered it publishes a simple MQTT event using the following topic:
```
hal9000/*device*/*index*
```
Available devices:
* device
* room
* light
* sensor
* doorAvailable indexes:
* one
* two
* three
* ...
* tenAvailable topic messages:
* on
* off
* true
* false
* open
* close## Steps to install MQTT Module
* Install the python Mosquitto package:
```
sudo pip install paho-mqtt
```
* run the following commands in order:
```
git clone https://github.com/ArtBIT/jasper-module-mqtt.git
cp jasper-module-mqtt/Mqtt.py
#i.e. cp jasper-module-mqtt/Mqtt.py /usr/local/lib/jasper/client/modules/
```
* Edit `~/.jasper/profile.yml` and add the follwing at the bottom:
```
mqtt:
hostname: 'your.mqtt.broker.hostname.or.ip'
port: 1883
protocol: 'MQTTv31' # Note: this should be either MQTTv31 or MQTTv311, I had problems with Ubuntu broker and MQTTv311
```
* Restart the Pi:
```
sudo reboot
```
## Congrats, JASPER MQTT Module is now installed and ready for use.
Here are some examples:
```
YOU: Light one off
JASPER: *publishes an mqtt event* topic:hal9000/light/one message:off
YOU: Door two close
JASPER: *publishes an mqtt event* topic:hal9000/door/two message:close
```