homebridge-alexa 0.5.61-beta.3 → 0.5.63
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.
- package/CHANGELOG.md +9 -0
- package/Installation.md +576 -0
- package/README.md +14 -534
- package/alexaDiscovery.json +3938 -0
- package/config.schema.json +58 -51
- package/lib/alexaActions.js +8 -10
- package/lib/alexaLocal.js +32 -46
- package/lib/parse/Accessory.js +0 -2
- package/lib/parse/Homebridges.js +6 -10
- package/package.json +4 -4
- package/plugin.js +20 -28
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. This project uses [Semantic Versioning](https://semver.org/).
|
|
4
4
|
|
|
5
|
+
## 0.5.63 (2022-04-27)
|
|
6
|
+
|
|
7
|
+
## [Version 0.5.63](https://github.com/northernman54/homebridge-alexa/compare/v0.5.61...v0.5.63)
|
|
8
|
+
|
|
9
|
+
#### Changes
|
|
10
|
+
|
|
11
|
+
- Updates to README in regards to switch to subscription based model for the cloud services.
|
|
12
|
+
- Lower default cloud connection keepalive to 5 minutes
|
|
13
|
+
|
|
5
14
|
## 0.5.61 (2022-03-21)
|
|
6
15
|
|
|
7
16
|
## [Version 0.5.61](https://github.com/northernman54/homebridge-alexa/compare/v0.5.56...v0.5.61)
|
package/Installation.md
ADDED
|
@@ -0,0 +1,576 @@
|
|
|
1
|
+
Installation and Configuration of Homebridge Alexa
|
|
2
|
+
==================================================
|
|
3
|
+
|
|
4
|
+
<!--ts-->
|
|
5
|
+
* [Installation and Configuration of Homebridge Alexa](#installation-and-configuration-of-homebridge-alexa)
|
|
6
|
+
* [Setup Instructions for users of the Homebridge UI](#setup-instructions-for-users-of-the-homebridge-ui)
|
|
7
|
+
* [Create Homebridge-Alexa Cloud Services Account](#create-homebridge-alexa-cloud-services-account)
|
|
8
|
+
* [Install and Configure the Plugin](#install-and-configure-the-plugin)
|
|
9
|
+
* [Installation in Homebridge UI](#installation-in-homebridge-ui)
|
|
10
|
+
* [Configuration in Homebridge UI](#configuration-in-homebridge-ui)
|
|
11
|
+
* [Enabling and linking the Homebridge Smart Home Skill](#enabling-and-linking-the-homebridge-smart-home-skill)
|
|
12
|
+
* [Viewing Account Status](#viewing-account-status)
|
|
13
|
+
* [Legacy Setup Instructions for users not using the Homebridge UI, includes advanced configuration options](#legacy-setup-instructions-for-users-not-using-the-homebridge-ui-includes-advanced-configuration-options)
|
|
14
|
+
* [Prepare Homebridge for plugin installation](#prepare-homebridge-for-plugin-installation)
|
|
15
|
+
* [Install Plugin](#install-plugin)
|
|
16
|
+
* [Create homebridge-alexa account](#create-homebridge-alexa-account)
|
|
17
|
+
* [HomeBridge-alexa plugin configuration](#homebridge-alexa-plugin-configuration)
|
|
18
|
+
* [Required parameters](#required-parameters)
|
|
19
|
+
* [Optional parameters](#optional-parameters)
|
|
20
|
+
* [pin](#pin)
|
|
21
|
+
* [routines](#routines)
|
|
22
|
+
* [blind](#blind)
|
|
23
|
+
* [door](#door)
|
|
24
|
+
* [debug](#debug)
|
|
25
|
+
* [refresh](#refresh)
|
|
26
|
+
* [filter](#filter)
|
|
27
|
+
* [deviceList & deviceListHandling](#devicelist--devicelisthandling)
|
|
28
|
+
* [combine](#combine)
|
|
29
|
+
* [speakers](#speakers)
|
|
30
|
+
* [Inputs](#inputs)
|
|
31
|
+
* [Apple TV](#apple-tv)
|
|
32
|
+
* [Yamaha Spotify Controls](#yamaha-spotify-controls)
|
|
33
|
+
* [New Parser](#new-parser)
|
|
34
|
+
* [Initial Testing and confirming configuration](#initial-testing-and-confirming-configuration)
|
|
35
|
+
* [Enable Homebridge smarthome skill and link accounts](#enable-homebridge-smarthome-skill-and-link-accounts)
|
|
36
|
+
* [Discover Devices](#discover-devices)
|
|
37
|
+
|
|
38
|
+
<!-- Added by: sgracey, at: -->
|
|
39
|
+
|
|
40
|
+
<!--te-->
|
|
41
|
+
|
|
42
|
+
# Setup Instructions for users of the Homebridge UI
|
|
43
|
+
|
|
44
|
+
## Create Homebridge-Alexa Cloud Services Account
|
|
45
|
+
|
|
46
|
+
This plugin requires the usage of cloud services to link your Amazon Alexa Account to the plugin. Please create an account at https://www.homebridge.ca/. The account details will be needed as part of plugin configuration and for linking the Homebridge smart home skill.
|
|
47
|
+
|
|
48
|
+
## Install and Configure the Plugin
|
|
49
|
+
|
|
50
|
+
### Installation in Homebridge UI
|
|
51
|
+
|
|
52
|
+
From the Plugins tab, search for and install the "Homebridge Alexa" plugin
|
|
53
|
+
|
|
54
|
+
### Configuration in Homebridge UI
|
|
55
|
+
|
|
56
|
+
Please enter the username and password you created earlier at https://www.homebridge.ca/.
|
|
57
|
+
|
|
58
|
+
If you have changed your homebridge PIN from the default `031-45-154`, please enter it under the optional settings.
|
|
59
|
+
|
|
60
|
+
Restart homebridge
|
|
61
|
+
|
|
62
|
+
## Enabling and linking the Homebridge Smart Home Skill
|
|
63
|
+
|
|
64
|
+
In the Amazon Alexa Application on your smart phone, search for the Homebridge Skill and enable it. When you enable the skill, it will take you to the https://www.homebridge.ca/ website to enable and link the skill to the plugin. You can now ask Alexa to `discover devices` and it should discover your homebridge devices.
|
|
65
|
+
|
|
66
|
+
### Viewing Account Status
|
|
67
|
+
|
|
68
|
+
On the homebridge.ca website you can view your account status, and identify any setup issues.
|
|
69
|
+
|
|
70
|
+
# Legacy Setup Instructions for users not using the Homebridge UI, includes advanced configuration options
|
|
71
|
+
|
|
72
|
+
* If you are looking for a basic setup to get this plugin up and running check out this guide (https://sambrooks.net/controlling-homebridge-using-alexa/). And here is another setup guide (https://www.youtube.com/watch?v=Ylg4yiw8ofM).
|
|
73
|
+
|
|
74
|
+
## Prepare Homebridge for plugin installation
|
|
75
|
+
|
|
76
|
+
The setup of the plugin is very straight forward, and requires enabling insecure mode of each homebridge instance you want to control from Alexa.
|
|
77
|
+
|
|
78
|
+
1. All homebridge instances that you want to control from Alexa need to run in insecure mode with -I included on the command line. How you make this change will depend on your installation of homebridge, and how you start homebridge. If you start from the command line, it would look like this:
|
|
79
|
+
|
|
80
|
+
```
|
|
81
|
+
homebridge -I
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
* If your using systemd to manage homebridge, the -I is added to the file /etc/default/homebridge in the line, HOMEBRIDGE_OPTS ie.
|
|
85
|
+
|
|
86
|
+
```
|
|
87
|
+
# Defaults / Configuration options for homebridge
|
|
88
|
+
# The following settings tells homebridge where to find the config.json file and where to persist the data (i.e. pairing and others)
|
|
89
|
+
HOMEBRIDGE_OPTS=-I
|
|
90
|
+
|
|
91
|
+
# If you uncomment the following line, homebridge will log more
|
|
92
|
+
# You can display this via systemd's journalctl: journalctl -f -u homebridge
|
|
93
|
+
#DEBUG=
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
* If your using pm2 to manage the startup of homebridge, you can add the -I option with these steps
|
|
97
|
+
|
|
98
|
+
```
|
|
99
|
+
pm2 delete homebridge
|
|
100
|
+
pm2 cleardump
|
|
101
|
+
pm2 start homebridge -- -I
|
|
102
|
+
pm2 save
|
|
103
|
+
```
|
|
104
|
+
To review your settings, use command below to check if homebridge was sucessfully registered to pm2. After that, you can try to reboot your system and check whether you can control homebridge devices with Alexa app.
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
```
|
|
108
|
+
pm2 show homebridge
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
* If you have multiple homebridge options, the -I should be listed first. ie
|
|
113
|
+
|
|
114
|
+
```
|
|
115
|
+
HOMEBRIDGE_OPTS=-I -U /var/homebridge
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
* If you are running with a docker container ( Oznu's), you can add the -I flag following these instructions:
|
|
119
|
+
|
|
120
|
+
https://github.com/oznu/docker-homebridge/issues/79
|
|
121
|
+
|
|
122
|
+
```
|
|
123
|
+
Variable=HOMEBRIDGE_INSECURE
|
|
124
|
+
Value=1
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
```
|
|
128
|
+
Go to the Docker app
|
|
129
|
+
Stop the Homebridge container
|
|
130
|
+
Edit the container and go to the Environment tab
|
|
131
|
+
Add environment variable
|
|
132
|
+
Save and start container
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
## Install Plugin
|
|
136
|
+
|
|
137
|
+
2. The setup of homebridge-alexa is similar to other plugins, except it doesn't have any devices in the Home app;-) I'm just reusing the runtime and configuration file management. And it only needs to installed once if you have multiple homeridge's installed. It will auto-discover and connect to the other instances.
|
|
138
|
+
|
|
139
|
+
```
|
|
140
|
+
sudo npm install -g homebridge-alexa
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
## Create homebridge-alexa account
|
|
144
|
+
|
|
145
|
+
3. An account to link your Amazon Alexa to HomeBridge needs to created on this website https://www.homebridge.ca/. This account will be used when you enable the home skill in the Alexa App on your mobile, and in the configuration of the plugin in homebridge.
|
|
146
|
+
|
|
147
|
+
|
|
148
|
+
## HomeBridge-alexa plugin configuration
|
|
149
|
+
|
|
150
|
+
4. Add the plugin to your config.json. The login and password in the config.json, are the credentials you created earlier for the https://www.homebridge.ca/ website. This only needs to be completed for one instance of homebridge in your environment, it will discover the accessories connected to your other homebridges automatically.
|
|
151
|
+
|
|
152
|
+
```
|
|
153
|
+
"platforms": [
|
|
154
|
+
{
|
|
155
|
+
"platform": "Alexa",
|
|
156
|
+
"name": "Alexa",
|
|
157
|
+
"username": "....",
|
|
158
|
+
"password": "...."
|
|
159
|
+
}
|
|
160
|
+
],
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
### Required parameters
|
|
164
|
+
|
|
165
|
+
* username - Login created for the skill linking website https://www.homebridge.ca/
|
|
166
|
+
* password - Login created for the skill linking website https://www.homebridge.ca/
|
|
167
|
+
|
|
168
|
+
### Optional parameters
|
|
169
|
+
|
|
170
|
+
#### pin
|
|
171
|
+
- If you had changed your homebridge pin from the default of "pin": "031-45-154" ie
|
|
172
|
+
|
|
173
|
+
```
|
|
174
|
+
"platforms": [
|
|
175
|
+
{
|
|
176
|
+
"platform": "Alexa",
|
|
177
|
+
"name": "Alexa",
|
|
178
|
+
"username": "....",
|
|
179
|
+
"password": "....",
|
|
180
|
+
"pin": "031-45-155"
|
|
181
|
+
}
|
|
182
|
+
],
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
#### routines
|
|
186
|
+
- Enables passing to Alexa of real time events from Motion and Contact sensors. For use in the Alexa app to create Routines triggered by these sensors. Not required unless you are using Alexa Routines.
|
|
187
|
+
|
|
188
|
+
```
|
|
189
|
+
"platforms": [
|
|
190
|
+
{
|
|
191
|
+
"platform": "Alexa",
|
|
192
|
+
"name": "Alexa",
|
|
193
|
+
"username": "....",
|
|
194
|
+
"password": "....",
|
|
195
|
+
"routines": true
|
|
196
|
+
}
|
|
197
|
+
],
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
#### blind
|
|
201
|
+
- Enables natural wording for opening and closing blinds, and window coverings. Not supported in all countries. Defaults to false
|
|
202
|
+
|
|
203
|
+
```
|
|
204
|
+
"platforms": [
|
|
205
|
+
{
|
|
206
|
+
"platform": "Alexa",
|
|
207
|
+
"name": "Alexa",
|
|
208
|
+
"username": "....",
|
|
209
|
+
"password": "....",
|
|
210
|
+
"blind": true
|
|
211
|
+
}
|
|
212
|
+
],
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
#### door
|
|
216
|
+
- Enables natural wording for opening and closing garage doors. Not supported in all countries. Please note that opening a garage door requires setting a voice pin within the Alexa app. Defaults to false
|
|
217
|
+
|
|
218
|
+
```
|
|
219
|
+
"platforms": [
|
|
220
|
+
{
|
|
221
|
+
"platform": "Alexa",
|
|
222
|
+
"name": "Alexa",
|
|
223
|
+
"username": "....",
|
|
224
|
+
"password": "....",
|
|
225
|
+
"door": true
|
|
226
|
+
}
|
|
227
|
+
],
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
#### debug
|
|
231
|
+
- This enables debug logging mode, can be used instead of the command line option ( DEBUG=* homebridge )
|
|
232
|
+
|
|
233
|
+
```
|
|
234
|
+
"platforms": [
|
|
235
|
+
{
|
|
236
|
+
"platform": "Alexa",
|
|
237
|
+
"name": "Alexa",
|
|
238
|
+
"username": "....",
|
|
239
|
+
"password": "....",
|
|
240
|
+
"debug": true
|
|
241
|
+
}
|
|
242
|
+
],
|
|
243
|
+
```
|
|
244
|
+
|
|
245
|
+
#### refresh
|
|
246
|
+
- Frequency of refreshes of the homebridge accessory cache, in seconds. Defaults to 15 minutes.
|
|
247
|
+
|
|
248
|
+
```
|
|
249
|
+
"platforms": [
|
|
250
|
+
{
|
|
251
|
+
"platform": "Alexa",
|
|
252
|
+
"name": "Alexa",
|
|
253
|
+
"username": "....",
|
|
254
|
+
"password": "....",
|
|
255
|
+
"refresh": 900
|
|
256
|
+
}
|
|
257
|
+
],
|
|
258
|
+
```
|
|
259
|
+
|
|
260
|
+
#### filter
|
|
261
|
+
- Limits accessories shared with Alexa to a single homebridge instance. ( I'm using this setting with Amazon for skill testing. ). The setting is ip:port of homebridge instance.
|
|
262
|
+
|
|
263
|
+
```
|
|
264
|
+
"platforms": [
|
|
265
|
+
{
|
|
266
|
+
"platform": "Alexa",
|
|
267
|
+
"name": "Alexa",
|
|
268
|
+
"username": "....",
|
|
269
|
+
"password": "....",
|
|
270
|
+
"filter": "192.168.1.122:51826"
|
|
271
|
+
}
|
|
272
|
+
],
|
|
273
|
+
```
|
|
274
|
+
|
|
275
|
+
#### deviceList & deviceListHandling
|
|
276
|
+
- allow or deny devices by name to be exposed to alexa. Values are checked to see if they are contained within the name. ( Under the covers it is using regex, so more complex options are available )
|
|
277
|
+
|
|
278
|
+
```
|
|
279
|
+
"platforms": [
|
|
280
|
+
{
|
|
281
|
+
"platform": "Alexa",
|
|
282
|
+
"name": "Alexa",
|
|
283
|
+
"username": "....",
|
|
284
|
+
"password": "....",
|
|
285
|
+
"deviceListHandling": "deny", // or allow
|
|
286
|
+
"deviceList":
|
|
287
|
+
[
|
|
288
|
+
"LightBulb",
|
|
289
|
+
"GarageDoor",
|
|
290
|
+
"SecureDevice"
|
|
291
|
+
]
|
|
292
|
+
}
|
|
293
|
+
],
|
|
294
|
+
```
|
|
295
|
+
|
|
296
|
+
#### combine
|
|
297
|
+
- Combine disparate accessories into one common device. My example here is combining my TV Remote (KODI), which only has ON/OFF and Volume controls into the Apple TV (TV) playback controls. And combining the spotify controls from my Yamaha receiver into the Zone.
|
|
298
|
+
|
|
299
|
+
```
|
|
300
|
+
"platforms": [
|
|
301
|
+
{
|
|
302
|
+
"platform": "Alexa",
|
|
303
|
+
"name": "Alexa",
|
|
304
|
+
"username": "....",
|
|
305
|
+
"password": "....",
|
|
306
|
+
"combine": [{
|
|
307
|
+
"into": "TV",
|
|
308
|
+
"from": ["KODI", "Power (TV)"]
|
|
309
|
+
}, {
|
|
310
|
+
"into": "Front",
|
|
311
|
+
"from": ["Yamaha"]
|
|
312
|
+
}, {
|
|
313
|
+
"into": "Rear",
|
|
314
|
+
"from": ["Yamaha"]
|
|
315
|
+
}],
|
|
316
|
+
}
|
|
317
|
+
],
|
|
318
|
+
```
|
|
319
|
+
|
|
320
|
+
* into - Device name to combine into
|
|
321
|
+
* from - Device name to combine from, can be a list of multiple devices.
|
|
322
|
+
|
|
323
|
+
|
|
324
|
+
#### speakers
|
|
325
|
+
- Devices to configure as speakers as HomeKit currently does not have a Speaker service, and enable the alexa phase `Alexa, raise the volume on`.
|
|
326
|
+
|
|
327
|
+
```
|
|
328
|
+
"platforms": [
|
|
329
|
+
{
|
|
330
|
+
"platform": "Alexa",
|
|
331
|
+
"name": "Alexa",
|
|
332
|
+
"username": "....",
|
|
333
|
+
"password": "....",
|
|
334
|
+
"speakers": [{
|
|
335
|
+
"manufacturer": "...",
|
|
336
|
+
"name": "..."
|
|
337
|
+
}]
|
|
338
|
+
}
|
|
339
|
+
],
|
|
340
|
+
```
|
|
341
|
+
|
|
342
|
+
* manufacturer - Is the manufacturer of the accessory as shown in the Home App
|
|
343
|
+
* name - Is the name of the accessory as shown in the Home App
|
|
344
|
+
|
|
345
|
+
ie
|
|
346
|
+
```
|
|
347
|
+
{
|
|
348
|
+
"platform": "Alexa",
|
|
349
|
+
"username": "...",
|
|
350
|
+
"password": "...",
|
|
351
|
+
"name": "Alexa",
|
|
352
|
+
"speakers": [{
|
|
353
|
+
"manufacturer": "Yamaha",
|
|
354
|
+
"name": "Front"
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
"manufacturer": "Yamaha",
|
|
358
|
+
"name": "Rear"
|
|
359
|
+
},
|
|
360
|
+
{
|
|
361
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
362
|
+
"name": "Panasonic"
|
|
363
|
+
}
|
|
364
|
+
]
|
|
365
|
+
}
|
|
366
|
+
```
|
|
367
|
+
|
|
368
|
+
#### Inputs
|
|
369
|
+
|
|
370
|
+
- This combines several buttons that control inputs on a TV or Stereo into an Alexa input control and enables the phrase `Alexa, change to input to`. For the names of the inputs, Amazon provided a list ( see alexa name below ) that you can choose from. You can map multiple alexa names to the same button as well.
|
|
371
|
+
|
|
372
|
+
`Alexa, change input to Tuner on the TV`
|
|
373
|
+
|
|
374
|
+
`Alexa, change input to HDMI 1 on the TV`
|
|
375
|
+
|
|
376
|
+
```
|
|
377
|
+
{
|
|
378
|
+
"platform": "Alexa",
|
|
379
|
+
"username": "...",
|
|
380
|
+
"password": "...",
|
|
381
|
+
"name": "Alexa",
|
|
382
|
+
"inputs": [{
|
|
383
|
+
"into": "TV",
|
|
384
|
+
"devices": [{
|
|
385
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
386
|
+
"name": "Tuner",
|
|
387
|
+
"alexaName": "TUNER"
|
|
388
|
+
}, {
|
|
389
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
390
|
+
"name": "Tuner",
|
|
391
|
+
"alexaName": "TV TUNER"
|
|
392
|
+
}, {
|
|
393
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
394
|
+
"name": "Tuner",
|
|
395
|
+
"alexaName": "TV"
|
|
396
|
+
}, {
|
|
397
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
398
|
+
"name": "HDMI1",
|
|
399
|
+
"alexaName": "HDMI 1"
|
|
400
|
+
}, {
|
|
401
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
402
|
+
"name": "HDMI1",
|
|
403
|
+
"alexaName": "TV KODI"
|
|
404
|
+
}, {
|
|
405
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
406
|
+
"name": "HDMI1",
|
|
407
|
+
"alexaName": "MEDIA PLAYER"
|
|
408
|
+
}, {
|
|
409
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
410
|
+
"name": "HDMI2",
|
|
411
|
+
"alexaName": "HDMI 2"
|
|
412
|
+
}, {
|
|
413
|
+
"manufacturer": "HTTP-IRBlaster",
|
|
414
|
+
"name": "HDMI2",
|
|
415
|
+
"alexaName": "TV NETFLIX"
|
|
416
|
+
}]
|
|
417
|
+
}],
|
|
418
|
+
```
|
|
419
|
+
|
|
420
|
+
In my setup I use an OTA Antenna, hence the Tuner option and have a KODI box on HDMI 1, and a Apple TV we use for Netflix on HDMI 2. For the alexaName's "TV KODI", "TV TUNER", and "TV NETFLIX" these were not part of the Amazon documentation and may stop working at any time or may not work in your region.
|
|
421
|
+
|
|
422
|
+
* into - Name of the existing accessory to add the input function to. In my setup this is my Apple TV accessory.
|
|
423
|
+
|
|
424
|
+
* manufacturer - Is the manufacturer of the accessory as shown in the Home App
|
|
425
|
+
|
|
426
|
+
* name - Is the name of the accessory as shown in the Home App
|
|
427
|
+
|
|
428
|
+
* alexaName - This the input your are asking Alexa to change to.
|
|
429
|
+
|
|
430
|
+
```
|
|
431
|
+
AUX 1, AUX 2, AUX 3, AUX 4, AUX 5, AUX 6, AUX 7, BLURAY, CABLE, CD, COAX 1, COAX 2, COMPOSITE 1, DVD, GAME,
|
|
432
|
+
HD RADIO, HDMI 1, HDMI 2, HDMI 3, HDMI 4, HDMI 5, HDMI 6, HDMI 7, HDMI 8, HDMI 9, HDMI 10, HDMI ARC, INPUT 1,
|
|
433
|
+
INPUT 2, INPUT 3, INPUT 4, INPUT 5, INPUT 6, INPUT 7, INPUT 8, INPUT 9, INPUT 10, IPOD, LINE 1, LINE 2, LINE 3,
|
|
434
|
+
LINE 4, LINE 5, LINE 6, LINE 7, MEDIA PLAYER, OPTICAL 1, OPTICAL 2, PHONO, PLAYSTATION, PLAYSTATION 3,
|
|
435
|
+
PLAYSTATION 4, SATELLITE, SMARTCAST, TUNER, TV, USB DAC, VIDEO 1, VIDEO 2, VIDEO 3, XBOX
|
|
436
|
+
```
|
|
437
|
+
|
|
438
|
+
#### Apple TV
|
|
439
|
+
|
|
440
|
+
- This is the config from my Apple TV using the homebridge-apple-tv plugin after completing the pairing. Please note, *"showDefaultSwitches": true* and *"defaultSwitchesIncludeATVName": true*, are required parameters. Please note I blanked out the devices/credentials section with my ATV credentials.
|
|
441
|
+
|
|
442
|
+
```
|
|
443
|
+
{
|
|
444
|
+
"platform":"AppleTV",
|
|
445
|
+
"name":"Apple TV",
|
|
446
|
+
"devices": [{
|
|
447
|
+
"id": "Cottage",
|
|
448
|
+
"name": "TV",
|
|
449
|
+
"credentials": "...." }
|
|
450
|
+
],
|
|
451
|
+
"showDefaultSwitches": true,
|
|
452
|
+
"defaultSwitchesIncludeATVName": true,
|
|
453
|
+
"showPairSwitches": false,
|
|
454
|
+
"hideWelcomeMessage": true
|
|
455
|
+
}
|
|
456
|
+
```
|
|
457
|
+
|
|
458
|
+
- This is the config for the homebridge-apple-tv-remote plugin. This allows you to pause/play forward/rewind on device.
|
|
459
|
+
|
|
460
|
+
Please note that the name in brackets ie (TV) will be the Name alexa uses to control your AppleTV
|
|
461
|
+
|
|
462
|
+
```
|
|
463
|
+
{
|
|
464
|
+
"platform": "AppleTvPlatform",
|
|
465
|
+
"devices": [{
|
|
466
|
+
"name": "Family Room (TV)",
|
|
467
|
+
"credentials": "XXXXXXXXXXXX",
|
|
468
|
+
"isOnOffSwitchEnabled": true,
|
|
469
|
+
"onOffSwitchName": "Power (TV)",
|
|
470
|
+
"isPlayPauseSwitchEnabled": true,
|
|
471
|
+
"playPauseSwitchName": "Play (TV)",
|
|
472
|
+
"commandSwitches": [{
|
|
473
|
+
"name": "Right (TV)",
|
|
474
|
+
"commands": [{
|
|
475
|
+
"key": "right",
|
|
476
|
+
"longPress": false
|
|
477
|
+
}]
|
|
478
|
+
}, {
|
|
479
|
+
"name": "Left (TV)",
|
|
480
|
+
"commands": [{
|
|
481
|
+
"key": "left",
|
|
482
|
+
"longPress": false
|
|
483
|
+
}]
|
|
484
|
+
}]
|
|
485
|
+
}],
|
|
486
|
+
"isApiEnabled": false
|
|
487
|
+
}
|
|
488
|
+
```
|
|
489
|
+
|
|
490
|
+
Also to enable turning on and off your Apple TV, add this to your homebridge-alexa configuration.
|
|
491
|
+
|
|
492
|
+
```
|
|
493
|
+
"combine": [{
|
|
494
|
+
"into": "TV",
|
|
495
|
+
"from": ["Power (TV)"]
|
|
496
|
+
}]
|
|
497
|
+
```
|
|
498
|
+
|
|
499
|
+
#### Yamaha Spotify Controls
|
|
500
|
+
|
|
501
|
+
This uses the plugin homebridge-yamaha-home and a Yamaha Receiver which includes Spotify and Spotify Playback Controls.
|
|
502
|
+
|
|
503
|
+
#### New Parser
|
|
504
|
+
|
|
505
|
+
~~As of April 14, 2019 I changed the Homebridge device parser massively, to add support for Locks and Heater/Cooler devices. To go back to the old device parser, you can set an option oldParser to true. Default is to the new parser.~~
|
|
506
|
+
|
|
507
|
+
```
|
|
508
|
+
"oldParser": true
|
|
509
|
+
```
|
|
510
|
+
|
|
511
|
+
Support for the oldParser option was **deprecated** with version 0.5.0
|
|
512
|
+
|
|
513
|
+
## Initial Testing and confirming configuration
|
|
514
|
+
|
|
515
|
+
5. Start homebridge in DEBUG mode, to ensure configuration of homebridge-alexa is correct. This will need to be executed with your implementations configuration options and as the same user as you are running homebridge. If you are homebridge with an autostart script ie systemd, you will need to stop the autostart temporarily.
|
|
516
|
+
|
|
517
|
+
ie
|
|
518
|
+
```
|
|
519
|
+
DEBUG=alexa* homebridge -I
|
|
520
|
+
```
|
|
521
|
+
|
|
522
|
+
6. Please ensure that homebridge starts without errors, and output should be similar to this. This is from my setup, and I have several instances of homebridge so you may have a different number of alexaHAP lines.
|
|
523
|
+
|
|
524
|
+
```
|
|
525
|
+
alexaHAP Starting Homebridge instance discovery +0ms
|
|
526
|
+
alexaLocal Connecting to Homebridge Smart Home Skill +1ms
|
|
527
|
+
[2018-3-17 11:23:57] Homebridge is running on port 51826.
|
|
528
|
+
alexaHAP HAP Device discovered Porch Camera [ '192.168.1.226' ] +87ms
|
|
529
|
+
alexaHAP HAP instance address: Porch Camera -> howard.local -> 192.168.1.226 +1ms
|
|
530
|
+
alexaHAP HAP Device discovered Howard [ '192.168.1.226' ] +4ms
|
|
531
|
+
alexaHAP HAP instance address: Howard -> howard.local -> 192.168.1.226 +0ms
|
|
532
|
+
alexaHAP HAP Device discovered Howard-Hue [ '192.168.1.226' ] +0ms
|
|
533
|
+
alexaHAP HAP instance address: Howard-Hue -> howard.local -> 192.168.1.226 +0ms
|
|
534
|
+
alexaHAP HAP Device discovered Spare Camera [ '192.168.1.226' ] +1ms
|
|
535
|
+
alexaHAP HAP instance address: Spare Camera -> howard.local -> 192.168.1.226 +0ms
|
|
536
|
+
alexaLocal offline +5ms
|
|
537
|
+
alexaHAP HAP Device discovered Penny [ 'fe80::ba27:ebff:febf:bbaa', '192.168.1.4', '169.254.185.85' ] +42ms
|
|
538
|
+
alexaHAP HAP instance address: Penny -> penny.local -> 192.168.1.4 +0ms
|
|
539
|
+
alexaHAP Homebridge instance discovered Howard with 12 accessories +7ms
|
|
540
|
+
alexaHAP Homebridge instance discovered Porch Camera with 1 accessories +11ms
|
|
541
|
+
alexaHAP Homebridge instance discovered Howard-Hue with 5 accessories +1ms
|
|
542
|
+
alexaHAP Homebridge instance discovered Spare Camera with 1 accessories +10ms
|
|
543
|
+
alexaHAP Homebridge instance discovered Penny with 26 accessories +101ms
|
|
544
|
+
alexaHAP HAP Device discovered Bart-Dev [ 'fe80::1c05:2c:5ae4:abdc', '192.168.1.231' ] +662ms
|
|
545
|
+
alexaHAP HAP instance address: Bart-Dev -> Bart.local -> 192.168.1.231 +0ms
|
|
546
|
+
alexaHAP Homebridge instance discovered Bart-Dev with 1 accessories +7ms
|
|
547
|
+
alexaLocal reconnect +4s
|
|
548
|
+
alexaLocal connect command/northernMan/# +174ms
|
|
549
|
+
```
|
|
550
|
+
|
|
551
|
+
Please note, that if you have other HomeKit devices on your network, like Philip's hue hub's, they will generate a `HAP Discover failed` message that can be ignored.
|
|
552
|
+
|
|
553
|
+
## Enable Homebridge smarthome skill and link accounts
|
|
554
|
+
|
|
555
|
+
7. In your Amazon Alexa app on your phone, please search for the "Homebridge" skill, and enable the skill. You will need to Enable and link the skill to the account you created earlier on https://www.homebridge.ca/
|
|
556
|
+
|
|
557
|
+
## Discover Devices
|
|
558
|
+
|
|
559
|
+
8. At this point you are ready to have Alexa discover devices. Once you say Alexa, discover devices, the output will get very verbose for a minute. After discovery is complete you should see a line showing the number of devices returned to Alexa.
|
|
560
|
+
|
|
561
|
+
ie
|
|
562
|
+
|
|
563
|
+
```
|
|
564
|
+
.
|
|
565
|
+
.
|
|
566
|
+
.
|
|
567
|
+
alexaTranslator Alexa Controllable Penny 22 +1ms
|
|
568
|
+
alexaTranslator Alexa Controllable Bart-Dev 0 +0ms
|
|
569
|
+
[2018-3-17 11:01:03] [Alexa] alexaDiscovery - returned 36 devices
|
|
570
|
+
```
|
|
571
|
+
|
|
572
|
+
In the event you have errors, or no devices returned please review your config.
|
|
573
|
+
|
|
574
|
+
Please note, as part of the verbose output from discovery devices, all your devices with the Alexa voice commands for each accessory are output in CSV format. You could grab these, format them into something usable and share.
|
|
575
|
+
|
|
576
|
+
9. Installation is now complete, good luck and enjoy.
|