Announcement

Collapse
No announcement yet.

Directing hs.speak to VR client

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

    Directing hs.speak to VR client

    Gurus,

    Need a little poke in the right direction. What I am trying to do is respond in a script to the specific speaker client that requested the script action.

    For a simple example let's say I say "Garage door status" to the Homeseer client on my android phone.

    This executes a phrase recognized event that executes a script that does some script magic and ends with an hs.speak statement.


    The question is how do I determine inside the script which specific client initiated the request? I understand how to structure the statement to speak to a specific client but can't figure out if there is a way know where it all started. I want the answer to come back to my phone and not any other client.

    Thoughts?

    Chris

    #2
    Some further thoughts...

    Looks like the command that I need to get to this is:

    hs.LastVoiceCommandHost

    However when I execute this inside a script I get:

    Jan-31 6:34:02 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Alert.vb: Type 'Obj' is not defined.
    Jan-31 6:34:02 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Alert.vb: Namespace or type specified in the Imports 'System.Core' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases.

    I suspect that it is either my beginning level of scripting or this is not supported in HS3... odd note that if I execute it in the control panel :

    &hs.writelog ("info",hs.LastVoiceCommandHost)

    I get :

    Jan-31 6:08:18 PM info

    Any thoughts?

    Chris

    Comment


      #3
      My guess is you have a variable declared as type "Obj" which is not a valid data type in VB.net. You would need to change it to "Object". If that doesn't help then post your entire script.

      Comment


        #4
        Did you ever get this working

        I have the code working but the return for host and instance is not the android client. Instead it returns the values from the last speaker client that received a VR command.

        Comment


          #5
          It is a bug

          Spoke to support and the confirmed it is a bug. They are producing a fix.

          Comment

          Working...
          X