Jump to content

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


  • 0

QA Virtual sensors AIO (All in One)


petrkl12
 Share

Question

QA Virtual Sensors AIO (All in One)

 

Why to use AIO virtual sensors:

  • Possibility to create any hierarchical structure of sensors (real and virtual) - eg motion sensors for room, floor, object,…
  • Switch the virtual sensor on/off
  • Simulate the setting of values for temperature, light, wind, humidity, etc.
  • Generate motion in a room where no one is and test the functionality of your home automation
  • Clone the sensor to another room
  • Correct the values
  • Mathematical conversions eg. km/h to m/s
  • Select how the final value for more sensors will be calculated (Average, Sum, Min, Max, Newest, Oldest)
  • Detail view with all values and time of updates

 

You can come with your own ideas how to use it :)

 

  

Please login or register to see this attachment.

    

Please login or register to see this attachment.

    

Please login or register to see this attachment.

 

 

 

INSTALLATION AND DETAIL INFORMATION:

 

1.Motion sensor - I use it as a main motion detector in all rooms/floors/buildings - it can concentrate all the devices that can show me that someone is there. Any motion detector (in Variables - Devices), opening or closing doors / windows (in DevicesDW) and then all remote controls / switches that generate Central Scenes (these are in DevicesCS)

This is how I have it in all rooms and then I put the individual virtual detectors in the Floor / Ground Floor / Outdoors and then on the Floor and Ground Floor I make a movement in the House - basically any combination :). Virtual and physical devices can be combined.

All other things (scenes/QAs) I have connected to these central sensors.

Other use cases:

- keep track of which devices in detail and when they last generated motion

- generate movement by pressing a button (suitable for testing, for example - you don't want to go into the room, so you just create the movement virtually)

- turn on / off the virtual sensor (you have a sensor connected, for example, in the alarm zone, but something is wrong, so you simply turn it off remotely)

Other parameters:

Delay - how long after the sensor the sensor returns to its original state (default 30s)

MotionSensOn - whether the sensor should be in the On state after restart (values are Yes / No, default Yes)

 

Please login or register to see this link.

 

2. Sensors: Power, Light, Temperature etc.

Why to use:

- I want to have an average value from more devices and then use it as the main indicator for a given room

- I want to test something - I can set any value, both manually and from another QA or scene

- I can create a sensor with an empty list of devices and send values from another scene or QA (or even manually)

- I can turn the sensor off / on (if the sensor is off, I can still set the values manually / programmatically). When enabled, the manually set value will be overwritten when the first new value arrives from the defined devices. If the sensor is switched off, the set value remains there.

- I can define how the final value will be calculated - can be used: Average, Sum, Min, Max, Newest, Oldest (TableOper item)

- use for rounding values,

- for correction of measured values

- can be used for any unit conversions - for the resulting value calculated according to TableOper, a mathematical expression (ValueOper item) will be used, eg Value + 2 or (100 * Value + 2) / 1000 (if you do not specify Value, the result will be a given constant or calculated constant eg 10 or 3 + 12 + 20)

- can also be used for cloning to another room - for example, you have a hygrometer in the living room and you want to add it to the kitchen

- you will certainly find other uses :)

 

Settings:

all sensors have more or less the same settings - they only have a different set of default parameters

- Devices: list of devices to be connected to the virtual sensor (comma separator), default is 0 (no device is defined)

- TableOper - how the values coming from Devices are to be processed - can be used: Average, Sum, Min, Max, Newest, Oldest

- ValueOper - how the resulting value from TableOper should be further mathematically processed - the default is Value, ie. unchanged - basic mathematical expressions including parentheses can be used

- ValueRound - how to round the resulting value - how many decimal places

- Unit - what is the sensor unit

- SensorOn - whether the sensor should be switched on after restart (values Yes / No)

Please login or register to see this link.

 

3. Power consumption for Light / Device

I use to set the power for devices that do not measure power themselves. It can be used both for devices that have an On / Off status and for devices that are regulated and have values of 0-100

Settings:

Device - only one device can be entered

MinPower - consumption in the off state

MaxPower - consumption in the on state at 100%

ValueOper - how to calculate the final consumption - for the off state is Value 0, for the on state is Value 100, for controllable devices the value will be 0-100 or 0-99 (depending on the type)

ValueRound - how to round the resulting value - how many decimal places

Unit - default - W

SensorOn - whether the sensor should be switched on after restart - Yes / No (default Yes)

 

Please login or register to see this link.

 

Technically, all devices are Child, including the user interface. The advantage is that they consume less memory than stand-alone QA devices. It is possible to have more main QAs in the system, for example one for motion detection, other for consumption measurement, etc. So far I only have one with more than 40 child devices :) 

QA works on the principle of capturing events (it is very fast) and does not query all defined devices on a regular basis.

Each time the setting is changed, the name of any device is changed, the room is changed, the main QA and the child device are restarted

 

Files:

Please login or register to see this attachment.

 

VirtualDevAIO.png.05d50a6c4fca58296f8819d6cad56c2d.png

 

 

Edited by petrkl12
  • Like 4
Link to comment
Share on other sites

6 answers to this question

Recommended Posts

  • 0

Some hysteresis or thresholds or average over a time window? Makes sense for stuff that fluctuates a lot like ex. power.

Edited by jgab
Link to comment
Share on other sites

  • 0
  • Inquirer
  • @jgab

     

    I was thinking about time weight average ie. for power consumption : ((time period 1 * value1 + time period 2 *value 2+ ... / sum(time period))

     

    How it should work with hysteresis or thresholds? Any example could help :)

     

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • if somebody wants to test this QA please let me know via pm

     

    Please login or register to see this attachment.

     

    • Thanks 1
    Link to comment
    Share on other sites

    • 0
    22 hours ago, petrkl12 said:

     

     

    Please login or register to see this attachment.

     

    I want to test

    Edited by minsad79
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • updated first post incl QA

    • Thanks 1
    Link to comment
    Share on other sites

    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.

    Guest
    Answer this question...

    ×   Pasted as rich text.   Paste as plain text instead

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.

     Share

    ×
    ×
    • Create New...