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


Remi

Member
  • Posts

    121
  • Joined

  • Last visited

About Remi

Profile information

  • Country
    Netherlands
  • Gateway/s
    Home Center 2

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Remi's Achievements

Learner

Learner (2/8)

11

Reputation

1

Community Answers

  1. Thanks @Sankotronic, Thats working for me too. greets, Remi
  2. Hi All, Does someone perhaps know how to check the status of a Fibaro rollershutter using LUA? I want to know if a rollershutter is up or down and use that as a condition in a scene. I tried fibaro:getValue(92, "value") but that seem to result in "0" always. greets, Remi
  3. Wow that did the trick indeed! Thank you very much, i would never have thought of that.
  4. Hi @Sankotronic, Mmm, you could be on the right track with that. I've been tweaking the scene quite a bit lately, and the original scene had my global variable included in the header. Let me try a restart and see.
  5. Until today i was convinced scene's are triggered by devices or variables i put in the upper section in the LUA script. I have a scene where i put in some actions when my wife leaves the house. If her variable change the scene should run. Her variable is "Ilse" and can be "Away" or "Home". But i noticed the scene also runs when my variable "Remi" change status Home or Away. The only variable in the upper section is her's and not mine, so i dont understand why the scene is running when my variable change? The following variable's are used in the script: Ilse (Which can be Home or Away Remi (Which van be Home or Away) Rollershuttercount (Which can be 0 or 1 and is used as a flag to limit opening automatitaclly the rollershutter to one's a day, and is reset during the night by a "Maintance scene") --[[ %% properties %% weather %% events %% globals Ilse --]] local date = os.date(); local ct=os.date("%H:%M",os.time()) -- debugging function in color function logbug(color, message) for line in message:gmatch("[^\010\013]+") do local txt = line:gsub("([\038\060\062])", function(c) return "&#"..string.byte(c)..";" end) fibaro:debug(('<span style="color:%s">%s</span>'):format(color,txt)) end end if fibaro:getGlobalValue("Ilse")=="Away" and fibaro:getGlobalValue("Remi")=="Away" and fibaro:getGlobalValue("Rollershuttercount")=="0" and (ct>="07:00" and ct<"14:00") then fibaro:debug(date); fibaro:call(92, "open") fibaro:setGlobal("Rollershuttercount","1") setTimeout(function() fibaro:call(95, "turnOff") --Main lamp fibaro:call(98, "turnOff") --Spot lamp Remi fibaro:call(101, "turnOff") --Spot lamp Ilse fibaro:call(104, "turnOff") -- Walli WCD end, 22000) logbug("green", "Rollershutter open and lights off.") else if fibaro:getGlobalValue("Ilse") == "Away" then fibaro:debug(date); fibaro:call(95, "turnOff") --Main lamp fibaro:call(98, "turnOff") --Spot lamp Remi fibaro:call(101, "turnOff") --Spot lamp Ilse fibaro:call(104, "turnOff") -- Walli WCD logbug("green", "Lights off") end end The reason why my variable is in the scene is, because the rollershutter is of our bedroom. When i have a day off i like to sleep a bit longer and dont want to wake up because the rollershutter goes up automatically when she leaves the house.
  6. @Jumpson , Did you check the manual already? https://manuals.fibaro.com/intercom/
  7. Thank you for your reply. At the moment i am at work. I will try it out later today when i come home.
  8. I cant acces my HC2 from the portal either. Not sure if its country related, but i'm from the Netherlands.
  9. Hi @Sankotronic, Its working great now! Thanks again
  10. Thank you so much @Sankotronic , Going to try it out and will let you know the result tomorrow If this works i am very happy since i am not an advanced programmer (Far from...) and this makes it so much more readable for me.
  11. Hello guys, I need some help with a script i made, hopefully you can point me in the right direction. I made a script which should open the rollershutter of the bedroom of my son when he leave home. But it doesnt seem to work well. I was wondering if this is because of the construction i made to descide if a specific time is within a time range? I use three conditions to descide the rollershutter should open or not. a Home/Away variable A variable which can be 0 or 1 to assure the rollershutter goes open only ones a day automaticaly. If the variable is 1 it should skip the action (this variable is reset to 0 at night) A time range of 07.00 - 13.00h. If my son leave the house within that time range the rollershutter should open. --[[ %% properties %% weather %% events %% globals Yannick --]] local date = os.date(); local currentDate = os.date("*t"); if ( ( fibaro:getGlobalValue("Yannick") == "Away" ) and tonumber(fibaro:getGlobalValue("Shuttercount_Y") == 0 ) and (tonumber(os.date("%H%M")) >= tonumber(string.format("%02d%02d", "07", "00")) or (tonumber(os.date("%H%M")) < tonumber(string.format("%02d%02d", "13", "00"))))) then fibaro:call(120, "open"); -- Rollershutter fibaro:setGlobal("Shuttercount_Y", "1"); end Thanks you in advance, Remi
  12. That are indeed good use cases and things what i always was wondering too. The last time a sensor reported a value. Or even with a global variable! I thought that wasnt possible. Great stuff to learn For sure going to give it a try to use this. Thanks!
  13. Thanks @Sankotronic I learn alot today I gues i can use UNIX format the same way if i want to compare moments in time with > or <= etc...? In my specific use case, since the variable 'sunriseHour' is already in normal time format it seems a extra step to convert it to UNIX first. When do UNIX format benefit over normal time notation? In a more complex scene?
  14. Thanks @Sankotronic glad to see normal time notation can work too. Altho i understand the conversion to seconds too, normal time notation is a bit more noob friendly to me ?
  15. Thanks, i will have a look at that later. But to be honest that look quite overwhelming ?
×
×
  • Create New...