For use in conjunction with
to play your favourite radio stations with just a voice command and control multiple output devices.
Examples:
This package acts like a standalone proxy server which endpoints get to be called by the homebridge-better-http-rgb plugin.The plugin is responsible for then advertising the various accessories to homebridge (see config.json).The middleware is using the amazing forked-daapd JSON APIto control the various accessories and redirect their actions to forked-daapd. Therefore it is possible to advertise almostany forked-daapd action to HomeKit.
$ mkdir forked-daapd-homebridge-middleware
$ npm init
$ npm install --save forked-daapd-homebridge-middleware
For the npm init
command answer all questions with [ENTER] key.
See configuration.
$ cd forked-daapd-homebridge-middleware
$ npx forked-daapd-homebridge-middleware
$ git clone https://github.com/moecre/forked-daapd-homebridge-middleware.git
$ cd forked-daapd-homebridge-middleware
$ npm install
See configuration.
$ cd forked-daapd-homebridge-middleware
$ npm start
In production I strongly advise you to use a process manager like PM2 to run forked-daapd-homebridge-middleware.In case anything unexpected happens the middleware is going to be restarted automatically by PM2.
By the way, that's a good solution for your Homebridge process, too.
Copy the distributed index.dist.json to index.json in the same directory and change the fileaccording to your setup and needs.
Param | Description |
---|---|
baseUrl | URL to your forked-daapd JSON API |
Please take a look at the provided config.json for examples. In general your Homebridgeconfiguration file is located in ~/.homebridge/config.json
.
Please replace placeholders, eg. {NAME YOUR RADIO STATION}
for ROCK ANTENNE
. Keep in mind that the name mustbe unique over all your accessories (UUID in Homebridge).
{
"accessory": "HTTP-RGB",
"name": "{NAME YOUR RADIO STATION}",
"service": "Light",
"switch": {
"status": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/playlists/{URL ENCODED NAME OF THE PLAYLIST IN FORKED-DAAPD}",
"powerOn": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/playlists/{URL ENCODED NAME OF THE PLAYLIST IN FORKED-DAAPD}/play[?shuffle=true]",
"powerOff": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/player/stop"
}
}
The /playlists/:playlist/play
endpoint has an optional parameter shuffle
. If applied all the playlist items get added to the queue shuffled.
Please replace placeholders, eg. {NAME YOUR SPEAKER}
for Hallway speaker
. Keep in mind that the name must beunique over all your accessories (UUID in Homebridge).
{
"accessory": "HTTP-RGB",
"name": "{NAME YOUR SPEAKER}",
"service": "Light",
"switch": {
"status": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/outputs/{URL ENCODED NAME OF OUTPUT DEVICE IN FORKED-DAAPD}",
"powerOn": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/outputs/{URL ENCODED NAME OF OUTPUT DEVICE IN FORKED-DAAPD}/state/on",
"powerOff": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/outputs/{URL ENCODED NAME OF OUTPUT DEVICE IN FORKED-DAAPD}/state/off"
},
"brightness": {
"status": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/outputs/{URL ENCODED NAME OF OUTPUT DEVICE IN FORKED-DAAPD}/volume",
"url": "http://{HOSTNAME ON WHICH FORKED-DAAPD-HOMEBRIDGE-MIDDLEWARE IS RUNNING}:3000/outputs/{URL ENCODED NAME OF OUTPUT DEVICE IN FORKED-DAAPD}/volume/%s"
}
}
Please have a look here.
Homebridge 是一个轻量级 NodeJS 服务器,它模拟 iOS HomeKit API,提供从 HomeKit 到“智能家居”设备制造商提供的各种第三方 API 的基本桥接。通过 Homebridge 的桥接,可以让 Siri 控制完全不支持 HomeKit 的设备。 此外 Homebridge 支持插件。
homebridge-vsx homebridge-vsx is a plugin made for homebridge,which allows switching on and off your Pioneer AV receiver. All AV receivers (VSX and SC),which work with the iControl AV5 App are support
homebridge-sesame Control and monitor your Sesame smart lock with HomeKit integration. Prerequisites Installation of Homebridge iOS 11 or later Sesame lock with enabled cloud integration Sesame Wifi A
homebridge-panasonictv A homebridge plugin for turning on and off your Panasonic Viera TV. The plugin also has experimental support for changing the volume and channel. These characteristics are not r
Quick Start | Contribute A Wake on Lan plugin for Homebridge Turn your PCs, laptops, servers and more on and off through Siri Quick Start To install the plugin, head over to the machine with Homebridg
Docker Homebridge This Alpine/Ubuntu Linux based Docker image allows you to run Nfarina's Homebridge on your home network which emulates the iOS HomeKit API. This is a multi-arch image and will also r