homebridge-multiple-switch 1.1.3 → 1.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +70 -17
  2. package/package.json +15 -2
package/README.md CHANGED
@@ -1,17 +1,70 @@
1
- # Homebridge Multiple Switch Plugin
2
-
3
- ## Overview
4
- The **Homebridge Multiple Switch** plugin allows you to create and manage multiple virtual switches within the HomeKit environment. This plugin is ideal for users who want to control multiple devices or scenarios using a single accessory with multiple switch options.
5
-
6
- ## Features
7
- - **Multiple Switches**: Add, manage, and control multiple virtual switches under one accessory in HomeKit.
8
- - **Master Switch**: Optionally add a master switch that controls all other switches simultaneously.
9
- - **Customizable**: Easily configure the number of switches and their names through the Homebridge UI.
10
- - **Flexible**: Supports dynamic addition of switches, allowing for easy scaling to your needs.
11
-
12
- ## Installation
13
- 1. Ensure you have [Homebridge](https://homebridge.io) installed and running.
14
- 2. Install the plugin via Homebridge or npm:
15
- ```bash
16
- npm install -g homebridge-multiple-switch
17
- 3. Configure the plugin through the Homebridge UI or manually edit your config.json.
1
+ # homebridge-multiple-switch
2
+
3
+ [![npm](https://img.shields.io/npm/v/homebridge-multiple-switch)](https://www.npmjs.com/package/homebridge-multiple-switch)
4
+ [![GitHub issues](https://img.shields.io/github/issues/azadaydinli/homebridge-multiple-switch)](https://github.com/azadaydinli/homebridge-multiple-switch/issues)
5
+ [![GitHub license](https://img.shields.io/github/license/azadaydinli/homebridge-multiple-switch)](https://github.com/azadaydinli/homebridge-multiple-switch/blob/master/LICENSE)
6
+
7
+ A lightweight Homebridge plugin that lets you create multiple customizable dummy switches (Outlet/Fan/Light/Switch) with different behavior modes including Independent, Master, and Single-Switch Mode.
8
+
9
+ ---
10
+
11
+ ## ✨ Features
12
+
13
+ - Multiple switches in a single accessory
14
+ - Each switch can be `switch`, `outlet`, `lightbulb`, or `fan`
15
+ - **Independent Mode** – all switches work separately
16
+ - **Master Mode** – adds a master switch that controls all other switches
17
+ - **Single Mode** only one switch can be on at any time
18
+ - Auto turn-off (in milliseconds)
19
+ - Works seamlessly with HomeKit and Siri
20
+
21
+ ---
22
+
23
+ ## 📦 Installation
24
+
25
+ Install the plugin via the Homebridge UI:
26
+
27
+ 1. Go to **Plugins**
28
+ 2. Search for `homebridge-multiple-switch`
29
+ 3. Click **Install**
30
+
31
+ Or use the command line:
32
+
33
+ ```bash
34
+ npm install -g homebridge-multiple-switch
35
+ ```
36
+
37
+ ---
38
+
39
+ ## ⚙️ Configuration
40
+
41
+ You can configure the plugin directly via the Homebridge UI, or manually in config.json:
42
+
43
+ ```bash
44
+ {
45
+ "accessory": "MultipleSwitchAccessory",
46
+ "name": "My Multi Switch",
47
+ "switchCount": 3,
48
+ "type": "outlet",
49
+ "mode": "independent",
50
+ "autoTurnOff": 1000,
51
+ "defaultState": false,
52
+ "states": [
53
+ { "type": "switch", "autoTurnOff": 3000 },
54
+ { "type": "fan" },
55
+ { "type": "lightbulb", "defaultState": true }
56
+ ]
57
+ }
58
+ ```
59
+
60
+ ### 🔧 Configuration Options
61
+
62
+ | Field | Type | Required | Description |
63
+ |---------------|---------|----------|-----------------------------------------------------------------------------|
64
+ | `name` | string | ✅ | Name of the accessory |
65
+ | `switchCount` | number | ✅ | Number of switches to create (max depends on HomeKit limits) |
66
+ | `type` | string | ❌ | Default type: `switch`, `outlet`, `lightbulb`, or `fan` |
67
+ | `mode` | string | ❌ | `independent`, `master`, or `single` |
68
+ | `autoTurnOff` | number | ❌ | Global auto-off in milliseconds |
69
+ | `defaultState`| boolean | ❌ | Default on/off state on restart |
70
+ | `states` | array | ❌ | Per-switch custom settings (overrides global config) |
package/package.json CHANGED
@@ -1,12 +1,25 @@
1
1
  {
2
2
  "name": "homebridge-multiple-switch",
3
- "version": "1.1.3",
3
+ "version": "1.1.4",
4
4
  "description": "Multiple switch accessory for Homebridge",
5
+ "homepage": "https://github.com/azadaydinli/homebridge-multiple-switch",
5
6
  "main": "index.js",
6
7
  "author": "Azad Aydınlı",
7
8
  "license": "ISC",
9
+ "bugs": {
10
+ "url": "https://github.com/azadaydinli/homebridge-multiple-switch/issues"
11
+ },
8
12
  "keywords": [
9
- "homebridge-plugin"
13
+ "homebridge-plugin",
14
+ "homebridge",
15
+ "homekit",
16
+ "switch",
17
+ "outlet",
18
+ "lightbulb",
19
+ "fan",
20
+ "dummy",
21
+ "multiple",
22
+ "accessory"
10
23
  ],
11
24
  "repository": {
12
25
  "type": "git",