User Tools

Site Tools


philipshue

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
philipshue [2016/07/07 13:19]
wo_rasp created
philipshue [2016/09/23 20:10] (current)
wo_rasp
Line 1: Line 1:
-**Philips Hue Bridge Protocol** +**Philips Hue Bridge Protocol**\\
 This implementation adds support for the Philips Hue protocol using the Philips Hue Bridge Rest API to control Philips Hue bulbs. The protocol polls the status from the Bridge every minute to update the device values in pilight. This implementation adds support for the Philips Hue protocol using the Philips Hue Bridge Rest API to control Philips Hue bulbs. The protocol polls the status from the Bridge every minute to update the device values in pilight.
  
-**Requirements** +**Requirements**\\
 The Hue Bridge is connected to the same LAN as the machine running the pilight daemon.\\ The Hue Bridge is connected to the same LAN as the machine running the pilight daemon.\\
 Using the Hue Bridge allows smooth integration of pilight into the overall environment. Using the Hue Bridge allows smooth integration of pilight into the overall environment.
 The concept of the Hue Bridge is found here: http://​www.developers.meethue.com/​documentation/​core-concepts. The concept of the Hue Bridge is found here: http://​www.developers.meethue.com/​documentation/​core-concepts.
-The bridge itself is using the zigbee protocol to communicate with the Hue bulbs. ​This interface is currently not supported.\\+The bridge itself is using the zigbee protocol to communicate with the Hue bulbs. ​The zigbee ​interface ​protocol ​is currently not supported ​directly, however this is not considered to be a shortcoming,​ as bypassing the Hue Bridge is basically not recommended.\\ 
 +Until this protocol stack is integrated into the main pilight release, the updated development version is available at:\\ 
 +https://​github.com/​wo-rasp/​pilight/​tree/​test_dev
  
 ^Feature^Support^ ^Feature^Support^
Line 16: Line 16:
  
 To use all available settings for the bulbs you do need to use the CLI interface for the protocol ''​philipshue''​ and ''​pilight-send''​ or ''​pilight-control''​. \\ To use all available settings for the bulbs you do need to use the CLI interface for the protocol ''​philipshue''​ and ''​pilight-send''​ or ''​pilight-control''​. \\
-The pilight WEBGUI, supports a subset of the capabilities of Hue bulbs.\\ 
- 
-**Supported Brands** 
  
 +**Supported Brands**\\
 All Hue Bulbs connected to the Hue Bridge. All Hue Bulbs connected to the Hue Bridge.
  
-**Sender Arguments** +**Sender Arguments**\\
 ^Abbr^Command^Remarks^ ^Abbr^Command^Remarks^
 |-i| --bridgeip=ipaddress|Philips Hue Bridge IP Address| |-i| --bridgeip=ipaddress|Philips Hue Bridge IP Address|
Line 48: Line 45:
  
  
-**Config**+**Config**\\ 
 +In the followng example, it is assumed that the IP address of the Hue Bridge is 192.168.0.252.
  
 1. Create a user on the Hue Bridge: 1. Create a user on the Hue Bridge:
Line 66: Line 64:
 </​code>​ </​code>​
  
-or report the ''​username''​ generated:+or will report ​back the ''​username''​ generated:
 <​code>​ <​code>​
-$ pilight-send -p philipshue -i 192.168.1.252 --newuser+$ pilight-send -p philipshue -i 192.168.0.252 --newuser
 pilight-send:​ NOTICE: Create and authorize new user for pilight on Hue Bridge ... pilight-send:​ NOTICE: Create and authorize new user for pilight on Hue Bridge ...
 pilight-send:​ NOTICE: philipshue - post data = {"​devicetype":"​pilight"​} to url http://​192.168.0.252/​api pilight-send:​ NOTICE: philipshue - post data = {"​devicetype":"​pilight"​} to url http://​192.168.0.252/​api
