Skip to content

Considerations of a Schedule for Preset states (of a Thermostat, Select entity) #3

@vincedarley

Description

@vincedarley

Just came across this repository - looks really good - perhaps just what I've been thinking about for some time! Can I check on a few things with you before I dive in:

  1. My primary use-case is not for switches/buttons, but for things that can have multiple states: an esphome thermostat has "home", "away", "sleep", "eco" states for example (I prefer to control my home with such preset states, which trigger a specific temperature rather than directly via temperatures). A select entity similarly:
select:
  - platform: template
    name: "Master Bedroom Preset"
    id: preset_first_master_bedroom
    optimistic: true
    options:
      - "Home"
      - "Eco"
      - "Vacation"
    initial_option: "Home"
    ...

I'm hoping that it would not be too much work for me to extend your code to handle this? Any feedback, guidance, pitfalls I should be aware of? This seems similar to your "switch-thermostat-control.yaml" but where there is fixed set of discrete options rather than "temperature values".

For the example above, I assume I'd need to create a "select" platform component similar to your "switch" one? I'm not so interested in turning something on/off on a schedule, but rather just selecting the preset.

  1. I'm slightly confused about the esphome <-> homeassistant synchronisation/etc. If I understand correctly "schedule" helpers that you create in home assistant purely define a schedule of on/off and arbitrary associated data. But they do NOT actually change the state of a switch, or button (or 'select' in my case) themselves. HA schedule helpers require you to create an automation, triggered by the helper, to make the actual change. FWIW, this has always seemed a weird limitation of HA to me.

However, when I read your code and examples, it seems (and this is a good thing) that these esphome schedules can and do modify the state of the switch, via the "on_turn_on" and "on_turn_off" sections, for example.

Am I correct in saying that: (a) the times of day, days of week etc of the schedule, and indeed the additional data, can be edited in Home Assistant's UI. But the esphome coded actions cannot (because HA doesn't even support that concept). Is that correct? (This sounds good for my uses at least).

  1. Lastly, if using the "webserver:" WebUI to esphome, how do these schedules appear? Can you usefully interact with them in that?

Thanks again...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions