暫無描述

Fabian Peter Hammerle 3e436f7e3e docker: multi-stage build to reduce target image size 4 年之前
.github cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
switchbot_mqtt 701ec81f1f validate mac address 4 年之前
.dockerignore cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
.gitignore cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
.pylintrc cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
COPYING cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
Dockerfile 3e436f7e3e docker: multi-stage build to reduce target image size 4 年之前
Pipfile cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
Pipfile.lock cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
README.md 094cd7a394 readme: added home assistant config snippet 4 年之前
mypy.ini cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前
setup.py cb2596d32e standard python project tech stack (pipenv, pytest, pylint etc.); mqtt connect; GPLv3+ 4 年之前

README.md

Use sudo hcitool lescan or select device settings > 3 dots on top right in SwitchBot app to determine the mac address.

Home Assistant 🏡

# https://www.home-assistant.io/docs/mqtt/broker/#configuration-variables
mqtt:
  broker: BROKER_HOSTNAME_OR_IP_ADDRESS
  # credentials, additional options...

# https://www.home-assistant.io/integrations/switch.mqtt/#configuration-variables
switch:
- platform: mqtt
  name: some_name
  command_topic: homeassistant/switch/switchbot/aa:bb:cc:dd:ee:ff/set
  # http://materialdesignicons.com/
  icon: mdi:light-switch

Docker

$ docker build -t switchbot-mqtt .
$ docker run --name spelunca_switchbot \
    --userns host --network host \
    switchbot-mqtt:latest \
    switchbot-mqtt --help

Alternatives