Announcement

Collapse
No announcement yet.

Button lights on Insteon KeypadLinc

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Button lights on Insteon KeypadLinc

    Is there a way to send a command to a Insteon KeypadLinc with a binary mask to make buttons On or Off?

    The buttons are getting out of sync and I really don't want to use Insteon events.

    Thanks!

    #2
    Not working

    Ok, I am missing something. Even sending a simple beep to the keypad I am getting an error:

    VBScript show me an error expecting ")":
    &hs.plugin("Insteon").TransmitInsteonCommand("23.C9.A5", 0x30, 0)

    C# don't even find Plugin collection:
    &shs.Plugin("Insteon").TransmitInsteonCommand("23.C9.A5", 0x30, 0);

    Can I have an example of how to send a command and an extended command? I think with that I may resolve the bitmap mask needed to change the button lights.

    Thanks!

    Comment


      #3
      for vbscript you need to remove the parens in the call. try the following

      &hs.plugin("Insteon").TransmitInsteonCommand "23.C9.A5", &h30, 0

      or convert your script to a vb.net script

      I'll have to add an external method for you to transmit an extended msg
      Mark

      HS3 Pro 4.2.19.5
      Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
      Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
      Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

      Comment


        #4
        I tried your

        &hs.plugin("Insteon").TransmitInsteonCommand "23.C9.A5", &h30, 0

        and it didn't work either. Am I missing any library to be installed?

        @mnsandler: do you have plans to have a public method to have extended messages? Any other way I can do that in the interim?

        Thank you.

        Comment


          #5
          here is a tested vb.net script. i couldn't get it to work in with vbscript (.vbs)

          sub main(parms as object)
          dim insteon as object
          insteon = hs.plugin("Insteon")
          insteon.TransmitInsteonCommand("\","1",&h30,0)
          end sub
          There is no work around for sending extended msgs.
          Last edited by mnsandler; August 3, 2015, 02:40 PM.
          Mark

          HS3 Pro 4.2.19.5
          Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
          Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
          Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

          Comment


            #6
            Originally posted by dr.zambol View Post
            I tried your

            &hs.plugin("Insteon").TransmitInsteonCommand "23.C9.A5", &h30, 0

            and it didn't work either. Am I missing any library to be installed?

            @mnsandler: do you have plans to have a public method to have extended messages? Any other way I can do that in the interim?

            Thank you.
            what version of the plugin are you running?
            Mark

            HS3 Pro 4.2.19.5
            Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
            Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
            Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

            Comment


              #7
              Insteon, version: 3.0.5.20

              Comment


                #8
                that explains the troubles. i thought you were using hs2 based on your original email

                here is the hs3 call. search this forum for "pluginFunction" for other examples of this.

                from a vb.net script file

                hs.pluginfunction("Insteon","","TransmitInsteonCommand", new object() {"23.C9.A5", &h30, 0})
                Mark

                HS3 Pro 4.2.19.5
                Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
                Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
                Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

                Comment


                  #9
                  here is a new version with a public method to send extended commands

                  here is the protocol for the call:

                  Public Function TransmitInsteonEDCommand(ByRef InsteonAddress As String, ByVal FlagByte As Byte, ByVal Cmd1 As Byte, ByVal Cmd2 As Byte, ByRef Data() As Byte) As Integer


                  To install:
                  1. shutdown hs, backup current plugin DLLs, insteon.ini and homeseer database
                  2. unzip DLLs to homeseer root directory
                  3. restart hs
                  Attached Files
                  Mark

                  HS3 Pro 4.2.19.5
                  Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
                  Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
                  Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

                  Comment


                    #10
                    Originally posted by mnsandler View Post
                    that explains the troubles. i thought you were using hs2 based on your original email

                    here is the hs3 call. search this forum for "pluginFunction" for other examples of this.

                    from a vb.net script file

                    hs.pluginfunction("Insteon","","TransmitInsteonCommand", new object() {"23.C9.A5", &h30, 0})
                    Thank you so much Mark. In C# it worked like below:

                    &shs.PluginFunction("Insteon","","TransmitInsteonCommand" , new object[] {"23.C9.A5", (byte) 0x30, (byte) 0});

                    Any reason why you are using "byte" and not System.Int32 and later forcing cast?

                    Now I am going to test the extended method you created. You rock !

                    Comment


                      #11
                      insteon cmds are byte values. this eliminate the need for me to check integer values and error trapping. it puts the onus on you the scripter to submit the correct values

                      you will find the extended command data array requires bytes as well.
                      Mark

                      HS3 Pro 4.2.19.5
                      Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
                      Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
                      Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

                      Comment


                        #12
                        I could send a beep using your extended command in C#. It worked perfectly:

                        &fhs.PluginFunction("Insteon","","TransmitInsteonEDComman d", new object[] {"24.FE.FC", (byte) 8, (byte) 0x30, (byte) 0, new byte[] {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}});


                        But I can't make work the Set LED Bitmask command to work (0x2E, 0x00). Command bellow should make buttons 1, 2, 3 and 4 ON, but instead of that it turns on the light if it is Off and do not change other Leds:

                        &fhs.PluginFunction("Insteon","","TransmitInsteonEDComman d", new object[] {"24.FE.FC", (byte) 8, (byte) 0x2E, (byte) 0, new byte[] {0x01, 0x09, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xB9}});

                        Any idea what I am missing?

                        Comment


                          #13
                          please try the following value for your flag byte: 0x1F
                          Mark

                          HS3 Pro 4.2.19.5
                          Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
                          Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
                          Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

                          Comment


                            #14
                            Thanks for the catch. I forgot bit 4 needed to be 1 to consider extended message. I do prefer minimize Hops and Retransmissions, so I set my Flag byte to 0x15 (10101).

                            Final command in C# is below. Button A/Load is not affected, but I think that is good since it is related to the load itself. In the command below I am setting turning on buttons A, B, C, D and E and off all the others.

                            &fhs.PluginFunction("Insteon","","TransmitInsteonEDComman d", new object[] {"24.FE.FC", (byte) 0x15, (byte) 0x2E, (byte) 0, new byte[] {0x01, 0x09, 31, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0xA9}});

                            Thanks for all your help. Everything is working now.

                            Comment


                              #15
                              glad its working. how do you find your comm stats when you only use 1 hop?
                              Mark

                              HS3 Pro 4.2.19.5
                              Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
                              Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
                              Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

                              Comment

                              Working...
                              X