Announcement

Collapse
No announcement yet.

Nap Timer

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Nap Timer

    I am looking for a way to Add a nap timer. I have an event that turns off the the lights and waits for a period of time and then turns it back on. I am looking for a more configurable way to change the wait period without going into the HS. Any Ideas?

    #2
    Perhaps a little more detail may help?

    What sort of interface are you looking at?

    For instance, if you have Z-wave, a Minimote remote with preset times for the buttons could be an option?

    Or do you want this via a Phone/Touchscreen interface like HSTouch?
    Jon

    Comment


      #3
      If you have the original Alexa skill, you can tell HomeSeer to turn off a group of lights for a time period.
      "Alexa, tell HomeSeer to turn off the living room lights for 15 minutes."
      Wade

      "I know nothing... nothing!"

      Comment


        #4
        Well I was thinking HStouch interface, but I think the Alexa idea is pretty good.

        Comment


          #5
          unfortunately it looks like Alexa does not support turning on a device for x period of time

          Comment


            #6
            If you want to play with a script that works very well, here is a snippet of my "Chatter" IP command handler script that uses my IPManager Plugin to receive commands from either a Telnet style input or the app I wrote (way back in Objective-C days) to handle commands and settings for devices, security, message and one of them was to set reminders.

            This will create an event of xxx length (in either minutes or a specific time) and the all the 'timed_reminder.txt' script file does is speak the message "You have asked me to remind you at this time".

            So you can create any event you would like (like to re-kickofff your alarm, etc) and there are even commands to cancel a reminder, list/show a list of reminders, etc.

            For parameters, I just call is (as I made it telnet friendly) as "Remind me in 20 minutes" or "Remind me at 2PM"

            Feel free to bast_--dize it as much as you would like!
            Or just PM me and we can work out a time to chat about what you would like to do.

            g

            Code:
            ****
            case "remind" ' Access and set a reminder for later
            ecm = trim(mid(data,len(cmd)+len(subcommand)+2)) ' GP's reminder system. Ask if you want it as well
            
            select case subcommand
                case "me" ' format is Remind me in/at xxx mins/hours or Time
                   if lcase(hs.stringitem(ecm,1," ")) = "at" then ' Remind 'at' a specific time?
                      timein = hs.stringitem(ecm,2," ")
                      ampm = ucase(hs.stringitem(ecm,3," "))
                   if ampm <> "AM" and ampm <> "PM" then ampm = "PM"
                      MyTime = TimeValue(timein & " " & ampm) ' a properly formatted time less date
                      numb = DateDiff("n",Time,MyTime) ' whats the difference in minutes from now?
                   if numb < 1 then reply "Cannot set reminder to less than current time today" : exit function
                      rc = hs.runex ("timed_reminder.txt", "timed_reminder", numb & ",minutes")
                      reply rc
                  else
                     numb = hs.stringitem(ecm,2," ") ' The number of minutes/hours from how
                     intr = hs.stringitem(ecm,3," ") ' the word minutes or hours
                     rc = hs.runex ("timed_reminder.txt", "timed_reminder", numb & "," & intr)
                 reply rc
                 end if
            
                case "cancel"
                    hs.RemoveDelayedEvent "","Issue Voice Reminder" ' Clear out any pending voice reminders
                    reply "All queued reminders have been removed"
            
                case "list", "show"
                    tcp.queueonsocket socketname, "event list *delayed" ' do a fancy recursive call to let the event command process
            
                case else
                    reply "Error: Valid remind commands are 'me in xxx min/hours, me at xx:xx AM/PM, Cancel, List'"
            end select

            Comment

            Working...
            X