* add HomeKit humidifier/dehumidifier * added more test coverage * simplified char logic Co-authored-by: Quentame <polletquentin74@me.com> * use mode constants * Renamed HomeKit Contorller Co-authored-by: Quentame <polletquentin74@me.com> * improved threshold logic * split up homekit humidifier into 2 entities * fixed tests * fixed mode and switch logic * added set mode tests * removed redundant methods present in base class Co-authored-by: Quentame <polletquentin74@me.com>
42 lines
1.2 KiB
Python
42 lines
1.2 KiB
Python
"""Constants for the homekit_controller component."""
|
|
DOMAIN = "homekit_controller"
|
|
|
|
KNOWN_DEVICES = f"{DOMAIN}-devices"
|
|
CONTROLLER = f"{DOMAIN}-controller"
|
|
ENTITY_MAP = f"{DOMAIN}-entity-map"
|
|
TRIGGERS = f"{DOMAIN}-triggers"
|
|
|
|
HOMEKIT_DIR = ".homekit"
|
|
PAIRING_FILE = "pairing.json"
|
|
|
|
# Mapping from Homekit type to component.
|
|
HOMEKIT_ACCESSORY_DISPATCH = {
|
|
"lightbulb": "light",
|
|
"outlet": "switch",
|
|
"switch": "switch",
|
|
"thermostat": "climate",
|
|
"heater-cooler": "climate",
|
|
"security-system": "alarm_control_panel",
|
|
"garage-door-opener": "cover",
|
|
"window": "cover",
|
|
"window-covering": "cover",
|
|
"lock-mechanism": "lock",
|
|
"contact": "binary_sensor",
|
|
"motion": "binary_sensor",
|
|
"carbon-dioxide": "sensor",
|
|
"humidity": "sensor",
|
|
"humidifier-dehumidifier": "humidifier",
|
|
"light": "sensor",
|
|
"temperature": "sensor",
|
|
"battery": "sensor",
|
|
"smoke": "binary_sensor",
|
|
"carbon-monoxide": "binary_sensor",
|
|
"leak": "binary_sensor",
|
|
"fan": "fan",
|
|
"fanv2": "fan",
|
|
"air-quality": "air_quality",
|
|
"occupancy": "binary_sensor",
|
|
"television": "media_player",
|
|
"valve": "switch",
|
|
"camera-rtp-stream-management": "camera",
|
|
}
|