Announcement

Collapse
No announcement yet.

activate device script button from a txt script

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

  • mterry63
    replied
    Funny, I had the exact same issue occur with the Homeseer Ocelot plugin with the 1st input of a SECU16 device. It consistantly creates a bad device.

    It's a shame Homeseer won't support their own code.

    Leave a comment:


  • tenholde
    replied
    Great! Glad I could help.

    tenholde

    Leave a comment:


  • peterpc
    replied
    That did the trick!
    The program stopped at a device and it was a device, created with an Ocelot plugin.
    This plugin was modified to also use IR and variables. But it was working only for 1 secu16 unit. (and the creator of the flugin did not respond anymore on my mails for help.)
    That made me decide to buy ethernet boards with relais and inputs.
    They are working now, but I still had the Ocelot devices.
    I have deleted all existing Ocelot devices and now the program is working ok!
    Thanks for your help!

    Leave a comment:


  • tenholde
    replied
    peterpc,

    I've built a utility that instead of using HS3 enumeration to retrieve all devices (which is failing on your installation), it attempts to retrieve Devices with a DevRef of 1-10000.

    I'm hoping it fails on a specific device so we can narrow down what is happening.

    Please download and run the FindBadDevice utility and let me know what happens.

    tenholde

    Leave a comment:


  • tenholde
    replied
    peterpc,

    Read this thread: http://forums.homeseer.com/showthread.php?p=1107815



    tenholde

    Leave a comment:


  • tenholde
    replied
    peterpc,

    Could you define a few things about your configuration.

    You are running on remote computer, correct?

    Same LAN?

    What OS, etc. is HS3 running on. What OS, etc are you running tenScriptAid on?

    What plugins are installed.



    The hs.GetDeviceEnumerator call is failing. There is some message board traffic about this -- I'm doing further research.

    Looking at reported problems with plugins that use PlugExtraData, and you try to access stuff remotely. Especially if the plugin places custom objects into PlugExtraData.

    Linux base HS3 does not properly serialize remote objects, and even on Win, if a plugin uses a custom object in the PlugExtraData, the plugin must be available for the remote caller for deserialization.

    Please provide what you can, and I will keep researching.

    If you feel adventurous, stop all of your plugins and see if that helps. If it does, keep adding plugins back until it fails.

    Not sure any of this is the problem. Still looking.

    tenholde

    Leave a comment:


  • peterpc
    replied
    12/6/2015 17:32:27 | Attempting to connect to: 127.0.0.1
    12/6/2015 17:32:27 | OpenHsConnection called with: 127.0.0.1
    12/6/2015 17:32:27 | CreateClient successful, CommunicationState: Disconnected
    12/6/2015 17:32:27 | Attempting to Connect, this is attempt number: 1
    12/6/2015 17:32:27 | client.Connect attempted, CommunicationState: Connected
    12/6/2015 17:32:27 | host should now be good ServiceProxy
    12/6/2015 17:32:27 | Attempting to get APIVersion through Proxy
    12/6/2015 17:32:27 | Successfully retrieved APIVersion through the host Proxy: 3
    12/6/2015 17:32:27 | Now trying: hs=host
    12/6/2015 17:32:27 | OpenHsConnection appears to have completed successfuly
    12/6/2015 17:32:27 | HS3 connection successful
    12/6/2015 17:32:27 | HS version: 3.0.0.208
    12/6/2015 17:32:27 | Retrieving HS3 Devices
    12/6/2015 17:32:27 | Getting Enumerator
    12/6/2015 17:33:27 | Exception retrieving Devices: Object reference not set to an instance of an object.

    Leave a comment:


  • tenholde
    replied
    The error you are getting is before it successfully retrieves even the first HS3 device while enumerating.

    Please try version 1.14, adds more debug info during Device Retrieval.

    Please post debug results.

    Thanks for your patience,

    tenholde

    Leave a comment:


  • sparkman
    replied
    Originally posted by peterpc View Post

    Can it be that the device Reference ID of the latest device is too high?
    Latest device has Reference ID 2451.
    I have done a lot of testing creating devices and delete them.
    I now have 687 devices
    Not likely as my latest reference is quite a bit higher than that and so is my latest device count and it's working fine for me.

    Cheers
    Al

    Leave a comment:


  • peterpc
    replied
    Originally posted by tenholde View Post
    That helps. Did the log not show any devices that it found?
    No, that is all in the log file.

    Leave a comment:


  • tenholde
    replied
    That helps. Did the log not show any devices that it found?

    Leave a comment:


  • peterpc
    replied
    Originally posted by tenholde View Post
    Could you select the debug box before connecting?

    The HS log will show you where the tenScriptAid log is written.

    Please post log contents here.

    Thanks,

    tenholde
    This is the log:
    12/5/2015 23:01:41 | tenScriptAid started
    12/5/2015 23:01:41 | Clipboard set to:
    12/5/2015 23:01:41 | tenScriptAid Startup Complete
    12/5/2015 23:01:47 | Attempting to connect to: 192.168.1.20
    12/5/2015 23:01:47 | HS3 connection successful
    12/5/2015 23:01:47 | HS version: 3.0.0.208
    12/5/2015 23:01:47 | Retrieving HS3 Devices
    12/5/2015 23:02:47 | Exception retrieving Devices: Object reference not set to an instance of an object.

    Can it be that the device Reference ID of the latest device is too high?
    Latest device has Reference ID 2451.
    I have done a lot of testing creating devices and delete them.
    I now have 687 devices

    Leave a comment:


  • sparkman
    replied
    Originally posted by peterpc View Post
    Is there also a command to read if a module is on or off?
    Like replacement for hs.IsOn?
    Since you are not controlling a device, you can also get the device's value using hs.devicevalue. However, you'd have to know what the specific values are for on and off as this is not consistent across all types of devices/plugins. Off is typically 0, but On could be 1, 99, 100, 255.

    Cheers
    Al

    Leave a comment:


  • tenholde
    replied
    Look at the Capi Status value, it should show current status from the CapiControls available for that device:

    Code:
    if hs.CAPIGetStatus(924).Status.ToUpper.Contains("ON") then    xxxxxxxxxxx

    Leave a comment:


  • peterpc
    replied
    Originally posted by peterpc View Post
    hs.CAPIControlHandler(hs.CAPIGetSingleControl(cv,true ,"On",false,true))
    is working perfect!
    Is there also a command to read if a module is on or off?
    Like replacement for hs.IsOn?

    Leave a comment:

Working...
X