Skip to content

tmelliottjr/homebridge-zwave

 
 

Repository files navigation

homebridge-zwave

Version Build Status npm License

A Homebridge plugin for ZWave devices.

Index

Prerequisites

  1. Node.js >= 11
  2. OpenZWave 1.6
  3. Homebridge >= 0.4.49
  4. A good understanding of how Homebridge and HomeKit works

Installation

npm i -g homebridge-zwave

Usage

Register the plugin with Homebridge by adding a new entry to the platforms section of your Homebridge config:

{
  "platform": "ZWavePlatform",
  "name": "ZWavePlatform",
  "zwave": {
    "devicePath": "/dev/cu.usbmodem14201"
  },
  "accessories": [
    {
      "zwaveNodeId": 2,
      "displayName": "Desk Power Socket",
      "homekitCategory": "Outlet",
      "homekitServices": [
        "Outlet"
      ]
    },
    {
      "zwaveNodeId": 3,
      "displayName": "Light Switch",
      "homekitCategory": "Switch",
      "homekitServices": [
        "Switch"
      ]
    },
    {
      "zwaveNodeId": 4,
      "displayName": "Office Multisensor",
      "homekitCategory": "Sensor",
      "homekitServices": [
        "Battery",
        "MotionSensor",
        "HumiditySensor",
        "TemperatureSensor"
      ]
    }
  ],
  "noCache": false
}

If you do not have a platforms section in your Homebridge config you will need to define one.

zwave.devicePath is the path to your ZWave controller. This can vary based on the controller manufacturer and the operating system you are using.

accessories is where you will map a ZWave node to a HomeKit accessory. To define an accessory the information needed is:

  • zwaveNodeId - the ID of the node in the ZWave network that this accessory is for
  • displayName - the name that will be used for this accessory
  • homekitCategory - the type of accessory HomeKit will see this accessory as. Supported categories are:
    • Outlet
    • Sensor
    • Switch
  • homekitServices - the HomeKit services provided by this accessory. Supported services are:
    • If homekitCategory is Outlet:
      • Outlet
    • If homekitCategory is Sensor:
      • Battery
      • HumiditySensor
      • LightSensor
      • MotionSensor
      • TemperatureSensor
    • if homekitCategory is Switch
      • Switch

noCache sets whether accessories registered by this plugin should be cached or not. By default this value is false. Set to true to disable the cache.

Notes

Devices tested with this plugin

FAQ's

How do I install OpenZWave on macOS

You can install v1.6 of OpenZWave using Homebrew:

brew tap mike182uk/tap

brew install mike182uk/tap/open-zwave

⚠️ WARNING

If you run:

brew install open-zwave

This will install an older version of OpenZWave that will not work with this plugin.

About

A Homebridge plugin for ZWave devices

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%