Automatic smart light brightness and color based on the sun

Поділитися
Вставка
  • Опубліковано 12 січ 2025

КОМЕНТАРІ • 80

  • @FrankyB295
    @FrankyB295 2 роки тому +11

    There is an Adaptive Lighting Integration that works very well. Easy to set up.

    • @theattorney6072
      @theattorney6072 Рік тому +4

      Just tried the adaptive lighting integration, and the Issue is that the previous setting is loaded first, so at night it is not usable for me, you are first blinded, then the light sets to lower brightness.

    • @DennisSchmitz
      @DennisSchmitz 9 місяців тому +1

      @@theattorney6072 fixed in a recent version. It just keeps adapting, even if the lights are off (not via hardware switch of course).

  • @PierreLeroy76620
    @PierreLeroy76620 2 роки тому +1

    Haven't looked the video yet but I was looking for this for a long time ! Thank you !

  • @phil-jc8hp
    @phil-jc8hp 2 роки тому +30

    Any reason you are not using the "Adaptive Lighting" integration? Does exactly what you are trying to do, just a lot more user friendly to setup

    • @Sparky_D
      @Sparky_D 2 роки тому +7

      Exactly what I was thinking within seconds of starting this video. Adaptive Lighting was a fork of Circadian Lighting, with a HEAP of improvements.

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому +18

      Nope - I'd never heard of it until now 😂. Guess I should take a look at it!

    • @BrianRoy86
      @BrianRoy86 2 роки тому +1

      @@HomeAutomationGuy it’s the updated version of circadian lighting.

    • @AlonsoVPR
      @AlonsoVPR 2 роки тому +1

      @@HomeAutomationGuy Please! do a video after testing that integration :D

    • @igiannakas
      @igiannakas 2 роки тому +1

      Same here. Was wondering why the adaptive lighting integration was not used, as it’s much easier to setup and works actually quite a bit better than the above.

  • @SergioBlackDolphin
    @SergioBlackDolphin 9 місяців тому

    What a great automation. I added it to my home and it makes everything so much easier. It works even with the porch light and across our home we don’t have to worry about choosing the right combination. Each time. 😊

  • @suzithewitch
    @suzithewitch 2 роки тому

    I'm using SmartThings for now, but I'm supposed to get my Home Assistant Yellow in January. I'm saving many of your videos for use for then, but what I love is when I can use the same ideas in SmartThings, now. For example, your light notification of your laundry status really helped me make mine work, and while I can't use HACS, I can use color templates based on the time of day and set them up for my system to use. Thank you!

  • @man4evil
    @man4evil 2 роки тому +1

    For years I used 222 temp everywhere. Boy I was shocked what a difference 300 temp does in the morning on a room with closed curtains. Thanks 😊

    • @chazM6116
      @chazM6116 Рік тому

      light is measured in Kelvin, Colour temperature generally ranges from 2700-3300K (warm) to 3300-5300 (cool) - and 6500K is daylight.

    • @man4evil
      @man4evil Рік тому

      ​@@chazM6116 thats cool, but lightbulbs in HA have different scale

    • @chazM6116
      @chazM6116 Рік тому

      @@man4evil light is light no matter its source.

    • @man4evil
      @man4evil Рік тому

      @@chazM6116 so? you probably can set all lightbulbs to same calvin, will they glow the same color for different vendors? I doubt that. I have 3 sets of different models of Xiaomi e27 lightbulbs in chandeliers and its colors is different. need to replace bunch of inconsistent lights :(

  • @WPGinfo
    @WPGinfo 2 роки тому

    marvelous! This is the aspect of my HA-setup I am not quite content with. This video, I'm sure, will help me 'fix' that! So thanks for sharing!

  • @EsotericArctos
    @EsotericArctos 2 роки тому +1

    The template sensor is a great idea, but Home Assistant can also do a lot of this with Action Condtions in the Automation instead of needing to create additional sensors. I stopped using set times for a lot of my light automations. Instead I started using the sun elevation. Not perfect still, but it eliminated some of the restrictions of time based automations.
    One of the great things about Home Assistant. There are many different ways to do the same thing. It can be complex, or simple :).

    • @kmaid
      @kmaid Рік тому +1

      I think using a template sensor is better programming practice. It allows you to reuse these values in different automations so there is only one place to tweak. It also separates concerns

  • @andymok7945
    @andymok7945 2 роки тому

    Great ideas. I have been using HA for a few years now and template is on the learning list for me. Your example for lighting was a really good example and will bump up the ranking to learn about templates higher on the list.

  • @TheMoonSeesMe
    @TheMoonSeesMe 2 роки тому

    That's sweet. The other thing that I have done is to have different lighting based on whether my night time alarm [external doors are opened] is on or off. If it's on then the lighting is really subdued because everyone is [or should be] asleep. And if the night time alarm isn't on then the lighting is a bit brighter because people are probably still up.

  • @cyberdave17
    @cyberdave17 2 роки тому

    I like your automation for hall lighting, I do similar with the kitchen and counter lights, as over night or late evening I'm normally just putting the kettle on or need a glass of water so the counter light strips are ideal

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому

      After a few days you stop noticing it, which means it's a perfect automation 😊

    • @cyberdave17
      @cyberdave17 2 роки тому

      @@HomeAutomationGuy it will be after my fp1 arrives to stop lights turning off when standing still by the oven cooking. Didn't want to extend the cool down to 10 mins and couldn't figure out code to start the cooldown at 1 min, and increase it the longer someone is in the room upto a limit.

  • @bat3332
    @bat3332 2 роки тому

    Thank you for the blog.

  • @wimderaat2993
    @wimderaat2993 2 роки тому

    Very interesting video. I already liked you automatic lighting before this, but this is even better. Winter in the Netherlands can be pretty dark too. I have to change some things around here. Perfect excuse to play with home automation.

  • @netblue
    @netblue 2 роки тому +1

    As usual a another great video we can inspire from. I am not as skilled with coding so I did this the long way around by creating a "Daytime" toggle helper that flips based on sunset / sunrise . Will definitely look into the circadian integration, though I try to stay away from cluttering the configuration.yaml file as it is terrible to read if long.

  • @hmonkey1
    @hmonkey1 2 роки тому

    I have something similar but I set the scene to all the lights on the sun height. That way it works all year round. Time isn't a reliable way to do it in my finding. I do this by having a template that tracks what scene the lights should follow. This also means I can get the scene to change on all the lights when the template changes not just when the light is turned on.

  • @Yama_1291
    @Yama_1291 2 роки тому

    You could also do this with scenes and a time of day sensor.

  • @iAmTheSquidThing
    @iAmTheSquidThing 2 роки тому

    Apparently people also prefer warmer lighting when the weather is colder, and colder lighting when the weather is warmer. So that might be something interesting to add.

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому +1

      I think I prefer that too, but only just realised 🤣
      Thanks for the suggestion

  • @fearthesmeag
    @fearthesmeag Рік тому +1

    Alan, awesome video. Im currently using Adaptive Lighting, which looks very similar to circadian lighting. However, can I use an automation (sensor) with the AL integration? Otherwise AL keeps the lights On.

    • @DennisSchmitz
      @DennisSchmitz 9 місяців тому

      Works fine here with automations using either light or motion/presence sensors. Just make sure to use the Adaptive Lighting 'apply' service to turn on the lights while applying the right color at the same time. With the regular light or device service lights often forgot to change to the right color.

  • @milicsantiago
    @milicsantiago 2 роки тому +1

    Great stuff. Are you using docket version?

  • @Jessicab-u7c
    @Jessicab-u7c 6 місяців тому

    Tonight is my first night trying sunset lights to help my sleep.

  • @deansproductions
    @deansproductions 2 роки тому

    Surely the times should be based off the sunrise/sunset .. what happens in winter etc?

  • @GagliardiPhotography
    @GagliardiPhotography Рік тому

    Another great video! Just a question: I need multiple IFs in my case, as I need different light conditions during the day. I tried to define a new sensor like this, but I got a syntax error, what is the right syntax?
    light_color:
    friendly_name: 'Light Color'
    value_template: >
    {% if (now().hour >= 23) or (now().hour < 6) %}
    red
    {% elseif (now().hour >= 6) and (now().hour < 10) %}
    yellow
    {% elseif (now().hour >= 10) and (now().hour < 15) %}
    green
    {% elseif (now().hour >= 15) and (now().hour < 20) %}
    blue
    {% else %}
    orange
    {% endif %}

  • @chrismills5470
    @chrismills5470 2 роки тому

    If I start using the circadian lighting plug in do i still need the colour temp sensor or am I correct in thinking this would remove the need for it?

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому +1

      The circadian plugin should do it. I've recently been using a new integration called Adaptive Lighting, which seems more powerful and supported. I'd suggest checking that out instead!

  • @kancharisaibhanuprasadchar4424
    @kancharisaibhanuprasadchar4424 2 місяці тому

    Can I have this Technology. My Project is similar to this project sir . Can I know brief description about this

  • @cyberdave17
    @cyberdave17 2 роки тому

    Anyone know how to tweak Adaptive Lighting so that it instantly changes to the right colour temperature after switching the bulb on? Mine normally changes around 20s later which can be a bit jarring if you last had the light on in the day, then switch on at night.

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому +1

      There's an "initial transition" setting when you press configure that is supposed to take care of that

  • @luisinigo5572
    @luisinigo5572 2 роки тому +1

    Great video!
    You can also use elevation and azimuth atributes of Sun entity insted of Sun state.
    I use to used them for open or close blinds, before install a illuminance sensor..
    Saludos.

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому

      Thanks for sharing Luis! I unfortunately am not smart enough to understand how those things really work....

    • @luisinigo5572
      @luisinigo5572 2 роки тому

      @@HomeAutomationGuy
      Easy peasy!
      Elevation is how high from horizon is the sun, in degrees. Minor than 0° is below horizon, 90° is over our heads.
      Azimuth is the horizontal position. 0° is north, 90° is east, etc.
      :-)

  • @EvolverDX
    @EvolverDX 2 роки тому

    Thought you were using Home Assistant as a docker container. How did you integrate HACS in your container?

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому

      The installation method is pretty similar for HA OS and container.

    • @EvolverDX
      @EvolverDX 2 роки тому

      @@HomeAutomationGuy you are right. I just integrated HACS in my container a few days ago and it works like a charm.

  • @chazM6116
    @chazM6116 Рік тому

    Not very 'Green' everything is on 24/7 :( Lights on in the day??? Do you have no windows? very rear do I put lights on in the day apart from the cloakroom with no windows

    • @HomeAutomationGuy
      @HomeAutomationGuy  Рік тому

      I live in the UK. Windows don't really make much difference in the winter.

    • @chazM6116
      @chazM6116 Рік тому

      @@HomeAutomationGuy lol I live in UK so unless you're in a 300yr old cottage as I lived in some 15yr ago :)

  • @sam5992
    @sam5992 Рік тому

    I always imagined a system that mimicked the brightness and color temperature of the outside suing a suite of photo sensors measuring color temp/brightness/cloudy conditions, with a manual override, of course.

  • @joeblstrn
    @joeblstrn Рік тому

    can this be done without coding?

    • @HomeAutomationGuy
      @HomeAutomationGuy  Рік тому +1

      Try an integration called Adaptive Lighting. It does a lot of this

  • @jfkgodk
    @jfkgodk 2 роки тому

    Is there a way to make this work in Sweden? I mean, the sun is up all night in the summer. We don't want bright light indoors in the middle of the night. In the winter it is the opposite, the sun isn't up much. We need bright light then.

    • @wimderaat2993
      @wimderaat2993 2 роки тому

      Very interesting problem indeed. The sun entity has some State Attributes like elevation angle and if the sun is rising or not. Have you ever looked at that ? Of course this can also be combined with the time and light sensors. I live in the Netherlands and I also want my lighting to change with the seasons. It is not as extreme as is Sweden, but is still pretty dark in winter over here. So I also want very bright light in the morning and the afternoon in winter to mimic the sun.

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому

      There are a lot of variables to play with including offsets and min/max brightness. But in these cases I'd probably go manual with the template sensors and pick what works best for you, your location and your routine

    • @iAmTheSquidThing
      @iAmTheSquidThing 2 роки тому

      I guess just use the settings for somewhere on the same longitude but nearer the equator. Like Poland or Croatia.

  • @axel9546
    @axel9546 2 роки тому

    What about PWM flickering?

    • @HomeAutomationGuy
      @HomeAutomationGuy  2 роки тому

      I'm not sure what that is, but I've not noticed any flickering with my Hue lights

  • @davidc4162
    @davidc4162 Рік тому

    I'm only halfway in buuut this really seems like a reinvention of Adaptive Lighting... with the difference that this is time-based rather than position of the sun.

    • @HomeAutomationGuy
      @HomeAutomationGuy  Рік тому +1

      Yep, I think Adaptive Lighting is the newer version of this.

  • @Guygizbon-1
    @Guygizbon-1 2 роки тому +1

    love it very Monty python😆

  • @BasNij
    @BasNij Рік тому

    Great video! I linked it in a new section "See also" in Adaptive-Lighting's README.