Hello all-
I have been searching this forum with no luck. I figured what I was looking to do was pretty basic and common, but maybe not? I am looking to design a piston that locked the doors whenever they are left unlocked and it detects a presence sensor has left. I can reliably get it to do that, but I would also like to know which do was left unlocked. In my attempts to do this i created a dynamic notification using a system variable. However, I am not sure I understand fully how they work. I tried used {$currentEventDevice} & {$previousEventDevice}, but my results come back with the presence sensor name and the word “Home” respectively. I don’t know what would happen if both doors were left unlocked.
My guess is I need to assign the locks to a variable and then call the variable in the notification. I am not sure how to go about doing this. I am really new to coding this stuff myself and don’t have a coding background. Has anyone already done this or can someone help me create this piston?
Thanks in advance for any help (and I apologize if this was covered elsewhere, i just couldn’t find it searching).
-Jason