Jump to content

UDP Formatting question - variables


nadler

Recommended Posts

Posted

I have connected ISY and Powerhome operating on my PC through UDP. Powerhome has easy to use voice integration and I have it announce things like "Garage Door is Open" or "Perimeter is Secured". I can not figure out how to send it ISY variables using UDP. For example I would like it to say "The temperature on the first floor is " ${sys.node.14 86 C 1.ST} "degrees." This works in an email but for UDP it sends the formula not the temperature.

 

I am certain that I am missing something easy, but I don't know what.

 

Anyone know if this is possible? If not, any other solutions?

 

Thanks!

Posted

Do you have the network module? Unless you have a way to parse a text or email and plug that into your other application, I am not sure it can be done without using the network module. But someone else may know something I don't.

Posted

I am using the network module. Here is an example of what I mean. The formula for the variable is being sent (and received) instead of the result of the formula (variable). I've tried all the modes and with and without quotes.

 

Thanks.

post-780-140474162312_thumb.png

Posted

I don't think the network resources allow for variable substitution. You'd have to create a different UDP resource for each variable value you'd want.

Posted

I won't mind creating a separate UDP resource for each variable. There aren't many. But how do I get the variables into each resource. I'm at a loss.

 

Thanks.

Posted
I won't mind creating a separate UDP resource for each variable. There aren't many. But how do I get the variables into each resource. I'm at a loss.

 

Thanks.

 

You have to put the actual value into each network resource, at least until variables is supported. For example, if the variable can have 5 values, you would need 5 network resources, one for each value. Then you would need 5 programs to call each of those 5 resources depending on what the actual value was.

 

If

$x = 1

Then

resource '1'

 

If

$x = 2

Then

Resource '2'

 

And so on, where resource 1 does your UDP posting of the value 1 to your other device, 2 for 2, and so on.

Posted

I am glad to hear that variables will be supported in Network Resources in future firmware.

 

apostolakisl, thanks for your suggestion. I'm going to try it.

 

I'm also going to try to have ISY send PowerHome a UDP packet when the temperature changes which will fire a trigger in PH which will run a macro to issue a Rest command from PH to ISY which will pull the various temperatures and setpoints from ISY and trigger PH's voice.

 

Thanks again.

Guest
This topic is now closed to further replies.

×
×
  • Create New...