Bathroom Lights with Motion and Contact Sensors


#21

I was going to PM you but I don’t mind people seeing my reasoning.

You are saying that using a condition will not execute a piston. That is wrong. Using a condition will execute a piston. Bottom line. That is why your post was striked out and edited. Sorry if calling it bad made you feel attacked or something. But your statement is wrong.

It is not theory. If you create a piston right now that says if contact is open then turn on a light. Are you saying that won’t work except in theory?

What about using only a condition makes a piston unreliable?

I am not here saying your way is wrong/bad and my way is right/good. I actually did not even suggest a different way. There are several ways to get to an end result in webcore. You mention this a lot, especially on facebook.

Your post was edited because the information you gave was wrong. Being bold would have been editing your post and deleting what you said and changed it to what I said. But instead I left my reason why I crossed your information out.

And just because you got edited and corrected do not make this out to be like I am censoring you and imposing my ideas over yours. Because that couldn’t be further from the truth.


#22

I have been using this piston for awhile and it has been working well for me. It’s more or less what you were describing but you may need to tweak a few things to get to where you want. A few things of note. I’m using a Xiaomi motion sensor and that is why i set the “if no motion detected” to 30 seconds as those sensors keep active for 1 minute by default. You should change this to your preferred wait time. The global variable @bathroomOccupied is used here for other automations - you can remove that.

Generally the lights will come on if motion is detected or a knock on the door and if no motion is detected for 90 seconds, it’ll turn off UNLESS the door is closed, in which case the lights will stay on. When the door is opened, the 90 second timer starts again.

Hope this helps.


#23

First, I’ve argued that it would not be reliable. I didn’t say that it couldn’t be done. And according to the documentation out there, I’m not wrong. And, yes, you basically censored my post by editing it. “SLAP! I edited your post because you were WRONG!” Well thanks for that. Nothing about “Hey were’d you hear that? Why do you feel that way?” Great way to start out a help forum. Pretty belittling. You obviously feel your reasoning is the “World” because you have the power to use it and edit other’s posts as you see fit. So you must be right. But my level of respect for this forum and you has gone down just a bit with this interaction. So now, I’m going to participate that much less. If at all. That’s unfortunate, because I feel like I’ve come up with some pretty cool stuff. And love to hear about other members pistons as well. And to top it off, you’ve taken away from the original post. So, in line with the high and mighty, you should probably delete this thread as in reality it will definitely command the respect of others knowing how you treat people in the forum. Congratulations.


#25

Honestly if you have argued this point I am curious as to where?

Please link this documentation that says conditions do not act like triggers. Or that conditions are unreliable.

The rest of this is how you feel about the matter. I am sorry you can not take constructive criticism or accept that you might have been wrong. As a forum that is helping new members who might actually use the search button before making a new post I would hate for them to see misinformation. And you can continue to ask like I am some gestapo or SS by saying I am going to delete your post but I do not plan on doing that. If you would like to continue this then please make a new thread or PM me.

@Lhartman89 Sorry this hijacked your thread. I hope that you have received the help you were looking for. If you still need to tweak some things then please ask away.


#27

Can we all calm down please?

I agree that admins shouldn’t be editing posts just because of factual errors, a nudge for the user to do so is probably the most diplomatic way in the first instance… there is a learning curve here for us all, new forum, new admins, new users… but there is never a reason to start name calling and insulting each other hence the post I have removed above.

Thank You


#29

A piston is usually executed on events that trigger it. Therefore, triggers - by definition - will always run pistons. In the event no trigger is present, conditions then fulfill that role by acting as triggers themselves (all the conditions in the piston do that when no triggers are present). The moment a trigger exists, conditions step down and act as just that, conditions (or restrictions, if you want), therefore not triggering pistons themselves.

Only conditions >>> all conditions act as triggers and they all subscribe to events
Mixed conditions and triggers >>> only the triggers subscribe to events
Only triggers >>> only the triggers subscribe to events

There is, of course, the manual modification of this behavior, by forcing a condition or trigger to either subscribe regardless, or never subscribe. Those settings take priority over the logic described above.


#30

Hey there, let’s all calm down please. Why do you think “is” is not reliable?