Skip to content
Nuno Santos edited this page Nov 10, 2023 · 17 revisions

We fully support Homebridge via MQTT-Thing for Apple HomeKit integration, since the release of 1.1.0.

Requirements

  • MQTT Broker (Mosquitto or other compatible)

PAI Configuration

In /etc/pai/pai.conf you'll need:

  1. MQTT enabled and configured (MQTT_ENABLE = True)
  2. Uncomment the MQTT_COMMAND_ALIAS section.
MQTT_COMMAND_ALIAS = {
    # For homebridge
    'armed_home': 'arm_stay',
    'armed_night': 'arm_sleep',
    'armed_away': 'arm',
    'disarmed': 'disarm'
}

Homebridge configuration

  1. Install MQTT-Thing.
  2. In Homebridge's config.json file, or through Homebridge's Config Editor, add the following accessory:
{
            "accessory": "mqttthing",
            "type": "securitySystem",
            "name": "Pick a name",
            "url": "mqtt://<ip_address>",
            "username": "<username>",
            "password": "<password>",
            "topics": {
                "setTargetState": "paradox/control/partitions/PARTITION_NAME",
                "getTargetState": "paradox/states/partitions/PARTITION_NAME/target_state",
                "getCurrentState": "paradox/states/partitions/PARTITION_NAME/current_state"
            },
            "currentStateValues": [
                "armed_home",
                "armed_away",
                "armed_night",
                "disarmed",
                "triggered"
            ],
            "targetStateValues": [
                "armed_home",
                "armed_away",
                "armed_night",
                "disarmed"
            ],
            "restrictTargetState": [ 1, 3 ]
}
  1. Finally, restart Homebridge.
  • If you need arm_stay (index 0) or arm_night (index 2), change the restrictTargetState array to include the respective indexes from the array of targetStateValues.
  • EVO panels do not support armed_night so remove index 2: "restrictTargetState": [ 0, 1, 3 ]
  • You can lookup escaped partition names like ../partitions/PARTITION_NAME in MQTT Explorer. Unescaped ../partitions/PARTITION NAME will not work.

Motion sensors

  1. In Homebridge's config.json file, or through Homebridge's Config Editor, add the following accessory:
{
"accessory": "mqttthing",
"type": "motionSensor",
"name": "NAME-OF-ZONE",
"url": "mqtt://<ip_address>",
"username": "<username>",
"password": "<password>",
"topics": {
    "getMotionDetected": "paradox/states/zones/NAME-OF-ZONE/open"
},
    "onValue": "True",
    "offValue": "False"
}
  1. Finally, restart Homebridge.