Created At

Jul 10, 2022

Last Update

Aug 03, 2022

Platforms

HC 3 Lite, Z-box Hub, Yubii Home Pro, Yubii Home, Venture WISE, HC 3

Views

5610

Download

450

Type Scene

The Advanced Presence Simulation scene automatically adapts to your living pattern from the past week. Therefore you don't have to program complex routines with random times that have to take into account light, sun and seasons.

This scene uses your light and shutter switching pattern from the HC3 device log (history). With this you can make an outsider believe that someone is at home by letting the HC3 operate the light switches and shutters exactly as you did a week before you went on vacation.

The scene is activated when the away profile is active for 8 hours. As a reminder, the user will receive a push message via the Yubii app.

Release notes

v1.1.0

  • Fixed a bug where the last light state was not set when a switch or dimmer was operated several times within 1 minute.

Prerequisites

  1. The HC3 must be operational for at least 7 days to log a switching pattern.

  2. To use the scene optimally, you should use the HC3 profiles for your home state.

Room exclusion configuration

The scene supports room exclusion because you may not want to include garden lighting routines in the presence simulation if they are switched by motion sensors to keep burglars away.

Installation

See the included manual for full installation instructions. English and Dutch manuals are available.

More information

I wrote a blog about presence simulation with tips on how to use this scene. You can read this blog at: https://docs.joepverhaeg.nl/presence-simulator/

8 Comments,  Want to add comment please login
7e55719745ae9e37e0996f355585fffc

Hi Bertrand, no, 7 days is not a limit. I'll send you a PM, because this view isn't handy with a lot of text.

8d2fca04cc9260fb2e8e0f772dab3bbc

Dear Joep, I have install your Presence simulation; all OK. HI recently had a problem of a full database in my HC3 due to too big "event.db" size which has caused all my scenes no more triggered by event or device state change. Fibaro.support clear the database and advised me to check regularely the number of events in HC3 in order to get an alarm when the event.db is over i.e. 50000 lines. In your scene function readHistory(), I have added a new request for 1 year using the following string: local fromYear = os.time({year = today.year-1, month = today.month, day = today., hour = 00, min = 00, sec = 00}) I can print the number of element of the retreived table using: allEventHistoryLastYear = api.get("/events/history?from=" .. fromYear .. "&to=" .. toTime.."&eventType=DevicePropertyUpdatedEvent&numberOfRecords=100000") print("Number of all events for the last 12 month: "..#allEventHistoryLastYear). It is also working for one month of history (month=today.month-1) For checking number of events in events.deb and also shrink automatically the event.db to a maximum number of events,I have created a QA in which I have included your readHistory() function with variables in the fromTime definition year=today.year+currY, month=today.month+currM, day=today.day+currD Where currY, currM and currD are a negative integers to select period modified by specific QA buttons. This is working fine but only for currD values from -7 to 0 and currY=0 and currM=0 Any other values of currs give an error 500 for the api.get("events...") request. Any reason for that? is the api.get format in a QA needs to be different from scene? f it is the case why working for only 7 days?

8f41876bead5a98aef71331b2aeece6f

Hi, You can find all the answers in HTML file

47dba807f54e3624c7d73e70af34035d

how to apply the above code to hc3 system?

7e55719745ae9e37e0996f355585fffc

@Rolf: this is possible. You have to edit the condition to trigger the scene when the other profile is active. And you have to change the lines with if (activeProfile ~= "Vacation") and if (activeProfile ~= "Away") to the new names. But why use the two profiles. The concept is that the home is set to away mode and after 8 hours away the system automatically sets the profile to vacation (or holiday) and start running the simulation.

© 2024. Nice-Polska Sp. z o.o.Privacy policyTerms & ConditionsFeedback