Announcement

Collapse
No announcement yet.

Set an Omni flag through a script

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

  • Set an Omni flag through a script

    I've been using the plugin for many years but I've never had to do this particular action.

    I'm trying to set a flag on the OMNI using a vb script from HS. I tried hs.SetDeviceValue but realized that all that does is change the value in the object on the HS side but does not communicate this to the OMNI. Has someone already solved this problem?

    I know i can set a flag using any HS action to a pre-defined value (using the dropdown) but how else would I set the value through an action when I need to read the value in as a parameter?

    Appreciate your thoughts!

  • #2
    You will likely need to use HS's CAPI interface to actually control/change the device.
    As far as reading the value in as a parm, I'm not entirely sure how you would do that.
    I'll see if I can post some CAPI code here later...
    HS3Pro Running on a Raspberry Pi3
    64 Z-Wave Nodes, 168 Events, 280 Devices
    UPB modules via OMNI plugin/panel
    Plugins: Z-Wave, BLRF, OMNI, HSTouch, weatherXML, EasyTrigger
    HSTouch Clients: 3 Android, 1 Joggler

    Comment


    • #3
      Thanks - some example code would be great!

      Comment


      • #4
        Try this (replace the Device Id with your flag's device id:
        Code:
        &hs.CAPIControlHandler(hs.CAPIGetSingleControl(1641,False,"75", False,true))
        Last edited by rmasonjr; November 26th, 2018, 11:08 AM. Reason: spacing
        HS3Pro Running on a Raspberry Pi3
        64 Z-Wave Nodes, 168 Events, 280 Devices
        UPB modules via OMNI plugin/panel
        Plugins: Z-Wave, BLRF, OMNI, HSTouch, weatherXML, EasyTrigger
        HSTouch Clients: 3 Android, 1 Joggler

        Comment


        • #5
          Worked like a charm! thank you!

          Comment

          Working...
          X