Announcement

Collapse
No announcement yet.

Checking if device address exists?

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

    Checking if device address exists?

    What's the best way to check if device address exists?

    #2
    hs.GetDeviceByAddress should return an object if the address exists. otherwise you get nothing
    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


      #3
      This I know, but (1) it's not very efficient and (2) messy since you need to know if it's a "device" or "feature".

      Click image for larger version

Name:	Screenshot 2022-07-27 003006.png
Views:	142
Size:	29.0 KB
ID:	1559146

      Comment


        #4

        what's the alternative? you to enumerate through all the devices and/or features until you find a hit
        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


          #5
          Originally posted by mnsandler View Post
          what's the alternative? you to enumerate through all the devices and/or features until you find a hit
          I think that also generates a log event from HS that something is iterating through all the devices.
          HS4Pro on a Raspberry Pi4
          54 Z-Wave Nodes / 21 Zigbee Devices / 108 Events / 767 Devices
          Plugins: Z-Wave / Zigbee Plus / EasyTrigger / AK Weather / OMNI

          HSTouch Clients: 1 Android

          Comment


            #6
            What about hs.DoesRefExist?
            stefxx

            Comment


              #7
              Originally posted by stefxx View Post
              What about hs.DoesRefExist?
              It's "ref", not address

              Comment


                #8
                DeviceExistsAddress or DeviceExistsAddressFull
                Zwave = Z-Stick, 3xHSM100� 7xACT ZDM230, 1xEverspring SM103, 2xACT HomePro ZRP210.
                X10 = CM12U, 2xAM12, 1xAW10, 1 x TM13U, 1xMS13, 2xHR10, 2xSS13
                Other Hardware = ADI Ocelot + secu16, Global Cache GC100, RFXtrx433, 3 x Foscams.
                Plugings = RFXcom, ActiveBackup, Applied Digital Ocelot, BLDeviceMatrix, BLGarbage, BLLAN, Current Cost, Global Cache GC100,HSTouch Android, HSTouch Server, HSTouch Server Unlimited, NetCAM, PowerTrigger, SageWebcamXP, SqueezeBox, X10 CM11A/CM12U.
                Scripts =
                Various

                Comment


                  #9
                  Originally posted by enigmatheatre View Post
                  DeviceExistsAddress or DeviceExistsAddressFull
                  That's what I'm after, but where? IHsController doesn't have it.

                  Comment


                    #10
                    Originally posted by alexbk66 View Post

                    It's "ref", not address
                    Correct, my bad.
                    stefxx

                    Comment


                      #11
                      I found it here but not sure about in the sdk.
                      Zwave = Z-Stick, 3xHSM100� 7xACT ZDM230, 1xEverspring SM103, 2xACT HomePro ZRP210.
                      X10 = CM12U, 2xAM12, 1xAW10, 1 x TM13U, 1xMS13, 2xHR10, 2xSS13
                      Other Hardware = ADI Ocelot + secu16, Global Cache GC100, RFXtrx433, 3 x Foscams.
                      Plugings = RFXcom, ActiveBackup, Applied Digital Ocelot, BLDeviceMatrix, BLGarbage, BLLAN, Current Cost, Global Cache GC100,HSTouch Android, HSTouch Server, HSTouch Server Unlimited, NetCAM, PowerTrigger, SageWebcamXP, SqueezeBox, X10 CM11A/CM12U.
                      Scripts =
                      Various

                      Comment


                        #12
                        Originally posted by enigmatheatre View Post
                        I found it here but not sure about in the sdk.
                        That would be under the HS3 HomeSeerAPI.IHSApplication
                        Jon

                        Comment


                          #13
                          yeah, found in HomeSeerAPI.IHSApplication - will give it a try

                          Comment


                            #14
                            Yep, it works, thank you enigmatheatre jon00

                            Comment


                              #15
                              A question related to this... Is there a script or easy method to generate a simple list of devices and their refs and address? Something that I can use to sort or search on? I don't see in the HS4 UI such a simple data grid view with selectable headers for sorting.

                              Comment

                              Working...
                              X