Skip to content

Deep sleep enter : make "until" templatable or add a set_time_until parameter #2532

@sduponch

Description

@sduponch

Describe the problem you have/What new integration you would like

I use an ESP32-S2 to control the power of a battery powered device using Home Assistant and a Calendar to turn off or turn on the device. To minimize consumption, i want to set the ESP32 in deep sleep mode until the start (or the end) of the next event using the internal RTC clock.

Please describe your use case for this integration and alternatives you've tried:

I tried to set the "until" parameter of deep_sleep.enter action using lambda but this parameter is not templatable. I searched to build a DeepSleepEnterAction using lambda code but i could not find any exemple, i saw interesting function like set_until(hh,mm,ss) but did not managed to use it.

Additional context

I saw another merged pull request for adding "deep sleep duration" as parameter of deep_sleep.enter function, maybe we should do something similar for until and time_id "set_until(time_id, hh, mm, ss)"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions