Single Channel Devices - homebridge-plugins/homebridge-ewelink GitHub Wiki

Use the 'Single Channel Devices' (singleDevices[]) configuration section to customise how your single-channel switch, outlet and light switch devices are exposed to HomeKit.

See Supported Devices to see which devices can be customised using this section.

By default, a device will appear in Homebridge as a single switch. You can use the Home app to change how this accessory appears:

  • a switch (by default)
  • a light (useful for devices like the T1-1C, TX-1C)
  • a fan (useful for an outlet connected to a fan)

Configuration

The easiest way to customise these devices is via the Homebridge/HOOBS UI. However, if you prefer to edit your Homebridge config file manually then here is a list of the options and and examples:

Entry Type Required Default Min Explanation
label str No "" This setting has no effect except to help identify this device.
deviceId str Yes "" eWeLink Device ID (10 characters e.g. "10000abcde".
ignoreDevice bool No false If true, this accessory will be removed and ignored from HomeKit.
deviceModel str See 1 ""

Set the model for this device.

  • "single" - Sonoff BASIC/MINI/RF/SV/RE5V1C
  • "t" - Sonoff T1/T2/T3/TX-1C
  • "pow" - Sonoff POW/R2
  • "iw" - Sonoff IW100/IW101
  • "s" - Sonoff S20/S26/S31/S55
  • "micro" - Sonoff Micro
  • "slampher" - Sonoff SLAMPHER/R2
  • "gddc5" - Eachen GD-DC5
  • "king" - KingArt KING-Q4
  • "zb" - Zigbee Single Channel (BASICZBR3/ZBMINI/S31ZB)

1 Required with Eachen GD-DC5 - set to "gddc5" to show accessory as a garage door.

showAs str No "default"

Expose this device as a different HomeKit accessory type.

Has no effect if deviceModel is "gddc5".

  • "default" - 1 Switch (Default)
  • "outlet" - 1 Outlet
  • "purifier" - 1 Air Purifier
  • "doorbell" - 1 Doorbell
  • "garage" - 1 Garage Door
  • "valve" - 1 Irrigation Valve
  • "lock" - 1 Lock
  • "p_button" - 1 Programmable Button
  • "sensor" - 1 Sensor
  • "tap" - 1 Tap/Faucet
inUsePowerThreshold int No 0 0

Only has effect when deviceModel is "pow" or "iw" and showAs is "outlet".

HomeKit will set the 'In Use' status of outlet devices to true when the wattage is above this number.

isInched bool No false

Only has effect when showAs is "default" or "outlet".

If true, the plugin will show the on/off status based on inching mode.

sensorType str No "motion"

The type of sensor to show in HomeKit if showAs is "sensor".

  • "motion" - Motion Sensor (Default)
  • "smoke" - Smoke/Fire Sensor
  • "water" - Water/Leak Sensor
  • "co" - Carbon Monoxide Sensor
  • "co2" - Carbon Dioxide Sensor
  • "occupancy" - Occupancy Sensor
  • "contact" - Contact Sensor
operationTime int See 2 100 20

2 Required if deviceModel is "gddc5" or showAs is "garage" or "lock".

  • Garage Door - the time to open/close the door
  • Lock - the time to show as unlocked

This setting is in deciseconds - count the time in seconds and multiply by 10, for example 75 for 7.5 seconds.

operationTimeDown int No - 20

Only has effect if showAs is "garage".

If your garage door has a different operation time for up and down, use this setting to specify the operation time DOWN (in deciseconds) and the other setting to specify the operation time UP.

This setting is in deciseconds - count the time in seconds and multiply by 10, for example 75 for 7.5 seconds.

sensorId str No ""

Only has effect if showAs is "garage" or "lock".

Enter the 10 digit eWeLink Device ID for a DW2 or Zigbee contact sensor that can be used to determine the current state of the garage door or lock.

hideSensor bool No false

Only has effect if showAs is "garage" or "lock".

Hide the contact sensor (defined above in sensorId) from showing in HomeKit.

obstructId str No ""

Only has effect if deviceModel is "gddc5" or showAs is "garage".

An optional switch that will trigger the Obstruction Detected feature depending on its value.

ipAddress str No ""

You can manually set the IP address for this device if it cannot be discovered by the plugin.

Has no effect if deviceModel is "king" or "zb".

overrideLogging str No "default"

Override global logging setting for this device.

  • "default" - follows global setting
  • "standard" for standard logging
  • "debug" for debug logging
  • "disable" to disable all accessory logging

Examples

An example to set a custom IP and no disabling all accessory logging:

"singleDevices": [
   {
      "deviceId": "10009553c8",
      "deviceModel": "t",
      "ipAddress": "192.168.1.13",
      "overrideLogging": "disable"
      
   }
]

An example for a POWR2 device to set the OutletInUse state to true only when the when power is over 5W:

"singleDevices": [
   {
      "deviceId": "10009553c8",
      "deviceModel": "pow",
      "inUsePowerThreshold": 5
   }
]

Accessory Simulations

Documentation Pending

  • 1 Lock (with single or multi channel device)
  • 1 Tap/Faucet (with single or multi channel device)
  • 1 Irrigation Valve (with single or multi channel device)
  • 1 Sensor (with single or multi channel device)
  • 1 Programmable Button (with single or multi channel device)
  • 1 Doorbell (with single or multi channel device)
⚠️ **GitHub.com Fallback** ⚠️