View unanswered posts | View active topics It is currently Fri May 24, 2013 10:10 am



Reply to topic  [ 2 posts ] 
 Possible enhancement request 
Author Message
User avatar

Joined: Nov 18, 2008
Posts: 1721
Location: Berkeley, CA
Post Possible enhancement request
If I use indigo.devices.subscribeToChanges(), in the callback deviceUpdated() a plugin receives two objects, the original (pre-change) Device and the new (post-change) Device. This is fine. However, the objects do not indicate whether Indigo originated (sent) or received the triggering event. I assume that this is because indigo.devices.subscribeToChanges() is triggered by an update to Indigo's database.

Would it be possible to include information in the objects sent to deviceUpdated to indicate whether Indigo had originated or received the change?

I realize this could be a giant can of worms since one INSTEON command sent could result in several received (links, etc.) and of course, now that we have plugin devices it is even more complex. But, I thought I'd ask anyway.

BTW, the reason for wanting to know this information is to allow a plugin the option of only triggering on received events (I.e. I might want to know when the actual switch was operated, not just when the light was turned on). I realize I can subscribe to incoming events (indigo.insteon.subscribeToIncoming()) as well. But, if it is necessary to also track sent changes, then subscribing to and managing both streams could be a real pain.


Sun Jan 29, 2012 6:21 pm
Profile
Site Admin
User avatar

Joined: Jan 27, 2003
Posts: 11697
Location: Texas
Post Re: Possible enhancement request
Having a changeOriginator type of argument is a good idea. However, the changes required to implement it are pretty significant given how many places states can change. But we'll keep it in mind the next time we are working in those areas.

_________________
Image


Sun Jan 29, 2012 7:01 pm
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 2 posts ] 

Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.   Template designed by STSoftware.