binoda
September 20, 2021, 8:37am
1
Hi!
I use the generic thermostat integration to automate some per-room heating things. However, on top of a simple home and away preset, I’d like some more detailed scheduling.
For example, the bathroom can remain cool for most of the day and only warm up a bit in the evening when we usually shower. A simple home/away preset won’t quite cut it for that.
Right now, I have several automations setup to switch the target temperature around at given times. I’ve also used the popular scheduler component (https://github.com/nielsfaber/scheduler-component ) but still I don’t think the experience is great.
What I’d like is for the generic thermostat integration to include some scheduling natively. Personally, I’d love the following features:
Set target temperature per time block so I can have different temperatures during the day
Set an entity (switch, boolean, group, ?) to watch for home state and automatically switch to away mode when it is false/away/off
Thanks
tom_l
September 20, 2021, 8:48am
2
There are quite a few third party schedulers that can do more than just adjust your thermostat.
This is one of the better ones:
Scheduler integration for HA
Introduction
In my house I have quite some devices that I want to control based on the time and day. For a while I have been looking for an easy way to set up and manage the automations that control them. HA has lots of functionality, but some things (such as automations), are not as simple to use as I would like. So, I decided to create my own scheduler integration. With a mobile-friendly Lovelace card for managing it.
What is the scheduler integra…
1 Like
nilux
September 20, 2021, 9:39am
3
Something as simple to configure as:
device: climate.hvac1
schedule:
- '07:00': 22C
- '08:00': 21C
- '21:00': 20C
- '22:00': 18C
4 Likes
Hello @nilux ,
where did you add this entry?
best regards
tom_l
August 15, 2022, 3:09pm
5
He did not. It was a suggestion for how the feature request could be implemented.
While not specific to the thermostat, there is a PR in the works for a schedule helper.
home-assistant:dev
← home-assistant:frenck-2022-1644
opened 07:43PM - 10 Aug 22 UTC
<!--
You are amazing! Thanks for contributing to our project!
Please, DO N… OT DELETE ANY TEXT from this template! (unless instructed).
-->
## Proposed change
<!--
Describe the big picture of your changes here to communicate to the
maintainers why we should accept this pull request. If it fixes a bug
or resolves a feature request, be sure to link to that issue in the
additional information section.
-->
Adds the schedule integration to Home Assistant.
The schedule integration is a helper integration that allows for creating weekly schedules for use in, for example, automations & scripts.
The reason it is a weekly schedule is that we think this will cover most use cases. When in need of a daily schedule, this integration can still be used. When in need of more complex or longer schedules, the use of a calendar integration might be a better fit.
This first iteration brings in support for the basic integration first and provides a collection that supports both YAML and UI configuration (Frontend part needs to be built at this point).
Example YAML configuration:
```yaml
schedule:
party:
name: "Party time"
icon: "mdi:party-popper"
friday:
- from: "20:00"
to: "23:00"
saturday:
- from: "20:00"
to: "23:00"
```
Possible future extensions/ideas, currently out of scope:
- A dedicated trigger for ease of use in automations.
- A dedicated condition for ease of use in automations and scripts.
- The use of templates in schemas, time ranges, or times.
- The use of referencing other entities providing a time (e.g., a `sun` entity, `input_datetime` or any other entity providing a time that can be used.
- Variables to set on time ranges, make them available in automations when triggering.
Those are top-of-mind things, but not for now, maybe later. Let's make this works nicely first.
This PR is a replacement of #41385, which didn't get adjusted to the review/requirements set by the core dev team.
## Type of change
<!--
What type of change does your PR introduce to Home Assistant?
NOTE: Please, check only 1! box!
If your PR requires multiple boxes to be checked, you'll most likely need to
split it into multiple PRs. This makes things easier and faster to code review.
-->
- [ ] Dependency upgrade
- [ ] Bugfix (non-breaking change which fixes an issue)
- [x] New integration (thank you!)
- [ ] New feature (which adds functionality to an existing integration)
- [ ] Deprecation (breaking change to happen in the future)
- [ ] Breaking change (fix/feature causing existing functionality to break)
- [ ] Code quality improvements to existing code or addition of tests
## Additional information
<!--
Details are important, and help maintainers processing your PR.
Please be sure to fill out additional details, if applicable.
-->
- This PR fixes or closes issue: fixes
- This PR is related to issue:
- Link to documentation pull request: https://github.com/home-assistant/home-assistant.io/pull/23721
- Link to brands pull request: https://github.com/home-assistant/brands/pull/3579
## Checklist
<!--
Put an `x` in the boxes that apply. You can also fill these out after
creating the PR. If you're unsure about any of them, don't hesitate to ask.
We're here to help! This is simply a reminder of what we are going to look
for before merging your code.
-->
- [x] The code change is tested and works locally.
- [x] Local tests pass. **Your PR cannot be merged unless tests pass**
- [x] There is no commented out code in this PR.
- [x] I have followed the [development checklist][dev-checklist]
- [x] The code has been formatted using Black (`black --fast homeassistant tests`)
- [x] Tests have been added to verify that the new code works.
If user exposed functionality or configuration variables are added/changed:
- [ ] Documentation added/updated for [www.home-assistant.io][docs-repository]
If the code communicates with devices, web services, or third-party tools:
- [x] The [manifest file][manifest-docs] has all fields filled out correctly.
Updated and included derived files by running: `python3 -m script.hassfest`.
- [x] New or updated dependencies have been added to `requirements_all.txt`.
Updated by running `python3 -m script.gen_requirements_all`.
- [ ] For the updated dependencies - a link to the changelog, or at minimum a diff between library versions is added to the PR description.
- [x] Untested files have been added to `.coveragerc`.
The integration reached or maintains the following [Integration Quality Scale][quality-scale]:
<!--
The Integration Quality Scale scores an integration on the code quality
and user experience. Each level of the quality scale consists of a list
of requirements. We highly recommend getting your integration scored!
-->
- [x] No score or internal
- [ ] 🥈 Silver
- [ ] 🥇 Gold
- [ ] 🏆 Platinum
<!--
This project is very active and we have a high turnover of pull requests.
Unfortunately, the number of incoming pull requests is higher than what our
reviewers can review and merge so there is a long backlog of pull requests
waiting for review. You can help here!
By reviewing another pull request, you will help raise the code quality of
that pull request and the final review will be faster. This way the general
pace of pull request reviews will go up and your wait time will go down.
When picking a pull request to review, try to choose one that hasn't yet
been reviewed.
Thanks for helping out!
-->
To help with the load of incoming pull requests:
- [x] I have reviewed two other [open pull requests][prs] in this repository.
[prs]: https://github.com/home-assistant/core/pulls?q=is%3Aopen+is%3Apr+-author%3A%40me+-draft%3Atrue+-label%3Awaiting-for-upstream+sort%3Acreated-desc+review%3Anone+-status%3Afailure
<!--
Thank you for contributing <3
Below, some useful links you could explore:
-->
[dev-checklist]: https://developers.home-assistant.io/docs/en/development_checklist.html
[manifest-docs]: https://developers.home-assistant.io/docs/en/creating_integration_manifest.html
[quality-scale]: https://developers.home-assistant.io/docs/en/next/integration_quality_scale_index.html
[docs-repository]: https://github.com/home-assistant/home-assistant.io
You could easily automate your thermostat using this.