Line 76: Line 74:
  
 You do need to copy the username to your config.json file. You do need to copy the username to your config.json file.
 +<​code>​
 "​devices":​ { "​devices":​ {
     "​Hue1":​ {     "​Hue1":​ {
Line 115: Line 114:
 The pilight GUI interface supports turning lights ON/OFF and dimming of the device in 15 steps. For all other command sequences, currently the CLI interface (pilight-send,​ pilight-control) has to be used. The pilight GUI interface supports turning lights ON/OFF and dimming of the device in 15 steps. For all other command sequences, currently the CLI interface (pilight-send,​ pilight-control) has to be used.
  
-**Configuration Steps** +**Configuration Steps**\\ 
- +Each Hue Bridge has its own username.\\ 
-Each Hue Bridge has its own username. +For each lampid, you do need to configure a device and assign it to a group.\\
-For each lampid, you do need to configure a device and assign it to a group.+
 Configure in the GUI section Dimmer devices if GUI support is required. Configure in the GUI section Dimmer devices if GUI support is required.
  
-**Examples** +**Examples**\\
 List all bulbs on the bridge: List all bulbs on the bridge:
 +<​code>​
 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --resource=lights $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --resource=lights
 +</​code>​
  
-List all scenes on the bridge:+List all scenes on the bridge:\\ 
 +<​code>​
 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --resource=scenes $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --resource=scenes
 pilight-send:​ NOTICE: philipshue - get data http://​192.168.0.252/​api/​29b7e422ee6f973bc97b3e1f3269a3/​scenes pilight-send:​ NOTICE: philipshue - get data http://​192.168.0.252/​api/​29b7e422ee6f973bc97b3e1f3269a3/​scenes
Line 132: Line 132:
 pilight-send:​ NOTICE: ac637e2f0-on-0 = {"​name":"​Relax on 0","​lights":​["​1","​2","​3"​],"​active":​true} pilight-send:​ NOTICE: ac637e2f0-on-0 = {"​name":"​Relax on 0","​lights":​["​1","​2","​3"​],"​active":​true}
 ... ...
 +</​code>​
  
 Apply a scene: Apply a scene:
 +<​code>​
 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --scene=497b50d84-on-0 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --scene=497b50d84-on-0
 +</​code>​
  
 Turn all lights on: Turn all lights on:
 +<​code>​
 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --group=0 -t $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --group=0 -t
 +</​code>​
  
 Turn all lights off: Turn all lights off:
 +<​code>​
 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --group=0 -f $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --group=0 -f
 +</​code>​
  
 Set full brightness red on light 2: Set full brightness red on light 2:
 +<​code>​
 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --lightid=2 --bri=255 --sat=255 --hue=0 $ pilight-send -p philipshue --bridgeip=192.168.0.252 --username=29b7e422ee6f973bc97b3e1f3269a3 --lightid=2 --bri=255 --sat=255 --hue=0
 +</​code>​
  
-Turn light 1 to red.+Turn light 1 to red
 +<​code>​
 $ pilight-control -d Hue1 -s on -v hue=65280 $ pilight-control -d Hue1 -s on -v hue=65280
 +</​code>​
  
-Turn all lights on+Turn all lights on
 +<​code>​
 $ pilight-control -d Hue1 -s on -v group=0 $ pilight-control -d Hue1 -s on -v group=0
 +</​code>​
  
-Turn all lights off+Turn all lights off
 +<​code>​
 $ pilight-control -d Hue1 -s off -v group=0 $ pilight-control -d Hue1 -s off -v group=0
 +</​code>​
  
-Apply scene+Apply scene
 +<​code>​
 $ pilight-control -d Hue1 -s off -v scene=497b50d84-on-0 $ pilight-control -d Hue1 -s off -v scene=497b50d84-on-0
 +</​code>​
  
-** Hints ** +** Hints **\\
 When you configure rules, you should limit the number of requests to be below 10 requests per second for an individual device and below 1 per second for a group. When you configure rules, you should limit the number of requests to be below 10 requests per second for an individual device and below 1 per second for a group.
  
-When you configure conflicting parameters, only one parameter is accepted, the priority is: +When you configure conflicting parameters, only one parameter is accepted, the priority is:\\ 
-- xy beats ct beats hue beats sat.+- xy beats ct, ct beats hue, hue beats sat.
  
 All lights act as a single repeater, if you need to extend your physical range, put a lamp inbetween. All lights act as a single repeater, if you need to extend your physical range, put a lamp inbetween.
  
-Once a light is ON, it stays on, do not sent ON commands repetively, as it slows down the bridge.+Once a light is ON, it stays ON, do not sent ON commands repetively, as it slows down the bridge.
  
  
-** Known Limitations** +** Known Limitations**\\
 The WEBGUI currently supports: ON, OFF, DIM UP/DOWN in 15 steps. The WEBGUI currently supports: ON, OFF, DIM UP/DOWN in 15 steps.
 Color, Scenes etc. do need to be controlled via the CLI interface. Color, Scenes etc. do need to be controlled via the CLI interface.
  
-** Literature ** +** Literature **\\ 
-More information about the Hue system can be found here: +More information about the Hue system can be found here:\\
 http://​www.developers.meethue.com/​documentation/​getting-started http://​www.developers.meethue.com/​documentation/​getting-started
 http://​www.developers.meethue.com/​documentation/​core-concepts http://​www.developers.meethue.com/​documentation/​core-concepts
philipshue.1467897561.txt.gz · Last modified: 2016/07/07 13:19 by wo_rasp