Announcement

Collapse
No announcement yet.

Script to turn on/off insteon device

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

    Script to turn on/off insteon device

    I have done a few scripts and turning x10 devices on and off is a cinch, but what command do you use to turn insteon devices on and off?

    #2
    Same commands work for both.
    💁‍♂️ Support & Customer Service 🙋‍♂️ Sales Questions 🛒 Shop HomeSeer Products

    Comment


      #3
      Originally posted by Rupp View Post
      Same commands work for both.
      Ah ok, but with X10 commands you specify the device id A1, B9 etc. What do you specify for Insteon?

      Comment


        #4
        What's the device code for your Insidious light switch?

        Check SetDeviceStatus in the HomeSeer Help.


        ~Bill

        Comment


          #5
          Originally posted by Bill Brower View Post
          What's the device code for your Insidious light switch?

          Check SetDeviceStatus in the HomeSeer Help.
          I am not sure how to answer this, Insteon switches are not assigned X10 codes by default. It seems as homeseer discovers them they are assigned a code like "0E.C0.75" but if I used that in a script it does not work.

          For example: hs.ExecX10 "0E.C0.75", "on", 0, 0
          Last edited by ; October 31, 2008, 08:04 PM.

          Comment


            #6
            Got it, the codes have a "\" before them..

            Comment


              #7
              When you added your Insteon switches it should have created devices for each item added with a device code like [1 or something similar. This is the code you use to control the device.
              💁‍♂️ Support & Customer Service 🙋‍♂️ Sales Questions 🛒 Shop HomeSeer Products

              Comment


                #8
                He figured it out while we were both typing.

                Good luck!


                ~Bill

                Comment


                  #9
                  Originally posted by Bill Brower View Post
                  He figured it out while we were both typing.

                  Good luck!
                  Bill & Rupp thank you!

                  Now where is the function to say if it is between 1 hour before sunset and 1 hour after sunrise turn on a light?

                  I found the sunrise seunset functions but can not find a function to get the current time and compare to sunset & sunrise plus or minus an hour?

                  I want to turn on the outside lights when the garage door is opened (dry contact x10) but only turn the lights on when it fits the times above?

                  Comment


                    #10
                    Scripts control lights differently then status page?

                    On my status page and can turn devices on and off no problem. I have a script that runs and when I test it turning on devices that work from the status page it does nothing? I added a one second delay between \2 and \1 thinking that might be an issue but it did not help. Again if I go to the status page and click ON for \2 or \1 the light comes on almost right away, but when the script fires nothing happens?

                    Sub Main
                    hs.ExecX10 "\2", "on", 0, 0
                    hs.WaitSecs 1
                    hs.ExecX10 "\1", "on", 0, 0
                    hs.WaitSecs 300
                    hs.ExecX10 "\2", "off", 0, 0
                    End Sub

                    I tried to shutdown homeseer (application not running as a service) and it said running shutdown script and hung there. I had to end task it, when I restarted the homeseer application and ran my script it worked. hmmm?? Homeseer also says the script is taking longer than expected, I thought wiatsecs was supposed to avoid this?

                    Comment

                    Working...
                    X