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


Recommended Posts

On 10/10/2021 at 2:40 PM, jgab said:

You should be able to run it in my emulator.

In 

function EVENTS.getIOSdevices(ev) 

there is a http request.

Set a breakpoint in the error and the success handler and see what you get, if you get something.

 

Hi Jan

 

I loaded the IOSLocator in ZBS - but im getting issue at line 392 - im pretty sure this is something else, that the error when the QA is running.

 

Please login or register to see this code.

Please login or register to see this attachment.

 

 

Link to comment
Share on other sites

  • Topic Author
  • 11 hours ago, ChristianSogaard said:

     

    Hi Jan

     

    I loaded the IOSLocator in ZBS - but im getting issue at line 392 - im pretty sure this is something else, that the error when the QA is running.

     

    Please login or register to see this code.

    Please login or register to see this attachment.

     

     

     

    This is strange - it seems like it hasn't loaded fibaroExtra.lua ? on the other hand if fibaroExtra.lua didn't exist it would complain....? Let me think about this...

    • Like 1
    Link to comment
    Share on other sites

    36 minutes ago, jgab said:

     

    This is strange - it seems like it hasn't loaded fibaroExtra.lua ? on the other hand if fibaroExtra.lua didn't exist it would complain....? Let me think about this...

    Confirming that, fibaroExtra.lua is missing, i dont see its possible to "enable" in the toolbox?

    Link to comment
    Share on other sites

    On 10/27/2021 at 8:09 AM, jgab said:

     

    This is strange - it seems like it hasn't loaded fibaroExtra.lua ? on the other hand if fibaroExtra.lua didn't exist it would complain....? Let me think about this...

    Where in ZBS do i put the fibaroExtra.lua? for it to work with IOSLocator?

    Tried using the "mini-installer" in the IOSLocator.lua, and looking in the Proxy IOSLocator QA, i see the fibaroExtra.lua

     

    but i still are getting the same error...

     

     

     

     

    Please login or register to see this attachment.

     

    Edited by ChristianSogaard
    P
    Link to comment
    Share on other sites

    I created this rules for my SONOS Connect and Denon amplifier.

    This will let HC3 detect when SONOS is playing and turn on the Denon amplifier. - i found the

    Please login or register to see this link.

    in the frensh forum

    It works, but i want it a little bit smarter

    I tried to create a rule for NOT PLAYING - like ...,value=!'PLAYING' or ...,value<>'PLAYING' - how is the syntax for this?

    What i really want is a TurnOff rule being activated when 'PLAYING' not has been active for 120 Seconds - what direction should i go for this?

     

     

    Please login or register to see this code.

     

    Link to comment
    Share on other sites

  • Topic Author
  • Please login or register to see this code.

    If the state is set to "PLAYING" it will call :on

    If the state is set to something else then "PLAYING" for 120s it will call :off

     

    Does that work for you?

    Link to comment
    Share on other sites

    29 minutes ago, jgab said:

    Please login or register to see this code.

    If the state is set to "PLAYING" it will call :on

    If the state is set to something else then "PLAYING" for 120s it will call :off

     

    Does that work for you?

    no - i tried the "1282:state=='PLAYING'" myself, but i fails. 

    And Yes to your answer if understood correct ;-)

    My triggers looks like this

    Please login or register to see this spoiler.

     

    [31.10.2021] [14:00:26] [DEBUG] [QUICKAPP1102]: ------------------------------------- Setting up rules (main) -------------------------------------
    [31.10.2021] [14:00:26] [ERROR] [QUICKAPP1102]: Error in '1282:state=='PLAYING' => 1074:on': ./include/EventRunner.lua:2057: attempt to index a nil value (field '?')
    [31.10.2021] [14:00:26] [ERROR] [QUICKAPP1102]: main() error:./include/EventRunner.lua:2369: Main() ERROR:./include/EventRunner.lua:2204: ./include/EventRunner.lua:2057: attempt to index a nil value (field '?')

    Edited by ChristianSogaard
    P
    Link to comment
    Share on other sites

    46 minutes ago, ChristianSogaard said:

    no - i tried the "1282:state=='PLAYING'" myself, but i fails. 

    And Yes to your answer if understood correct ;-)

    My triggers looks like this

    Please login or register to see this spoiler.

    This works

    rule("#device{id=1282,property='state',value='PLAYING'} => fibaro.call(1074, 'turnOn')")

     

    This Complie and Dont work - 1074:On is not working

    rule("#device{id=1282,property='state',value='PLAYING'} => 1074:On")

    This dont Compile - it dont like the state=='PLAYING'

    rule("1282:state=='PLAYING' =>fibaro.call(1074, 'turnOn')

     

    This Compile and Dont work, it dont show or trigger after 2 min..you see the "PAUSED_PLAYBACK" in line 4

    rule("trueFor(00:02,#device{id=1282,property='state',value~='PLAYING'}) => fibaro.call(1074, 'turnOff')")

    Please login or register to see this code.


     

     

     

    Link to comment
    Share on other sites

  • Topic Author
  • Hmm, I had forgot to add ':state' property to the rule engine.

     

    I pushed fix79. Try again with

    Please login or register to see this code.

     

    ':on' it's important that it's lower case letters. In your example you use ':On'

    x:on is translated to fibaro.call(x,"turnOn") so it must work.

    • Thanks 1
    Link to comment
    Share on other sites

    17 minutes ago, jgab said:

    Hmm, I had forgot to add ':state' property to the rule engine.

     

    I pushed fix79. Try again with

    Please login or register to see this code.

     

    ':on' it's important that it's lower case letters. In your example you use ':On'

    x:on is translated to fibaro.call(x,"turnOn") so it must work.

    Yes . Now it works .-)??

    Did you also see my response from last day ?

     

    Link to comment
    Share on other sites

  • Topic Author
  • 2 minutes ago, ChristianSogaard said:

    Yes . Now it works .-)??

    Did you also see my response from last day ?

     

    Yes, I'm restructuring my github directory now. 

    In fact there is a new repository named TQAE with the emulator and the most common QAs I have posted here - like EventRunner4 and ChildrenOfHue - all updated for TQAE - all packed in a directory where everything should work together.. ;-)

    Here is also the new version of EventRunner that's based on fibaroExtra.lua - I would not recommend to use it at the moment - I'm running it myself and try to catch the obvious bugs... I will announce in the EventRunner thread when it's time to switch...

    There is also a new plugin for ZBS to support TQAE and future features...

    In the TQAE post I have changed all links to the new repository, but I would recommend to pull the repository with a GitHub client (that way it's easy to update too) - or take down the TQAE.tar.gz archive

     

    • Thanks 1
    Link to comment
    Share on other sites

    55 minutes ago, jgab said:

     

    Yes, I'm restructuring my github directory now. 

    In fact there is a new repository named TQAE with the emulator and the most common QAs I have posted here - like EventRunner4 and ChildrenOfHue - all updated for TQAE - all packed in a directory where everything should work together.. ;-)

    Here is also the new version of EventRunner that's based on fibaroExtra.lua - I would not recommend to use it at the moment - I'm running it myself and try to catch the obvious bugs... I will announce in the EventRunner thread when it's time to switch...

    There is also a new plugin for ZBS to support TQAE and future features...

    In the TQAE post I have changed all links to the new repository, but I would recommend to pull the repository with a GitHub client (that way it's easy to update too) - or take down the TQAE.tar.gz archive

     

    Could you also make COH, so it will update from Github like EV4 :-) its a mess to upgrade because too many EV4 rules depends on the HUE device ID :-). And i found a few bugs in COH, and know it will take me hours to update ;-) when reinstalling COH

    • Like 1
    Link to comment
    Share on other sites

    There are technical tasks: in one room there is the warm floor , which is included in the collector, on the collector there are servodrives which we can close or open. A typical scheme in general.

     

    The room has a thermostat that is controlled by air temperature, it turns on / off our servodrives.

    Also in this room there is a thermostat that is controlled by the floor temperature, and it must also turn on or off our servodrive.

     

    The main requirement: that the floor was warm, that it did not overheat and was comfortable in the air.

     

    The option I see: for the AIR thermostat to control the native FIBARO climate panel( futher AIR CLIMAT PANEL). And here for the thermostat on a floor - to make management from ER4 that it was possible to control system as a whole dynamically.
    For example:

    1) Our AIR now has 20 degrees, and we need 22 degrees
    2) at the same time the FLOOR has 17 degrees, and we need comfortable from 22 to 28

    3)The AIR thermostat will turn on and will heat up to our SET 22, but at the same time we CANNOT overheat the floor more than 28

    4)When the air heats up to 22, the floor needs to be maintained in the range of 22-28 (from practice - somewhere 1.5-2 degrees more than the desired air temperature) ... that's where we need the ER4 to control the AIR CLIMAT PANEL.

     

    Question: how to change the climate panel from ER4?

    Link to comment
    Share on other sites

  • Topic Author
  • 36 minutes ago, fastvd said:

    There are technical tasks: in one room there is the warm floor , which is included in the collector, on the collector there are servodrives which we can close or open. A typical scheme in general.

     

    The room has a thermostat that is controlled by air temperature, it turns on / off our servodrives.

    Also in this room there is a thermostat that is controlled by the floor temperature, and it must also turn on or off our servodrive.

     

    The main requirement: that the floor was warm, that it did not overheat and was comfortable in the air.

     

    The option I see: for the AIR thermostat to control the native FIBARO climate panel( futher AIR CLIMAT PANEL). And here for the thermostat on a floor - to make management from ER4 that it was possible to control system as a whole dynamically.
    For example:

    1) Our AIR now has 20 degrees, and we need 22 degrees
    2) at the same time the FLOOR has 17 degrees, and we need comfortable from 22 to 28

    3)The AIR thermostat will turn on and will heat up to our SET 22, but at the same time we CANNOT overheat the floor more than 28

    4)When the air heats up to 22, the floor needs to be maintained in the range of 22-28 (from practice - somewhere 1.5-2 degrees more than the desired air temperature) ... that's where we need the ER4 to control the AIR CLIMAT PANEL.

     

    Question: how to change the climate panel from ER4?

     

    There are already support for dealing with individual thermostats (setting setPoints etc).

    If you want to deal with the climate panel directly it could be possible. The question is only what model to use when interacting with it.

    It's all divided  up in "climate zones" and you can modify the properties of them, including the weekday schedules.

    It's easy to add the code but I'm afraid it will be complex to use.

    Please login or register to see this code.

     

    Link to comment
    Share on other sites

    could you for example like with ER4?
    1) read through the API the current set temperature, say from the climate zone with ID 3
    2) let's say the set temperature in the zone of ID 3 is now 20, and we want to change through the API it to 23?

    Thanks!

    Link to comment
    Share on other sites

  • Topic Author
  • 7 minutes ago, fastvd said:

    could you for example like with ER4?
    1) read through the API the current set temperature, say from the climate zone with ID 3
    2) let's say the set temperature in the zone of ID 3 is now 20, and we want to change through the API it to 23?

    Thanks!

    Yes, but it's a temperature for morning/day/evening/night and for each day.

    If you discover that now , tuesday morning, its too high, do you change it for just tuesday morning, or for other subsequent time periods too? (it may be just a few minutes before the next time slot so changing the current may not make a difference)

    Link to comment
    Share on other sites

    for example:
    we have only 1 zone in the climate panel and only 1 temperature in the 1 zone for all day (all 4 Setpoints have the same temperature), and all days have the same temperature, but we turn to Monday, zone ID 1, Setpoint 1

    Edited by fastvd
    Link to comment
    Share on other sites

    Guest kallecux

    Control of light scenarios

     

    Hello!
    I would like to control my lighting scenarios with ER4. To do this, I can, for example, switch on certain lamps in the morning at 6:20 a.m. and switch them off again at 8:00 a.m. Everything OK

     

    rule ("@06:20 => 66: value = 0; 66:on; 66:dim = {00:01:00, 'up', 00:00:01, 'Linear', 0.99}")

     

    But now I would like to start this rule manually (at a different time) via the YUBI app. To do this, I would have to trigger the rule "from outside". How can I do this with ER4? Or is there a smarter way to go about it?

     

    Greetings

    Karl Heinz 

    Link to comment
    Share on other sites

  • Topic Author
  • There are 2 ways to do  it.

    1. Add a button to the  ER4 QA.

    If  we add a button with id 'Test' and onReleased 'FEventRunner4' it will send the event (thee QA id  was 3101)

    {"type":"UI","value":[3101],"event":"onReleased","id":3101,"name":"Test"}

    This means we can do rules like

    Please login or register to see this code.

    This means we can either press the Test button or wait for 06:20 and we carry out the "morning routine".

     

    2. Create a  separate QA with

    Please login or register to see this code.

    and bind the function to a button. This will post the #morning event to the ER4 QA when the button is pressed. 

     

    and keep the 2 last rules in the ER4

    Please login or register to see this code.

     

     

     

    Edited by jgab
    Link to comment
    Share on other sites

    On 11/1/2021 at 7:50 PM, fastvd said:

    for example:
    we have only 1 zone in the climate panel and only 1 temperature in the 1 zone for all day (all 4 Setpoints have the same temperature), and all days have the same temperature, but we turn to Monday, zone ID 1, Setpoint 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
    Reply to this topic...

    ×   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.

    ×
    ×
    • Create New...