Commit Graph

99 Commits (f4f06af0c597d172942c5a42a9a7e3b1e9370778)

Author SHA1 Message Date
Anders Melchiorsen 64a7be66b1 Remove global limit on white light temperature (#7206)
* Remove global limit on white light temperature

Here are the supported temperatures of some popular bulbs:

 Philips Hue: 2000K-6500K (the current 500-154 mired range)
 LIFX Color 1000: 2500K-9000K
 IKEA TRÅDFRI: 2200K, 2700K, 4000K

Obviously, Home Assistant cannot enforce a global limit and work properly
with all of these bulbs. So just remove the limit and leave it up to each
platform to work it out.

This commit updates the existing users and adds a clamp to Hue (where the
limit appears to have originated). It does not attempt to update other
platforms that might need extra handling of the larger range that is now
possible.

* Add min_mireds/max_mireds state attributes to lights

* Support min_mireds/max_mireds with LIFX lights
2017-04-29 15:04:20 -07:00
Paulus Schoutsen e265401cd0 self.loop.create_task -> self.add_job (#6632)
* self.loop.create_task -> self.add_job

* Core to use create task
2017-03-16 06:58:54 +01:00
Anders Melchiorsen b9cf4df557 Increase upper limit on light transitions (#2843)
This increases the global limit to 6535 seconds (1h48m55s) because that is
supported by all light platforms.

Some platforms support even longer transition times so the limit should
actually be platform specific.
2017-03-09 23:59:35 +01:00
Nate d5bdf7783e light.transition now supports float instead of int in order to be able to perform faster transitions (#6163) 2017-02-26 21:21:12 -08:00
Pascal Vizeli 106b7a9d8f Cleanup run_callback_threadsafe (#6187)
* Cleanup run_callback_threadsafe

* fix spell

* Revert image_processing, they need to wait for update
2017-02-23 12:57:25 -08:00
Johann Kellerman fdc373f27e Restore_state helper to restore entity states from the DB on startup (#4614)
* Restore states

* feedback

* Remove component move into recorder

* space

* helper

* Address my own comments

* Improve test coverage

* Add test for light restore state
2017-02-20 23:40:27 -08:00
Adam Mills ecfe8e0a9a Formalize supported_features as entity property (#5794)
* Formalize supported_features as entity property

* Remove extra emulated_hue conditions

* Generate log message in executor
2017-02-07 20:42:45 -08:00
Pascal Vizeli 1719d88602 Bugfix default values to timedelta (#5193)
* Bugfix default values to timedelta

* fix unittests
2017-01-06 00:16:12 +01:00
Pascal Vizeli 9a16054867 Bugfix create a task from a task in component update (#5033) 2016-12-21 15:11:14 +01:00
Paulus Schoutsen 98fe50d5ad Update after service calls (#4795)
* Update after service calls

* Service update: wrap async_update in create_task
2016-12-06 22:30:47 -08:00
lichtteil 279f82acc4 Mutate values for light color temperature and white value (#4660)
* Mutate values for light color temperature and white value

* Fix lenght of line

* Fix under-indented line

* Fix cgl
2016-12-01 18:26:53 -08:00
Pascal Vizeli bde7176b3c Migrate light component to async (#4635) 2016-11-30 13:33:38 -08:00
Antoine Bertin f0db698f75 Light effects (#4538)
* Add support for light effects

* Move PLATFORM_SCHEMA changes in light to mqtt_template

* Add effect validation

* Add unittests

* Add light effect to demo and unittests

* Use cv.string for config validation

* Use cv.ensure_list for config validation

* Fix typo

* Remove unused exception management for effect
2016-11-27 17:15:28 -08:00
Paulus Schoutsen 62785c2431 More async tests (#4223)
* Annotate test callbacks to be async

* Convert device_sun_light_trigger to be async
2016-11-05 16:36:20 -07:00
Paulus Schoutsen ee5f228309 Make services yield (#4187)
* Make services yield

* Disable pylint abstract-method check

* add input_select

* add input_slider

* change to async vers.

* fix lint

* yield on add_entities as other components does
2016-11-03 18:32:14 -07:00
Fabian Affolter be272ac64a Disable too-many-* (#4107)
* Disable too-many-* and too-few-public-methods

* Remove globally disabled pylint warnings
2016-10-30 22:18:53 +01:00
Jeff Wilson d55ed7a3a2 Flux switch improvements (#3615)
* Make flux always adjust brightness of light (even when not in XY mode)

* Remove kelvin mode from flux switch

The light/turn_on service only works with mired values, kelvin values
are out of range per the schema.

* Use already defined min/max values for light/turn_on schema

* Clamp temp value to light/turn_on allowed values
2016-10-01 22:57:15 -07:00
Marc Pabst 138205a019 Adding support for a white value (#3338)
* Update __init__.py

addedattribute "WHITE_VALUE" to improve support for RGBW devices

* Update services.yaml

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

* Update __init__.py

shortened line

* Update __init__.py

* Update __init__.py

* Add mysensors RGBW and light tests

* Activate support for mysensors RGBW devices with support for
	white_value attribute.
* Add white_value support in light demo platform.
* Add tests for white_value and more for light component.
* Add tests for light demo platform.
* Fix import order in check_config.
2016-09-20 21:26:40 -07:00
Robbie Trencheny 0f37d8d8eb Using alert with Hue maintains prior state (#3147)
* When using flash with hue, dont change the on/off state of the light so that it will naturally return to its previous state once flash is complete

* ATTR_FLASH not ATTR_EFFECT
2016-09-04 03:04:12 -07:00
Assaf Inbal 72ad1d8d7c Added support for exposing light features (#2828) 2016-08-15 23:07:07 -07:00
Keaton Taylor 2189516966 Clamp brightness between 0 and 255 (#2494)
* Clamp brightness between 0 and 255

Change to ensure that values over 255 supplied by the config will be
clamed to a max value of 255.

* Revert "Clamp brightness between 0 and 255"

This reverts commit c87238e8b5.

* Clamp brightness between 0 and 255

Change to ensure that values over 255 supplied by the config will be
clamed to a max value of 255.
2016-07-11 12:39:46 -07:00
Paulus Schoutsen 68df3deee0 ABC consistent not implemented behavior (#2359) 2016-06-24 21:27:40 -07:00
Paulus Schoutsen 30f74bb3ca Migrate to generic discovery method (#2271)
* Migrate to generic discovery method

* Add tests for discovery
2016-06-11 17:43:13 -07:00
Robbie Trencheny a431277de1 Accept human readable color names to change light colors (#2075)
* Add support for providing color_name which accepts a CSS3 valid, human readable string such as red or blue

* Forgot the schema validation!

* ugh farcy

* use html5_parse_legacy_color for more input options

* Add webcolors==1.5 to setup.py

* Block pylint no-member errors on tuple

* add color_name_to_rgb test

* whoops

* revert changes to individual platforms

* If color_name is set, pop it off params and set rgb_color with it

* Forgot to reset wink.py

* Import the legacy function as color_name_to_rgb directly

* reset test_color.py

* Improve light services.yaml
2016-05-17 00:06:55 -07:00
Jan Harkes 7a25ae3e2c Fix for light service validation. (#1770)
Incorrect validation tested if passed value was a list instead of
a member of the list.
2016-04-09 09:07:13 -07:00
Jan Harkes 6d914126fa Validate data read from light_profiles.csv 2016-03-31 23:29:07 -04:00
Jan Harkes 4f3dc2ce8b Coerce RGB and XY color values to tuples instead of lists. 2016-03-31 22:59:18 -04:00
Jan Harkes 017f47dd2c Service validation for light.turn_on/.turn_off/.toggle 2016-03-31 22:03:38 -04:00
Paulus Schoutsen 5baa98b79f Add initial config validation 2016-03-28 23:46:12 -07:00
Paulus Schoutsen 557dae7ab3 Fix typo in light docs 2016-03-19 19:44:20 -07:00
pavoni 9fc73fa644 Refactor vera into a platform. 2016-03-16 09:03:56 +00:00
Stefan Jonasson eb9ed5ccfe Rewrite of the tellstick module. It now uses a common base for all shared functionality.
The rewrite addresses a problem with the tellstick hardware dropping
commands when too many simultaneous calls is being made from HA. Also fixes a bug when the dim level was changed externally.
This breaks previous configurations.

The new config for tellstick is

```yaml
tellstick:
  signal_repetitions: X
```
Lights and Switches are detected automatically.
Sensors work like before because they do not share any functionality with the other devices and they also needs a complete other configuration.
2016-03-13 19:28:42 +01:00
Fabian Affolter 7e8e91ef3c Fix PEP257 issues 2016-03-07 22:08:21 +01:00
Jan Harkes afe564fb3f Move WeMo discovery into a common component 2016-02-21 22:23:00 -05:00
MartinHjelmare 2cf061c768 Add mysensors light platform
* Make light controllable independently with types V_LIGHT, V_DIMMER,
    V_RGB and V_RGBW. V_RGBW is not implemented in the frontend yet.
* Add discovery for light platform.
* Add optimistic mode config setting for switch and light
    to allow feedback state from actuator.
* Move S_LIGHT, V_LIGHT, V_STATUS types from switch to light platform.
* Change node update logging to debug from info level.
* Fix some inaccurate comments.
2016-02-12 01:22:35 +01:00
Paulus Schoutsen f08b77dc4c Clean up state_attributes vs device_state_attributes 2016-02-06 22:34:24 -08:00
Harald Nagel 86f433067c Fix #1046 by correcting platform name 2016-01-30 06:05:09 +00:00
Paulus Schoutsen cbc6323438 Fix imports 2016-01-28 21:45:26 -08:00
Dean d59b98ee2b Added Insteon Support 2016-01-22 02:28:36 -05:00
Ryan Kraus 342a819fd4 Added toggle service
Added a toggle service to the homeassistant, light, switch, and
media_player domains.
2016-01-16 10:45:05 -05:00
richard 5c7fb5d7ae Fix styling issues 2015-12-24 21:35:36 -06:00
richard 0dfc1c4e7a Add functionality set random color Philips Hue 2015-12-24 21:10:27 -06:00
Paulus Schoutsen fabd0ced3f Make DEPENDENCIES optional for components 2015-11-26 13:11:59 -08:00
Paulus Schoutsen 50d19bb1b4 Merge pull request #592 from leoc/feature-zwave-lights
Implement zwave light support
2015-11-11 00:11:51 -08:00
Fabian Affolter 97f9f8aa49 Update link to docs (Jekyll 3 update) 2015-11-09 13:12:18 +01:00
Arthur Andersen 84f81480bb [Zwave] Add light zwave component 2015-11-07 15:58:28 +01:00
Paulus Schoutsen 95320f39b3 Light: base color now in RGB instead of XY 2015-11-07 01:25:33 -08:00
happyleaves 4d958c6d18 style fix 2015-11-02 18:08:17 -05:00
happyleaves 3cd89f8474 add disco, white effects 2015-11-02 18:08:17 -05:00
Tom Duijf b76471c4b3 :( .. pyliny 2015-10-30 19:15:38 +00:00