I’m trying to write a new plugin for a type of RFID tag reader (I am aware of and have looked at the existing ActiveRFID plugin - I’m trying to do something a bit different).
I’m getting familiar with what goes in the D_.xml, S_.xml and I_*.xml files, and I think I can make educated guesses what should be in them for my particular application.
I’d like to create a Scene Trigger that runs every time a new “SetTag” action is performed (I’m declaring SetTag in the S_ file and giving the one-line implementation in the I_ file, which I think is correct.)
Can anyone help with what to put in the D_**.json file to be able to get this event to appear?
What is the “eventList” part of the json file, and what is the “eventList2” part?
Awesome. With the help of those links, I now have it working
I’d like to make its operation conditional on being “active” so I’ve also implemented the SecuritySensor1 Armed attribute along with arm and disarm buttons on the interface. Under the hood I want to make the Event dependent on two attributes, “Tag ID” matching the one entered in the Trigger page as previously, but now also “Armed” = 1.
I see that one way to do this is to include a “serviceStateTable” entry in the event entry, thus:
But - the serviceStateTable looks in the same serviceId as the argumentList and my two attributes are from different serviceIds. Is there another way to do this?
Thanks for any suggestions!
Quick and dirty solution:
newTagID = ...
if Armed == 1
Tag ID = newTagID
Tag ID = 'NONE'