Welcome to Smart Home Forum by FIBARO
Dear Guest,
as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.
As a member you can:
- Start new topics and reply to others
- Follow topics and users to get email updates
- Get your own profile page and make new friends
- Send personal messages
- ... and learn a lot about our system!
Regards,
Smart Home Forum by FIBARO Team
Question
Seraphim 1
Dear Community,
I have a small issue with creating a script to my logic. I have three beds with a sleep sensor in each. Now I want to trigger something if the first person awakes and leaves the bed.
Well I know about time delay if this person is going to drink something at night etc. but that is not my issue.
I have created a variable "var_sleep" which counts from 0 (no one is sleeping) to 3 (everybody is sleeping).
I also have a variable "var_home" which counts from 0 (no one at home) to 3 (everybody at home).
If var_home = var_sleep, my house starts the night mode.
My issue starts in the morning when the first persona awakes: How to realise this? The variable var_sleep reaches the state 2 two times
1. 3 sleeping - 1 awakes = 2
2. 1st sleeping + 2nd goes sleeping = 2
Maybe this is the completely wrong way to "measure" it, if you have a better way, let me know.
In the end I want to know, when the first person leaves the bed.
Any Ideas?
Regards
Andreas
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.