Feedback Response Terminator Questions...

Forum to ask for any help
Post Reply
Stik
Posts: 23
Joined: Wed Nov 20, 2013 7:04 pm

Feedback Response Terminator Questions...

Post by Stik » Mon Nov 24, 2014 9:56 pm

I apologize if these questions have been answered already somewhere else, but after examining the Demopad manuals and Forums, I have been unable to find any relevant discussions...

I am using Demopad to control a Universal Devices ISY994. I have managed to successfully set it up to use subscription services such that the ISY will update Demopad with changes in status without requiring repetitive polling.

Unfortunately, the ISY API doesn't seem to provide the same Response Terminator for all feedback. In particular, the Feedback I am trying to solicit is either returned ending in "</S:Envelope>" or "</Event>" (translated to Hex of course). In neither case does it append these with either a \x0A or \x0D. This seems to mean that I require two sets of devices/feedback to correctly identify both sets of responses which could otherwise by accomplished using one Regex expression. I have tried just using the common ">" (\x3E) without success. I am guessing it is because the ">" is peppered throughout each line of all responses.

Several questions,

1. How exactly does Demopad use the Response Terminator? Does it use the Response Terminator to determine which lines to parse for Feedback or does it parse every line until it sees the first instance of the response terminator? Something else entirely?

2. Is there any way to use an OR function in specifying the Response Terminator on one device? i.e. - </s:Envelope> or </Event>? I know this is a long shot, but it would be nice to avoid having to define two separate devices and extensive sets of feedback for basically receiving the same data simply because ISY sends different device terminators for what is otherwise almost identical data.

3. Am I missing something? Can anyone offer any other advice or do I need to set up a different device for each different Response Terminator for which I desire feedback?

Thanks in advance for the assistance.

Andy

trevorst
Posts: 160
Joined: Wed Jul 18, 2012 3:45 pm
Location: Tacoma, WA

Re: Feedback Response Terminator Questions...

Post by trevorst » Tue Nov 25, 2014 4:45 am

What feedback are you trying to capture from the ISY???
Insteon feedback??
I have several Insteon feedback routines working fine, the ISY does not give any feedback from some functions.

Stik
Posts: 23
Joined: Wed Nov 20, 2013 7:04 pm

Re: Feedback Response Terminator Questions...

Post by Stik » Tue Nov 25, 2014 6:34 am

You can capture much more than just Insteon Feedback from ISY. A few examples - I am using Demopad to control an alarm system through the ISY and using ISY variables to track states of various devices. In addition, if you have the Climate module installed, you can also get any of this information through from the ISY. This can all be done with feedback utilizing subscription based services so that no recurring polling is required.

Just about anything that can be controlled with ISY can also provide feedback. For more info, have a look at the documentation here: https://www.universal-devices.com/isy-developers/

trevorst
Posts: 160
Joined: Wed Jul 18, 2012 3:45 pm
Location: Tacoma, WA

Re: Feedback Response Terminator Questions...

Post by trevorst » Tue Nov 25, 2014 2:40 pm

I agree you can do a lot more with ISY than Insteon, didn't say you couldn't. What I said is there are some functions that do not provide feedback, which is true. I have the ISY working polling and use variables with Demopad also...I also have lots of feedback working just fine so I am sorry I can't help you with yours...

User avatar
DemoPad
Site Admin
Posts: 769
Joined: Thu Jun 14, 2012 10:46 am
Contact:

Re: Feedback Response Terminator Questions...

Post by DemoPad » Tue Nov 25, 2014 3:02 pm

Stik wrote: 1. How exactly does Demopad use the Response Terminator? Does it use the Response Terminator to determine which lines to parse for Feedback or does it parse every line until it sees the first instance of the response terminator? Something else entirely?

2. Is there any way to use an OR function in specifying the Response Terminator on one device? i.e. - </s:Envelope> or </Event>? I know this is a long shot, but it would be nice to avoid having to define two separate devices and extensive sets of feedback for basically receiving the same data simply because ISY sends different device terminators for what is otherwise almost identical data.

3. Am I missing something? Can anyone offer any other advice or do I need to set up a different device for each different Response Terminator for which I desire feedback?
The app / centro will read in each byte of data until the response terminator is seen. The response terminator can be entered in the software as a byte or bytes, eg\x0D\x0A or just as normal text, eg </xml>. Once the response terminator sequence is seen by the app, it runs the data read so far (since the last terminator) through the 2-way pattern matching, then carries on reading data until the next response terminator is seen - and then runs that next 'line' of data through the pattern matching.

Unfortunately there is no way, other than having several devices as you suggested, to cope with devices which return data ending with different characters, unless there is a common set of characters which still includes the data you require, eg </

Stik
Posts: 23
Joined: Wed Nov 20, 2013 7:04 pm

Re: Feedback Response Terminator Questions...

Post by Stik » Tue Nov 25, 2014 3:22 pm

DemoPad wrote: The app / centro will read in each byte of data until the response terminator is seen. The response terminator can be entered in the software as a byte or bytes, eg\x0D\x0A or just as normal text, eg </xml>. Once the response terminator sequence is seen by the app, it runs the data read so far (since the last terminator) through the 2-way pattern matching, then carries on reading data until the next response terminator is seen - and then runs that next 'line' of data through the pattern matching.

Unfortunately there is no way, other than having several devices as you suggested, to cope with devices which return data ending with different characters, unless there is a common set of characters which still includes the data you require, eg </
That is exactly the information I was looking for! Thank you for the clear explanation.

Post Reply