Allow MagiQuest Wands to call into HomeAssistant Webhooks
Project description
homeassistant-magiwand
This code can be used to connect MagiQuest IR wands to an instance of HomeAssistant. This extends a related project of mine, pywand [source] [PyPI]
This project ships with a script that will monitor a lirc device, and trigger HomeAssistant Automations via web api call. Currently, the scope is pretty narrow, but I hope to expand it over time to meet my needs.
Installation, Setup, and Config
tldr:
- Enable your infrared device
- Install python3
pip install homeassistant-magiwand
- Enable a Ling-Lived Access Token in HomeAssistant
- Enable api and add an Automation to run in HomeAssistant
- Edit
/etc/wand_config.ini
- Run
ha_wand_service.py
More Details
- pywand: Installation and Pre-Reqs
- pywand: Configuration
- Enable the REST API for HomeAssistant: HomeAssistant: REST API
- Create an Automation for our sensor. This is what will be triggered when the wand is waved. HomeAssistant: Automation
- Create a Long-Lived Access Token within your HomeAssistant Instance.
- Continue configuring the wand configuration file with the HOMEASSISTANT section. See example_wand_config.ini for more information.
- Execute the service by running
ha_wand_service.py
Running the service
Just make sure the config file is right, see previous sections
Usage
ha_wand_service.py -h
usage: ha_wand_service.py [-h] [--loglevel LOGLEVEL]
optional arguments:
-h, --help show this help message and exit
--loglevel LOGLEVEL Loglevel: CRITICAL, ERROR, WARNING (default), INFO,
DEBUG
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file homeassistant-magiwand-0.1.1.tar.gz
.
File metadata
- Download URL: homeassistant-magiwand-0.1.1.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.8.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cb5522edf1370e8c4f44ebd1076c20af3b82eca2043f0aa81b143e4553a9c926 |
|
MD5 | 8ea7fb8a10fccd20442e70464fe458b0 |
|
BLAKE2b-256 | 66a180e9c2aa52a00ef7ad1312da0d71cd3cd851064ecd76191829a6abee5501 |