• Zikeji
      link
      fedilink
      English
      arrow-up
      5
      ·
      edit-2
      3 days ago

      Take it a step further with Tasker and your sleep tracking app. Lights go off when I start sleep tracking, lights come on with alarm.

      • nodiratime@lemmy.world
        link
        fedilink
        arrow-up
        2
        ·
        edit-2
        3 days ago

        You can do that in HA no problem. No need for proprietary stuff (tasker has really lost it’s charm).

        • Zikeji
          link
          fedilink
          English
          arrow-up
          2
          ·
          3 days ago

          HO? Do you mean HA or something else I’m unfamiliar with? I didn’t see any option in the companion app or when creating and automation to trigger based on an Android intent.

          The only thing I see is the sleep confidence and sleep segment sensors which while useful aren’t useful for this purpose.

          • nodiratime@lemmy.world
            link
            fedilink
            arrow-up
            2
            ·
            3 days ago

            Sorry, I meant HA. I just recently set this up, it’s not 100% the same, but very, very similar. I have some wake up system, and when I go to bed, I scan a ncf Tag (just hold the unlocked phone next to it). There is an android next alarm sensor in the companion app, and when this changes (under time conditions), the next alarm is set in HA. The Tag kills all lighting and sets the alarm (which was set earlier) to active, triggering the wake up system some time before the next alarm is set to go off. Of course, the Tag trigger can also be paired to a button (or to its secondary “mode”), but for now I let my (bed) button to the normal sleep/lights off everywhere more without the alarm, to be able to make a choice.

            • djdarren@piefed.social
              link
              fedilink
              English
              arrow-up
              1
              ·
              2 days ago

              Meanwhile, I just have a big button on my Home Assistant home screen on my phone that turns off all my lights. It’s great.

            • Zikeji
              link
              fedilink
              English
              arrow-up
              2
              ·
              2 days ago

              I don’t consider that similar.

              My current workflow I use the Sleep as Android app, I click “Start sleep tracking” and the lights go off (+ other stuff). When the app wakes me up the lights come on. The app has support for Tasker’s plugin system, which makes it easily possible. I could use Automate, another proprietary app, but prefer Tasker thanks to the support I received from the dev (in fact I’ve received good support from both Sleep and Tasker).

              If I was to switch to a physical setup that required an NFC tag, I’d probably still use Tasker to initiate sleep tracking in Sleep as Android.

              • fif-t@fedia.io
                link
                fedilink
                arrow-up
                2
                ·
                2 days ago

                You can also just use the webhooks system in Sleep as Android and make a webhook receiver for it in home assistant, which is what I do

                • Zikeji
                  link
                  fedilink
                  English
                  arrow-up
                  1
                  ·
                  2 days ago

                  Damn that’s new since I was messed with this. They even have MQTT! Thanks for pointing that out. I’ll have to switch over lol.

      • RogueBanana@piefed.zip
        link
        fedilink
        English
        arrow-up
        6
        ·
        3 days ago

        Setting up home assistant from the bed is not very ideal. Sit straight up in a chair, set it up then go to bed.