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


Search the Community

Showing results for tags 'tibber'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • FIBARO Community
    • FIBARO Portal and Forum policy
    • FIBARO
    • Say hello!
    • Off-topics
  • FIBARO Update
    • FIBARO System Update
    • FIBARO Mobile Update
  • FIBARO Community Support
    • Scenes and Interface
    • FIBARO Products
    • FIBARO Mobile
    • FIBARO HomeKit
    • FIBARO Assistant Integrations
    • Other Devices / Third-party devices
    • Tutorials and Guides
    • Home Automation
    • Suggestions
  • FIBARO Społeczność
    • FIBARO
    • Przywitaj się!
    • Off-topic
  • FIBARO Aktualizacja
    • FIBARO System Aktualizacja
    • FIBARO Mobile Aktualizacja
  • FIBARO Wsparcie Społeczności
    • Sceny i Interfejs
    • FIBARO Urządzenia
    • FIBARO Mobilnie
    • FIBARO HomeKit
    • Integracja z Amazon Alexa i Google Home
    • Urządzenia Firm Trzecich
    • Poradniki
    • Automatyka Domowa
    • Sugestie

Categories

  • Scenes
  • Virtual Devices
  • Quick Apps
  • Icons

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Facebook


Google+


Skype


Website URL


WhatsApp


Country


Gateway/s


Interests

Found 3 results

  1. This QuickApp gets your energy consumption and production data from Tibber Live. This QuickApp can be used in combination with the Tibber Monitor to get the Tibber Prices. Based on the Fibaro WebSockets/GraphQL demo by Peter Gebruers If you use Tibber for your Energy Panel, you can use this Tibber Live QuickApp for your energy consumption and production combined with the Tibber Monitor QuickApp to provide the Energy Panel with the hourly prices. Main device with positive or negative actual power consumption Child devices are available for: power (Actual consumption with maxPower in log text) powerProduction (Actual production with maxPowerProduction in log text) accumulatedConsumption (Todays consumption, also the child device for the Energy Panel) accumulatedProduction (Todays production) accumulatedCost (Todays cost) accumulatedConsumptionLastHour (Consumed since since last hour shift) accumulatedProductionLastHour (Produced since last hour shift) lastMeterConsumption (Total consumption) lastMeterProduction (Total production) voltagePhase1 voltagePhase2 voltagePhase3 currentL1 currentL2 currentL3 Available information: power (Consumption at the moment (Watt)) maxPower (Peak consumption since midnight (Watt)) powerProduction (Net production (A-) at the moment (Watt)) maxPowerProduction (Max net production since midnight (Watt)) accumulatedConsumption (kWh consumed since midnight) accumulatedProduction (net kWh produced since midnight) accumulatedCost (Accumulated cost since midnight; requires active Tibber power deal) currency (Currency of displayed cost; requires active Tibber power deal) lastMeterConsumption (Last meter active import register state (kWh)) lastMeterProduction (Last meter active export register state (kWh)) voltagePhase1 (Voltage on phase 1) * voltagePhase2 (Voltage on phase 2) * voltagePhase3 (Voltage on phase 3) * currentL1 (Current on L1) * currentL2 (Current on L2) * currentL3 (Current on L3) * accumulatedConsumptionLastHour (kWh consumed since since last hour shift) accumulatedProductionLastHour (net kWh produced since last hour shift) accumulatedReward (Accumulated reward since midnight; requires active Tibber power deal) minPower (Min consumption since midnight (Watt)) averagePower (Average consumption since midnight (Watt)) powerReactive (Reactive consumption (Q+) at the moment (kVAr)) * powerProductionReactive (Net reactive production (Q-) at the moment (kVAr)) * minPowerProduction (Min net production since midnight (Watt)) maxPowerProduction (Max net production since midnight (Watt)) powerFactor (Power factor (active power / apparent power)) * signalStrength (Device signal strength (Pulse - dB; Watty - percent)) * timestamp (Timestamp when usage occurred) * on Kaifa and Aidon meters the value is not part of every HAN data frame therefore the value is null at timestamps with second value other than 0, 10, 20, 30, 40, 50. There can be other deviations based on concrete meter firmware. In this QuickApp "null" values are replaced by their previous values. To communicate with the API you need to acquire a OAuth access token and pass this along with every request passed to the server. A Personal Access Token give you access to your data and your data only. This is ideal for DIY people that want to leverage the Tibber platform to extend the smartness of their home. Such a token can be acquired here: https://developer.tibber.com When creating your access token or OAuth client you’ll be asked which scopes you want the access token to be associated with. These scopes tells the API which data and operations the client is allowed to perform on the user’s behalf. The scopes your app requires depend on the type of data it is trying to request. If you for example need access to user information you add the USER scope. If information about the user's homes is needed you add the appropriate HOME scopes. If you have more than one home in your subscription, you need to fill in your home number the change between your homes. If the Tibber server disconnects the webSocket, the QuickApp wil do a re-connect for the amount in the QuickApp variable reconnect. If the re-connect fails for that amount, there will be a timeout for the seconds in the QuickApp variable timeout. Use this QuickApp at your own risk. You are responsible for ensuring that the information provided via this QuickApp do not contain errors. Tibber is a registered trademark being the property of TIBBER. TIBBER reserves all rights to the registered trademarks. Information which is published on TIBBER’s websites belongs to TIBBER or is used with the permission of the rights holder. Making of copies, presentations, distribution, display or any other transfer of the information on the website to the public is, except for strictly private use, prohibited unless done with the consent of TIBBER. Published material on dedicated TIBBER press websites, intended for public use, is exempt from the consent requirement. Also see: https://tibber.com/en/legal-notice Guide Communicating with the Tibber API: https://developer.tibber.com/docs/guides/calling-api Tibber API Explorer: https://developer.tibber.com/explorer Tibber gitHub: https://github.com/tibber Tibber SDK NET: https://github.com/tibber/Tibber.SDK.NET/tree/master/src/Tibber.Sdk Fibaro webSocket manual: https://manuals.fibaro.com/knowledge-base-browse/hc3-quick-apps-websocket-client/ Fibaro Forum - Headers in webSocket: https://forum.fibaro.com/topic/60307-added-support-for-headers-in-websocket-connections-any-documentation WebSocket++ Documentation: https://docs.websocketpp.org GraphQL over WebSocket Protocol: https://github.com/enisdenjo/graphql-ws/blob/master/PROTOCOL.md GraphQL query language: https://spec.graphql.org/June2018/#sec-Language Version 3.0 (8th March 2023) Removed Tibber old Websocket code Prepared, not enabled: Check home.features.realTimeConsumptionEnabled has a true value always before reconnecting Prepared, not enabled: Added button to disconnect or re-connect the Tibber webSocket Prepared: Added quickapp variable homeNr (most of the time 1) to be able to check the response realTimeConsumptionEnabled Version 2.3 (beta 8th December 2022) Improved the 60 seconds interval child devices update, it now never skips a beat Added translation for English (en), Dutch (nl), Swedish (se), Norwegian (no) Changed the json response for the debugLevel=4 Offline Simulation mode, the date/time format was wrong Added random (jitter) reconnection handleDisconnected and handleError between 10 and 15 seconds Added random (jitter) reconnection interval handleDisconnected and handleError plus between 1 and 10 seconds Added exponential backoff (increasing delay) between each timeout. The increase is limited to 10 times the value in the quickapp reconnect variable. Version 2.2 (20th November 2022) Changed to new Tibber webSocket requirements, required from December 2022 Version 2.1 (15th October 2022) Child devices are now updated every (whole) minute to reduce CPU load Replaced zero values for Voltage L1 L2 L3 with the previous value Version 2.0 (5th August 2022) Added two child devices, Hourly Consumption and Hourly Production Added re-connect routine to handleError. If an Tibber error occurs, the QuickApp will try to re-connect. Thanks @JcBorgs for testing. Improved routine to handle Tibber null values. Thanks @Darquan for testing. Changed labels a bit to save some space Changed "volt" and "amp" text in the labels. Thanks @Morten22 for mentioning. Changed kWh device types from com.fibaro.electricMeter to com.fibaro.energyMeter Version 1.0 (19th June 2022) Initial webSocket version Tibber Live Thanks @JcBorgs for testing all beta versions and great suggestion to improve the quickapp Based on the Fibaro WebSockets/GraphQL demo by @petergebruers Variables (mandatory and created automatically): token = Authorization token (see the Tibber website: https://developer.tibber.com) homeId = Tibber Home ID (see the Tibber website: https://developer.tibber.com) homeNr = Tibber home (nodes) number if you have more than one home (default = 1) language = Preferred language (default = en) (supported languages are English (en), Swedisch (se), Norwegian (no) and Dutch (nl)) reconnect = Amount of re-connects after disconnect from Tibber server (default = 10) timeout = Pause after maximum amount of re-connects (default = 300 seconds) debugLevel = Number (1=some, 2=few, 3=all, 4=Offline Simulation Mode, 5=Live Test Mode) (default = 1) Fibaro Firmware: Minimal version 5.111.48 (beta) Download the QuickApp here (download the file and un-zip): https://github.com/GitHub4Eddy/tibber_live/archive/refs/tags/tibber-live-30.zip or from the Fibaro Marketplace: https://marketplace.fibaro.com/items/tibber-live How to install: Open the Configuration Interface Go to Settings > Devices Click + Choose Other Device Choose Upload File Choose file from your computer with .fqa
  2. This QuickApp calculates the cheapest prices for using appliances based on the hourly Tibber energy prices. This QuickApp is especially useful for appliances (like charging your car and washing the dishes) that need to run once a day, within a timeframe and during some hours. You can use more than one instance of this QuickApp if you need more than one appliance to start in the cheapest hour but not within the same timeslot. Tibber today and tomorrow prices The tomorrow prices are available from 13:00 hour. If the tomorrow prices aren't available yet and the timeslot is (partially) tomorrow, a temporary calculation and start-stop plan is made with the today prices, until the tomorrow prices are available. If the start time plus duration is (partially) tomorrow, for example start time 18:00 and duration 7 hours, the calculation can be made from 13:00 hour when the tomorrow prices are available. At 04:00 the binary switch will turn ON and at 07:00 the binary switch will turn OFF. You would still have to create a script, triggers by this binary switch, to actually turn on the charging of your car, or turn on the dishwasher. IMPORTANT This QuickApp needs the Tibber Monitor QuickApp to run on your HC3. It is important to synchonise this QuickApp with the timing of your Tibber Monitor QuickApp. This QuickApp works at its best, if you setup the interval with the intervalOffset just after the Tibber Monitor runs. If you Tibber Monitor runs at 5 minutes (300 seconds) after the whole hour, run this QuickApp 5 minutes and 10 seconds (310 seconds) after the whole hour to be sure to get the prices from Tibber Monitor. This QuickApp runs every whole hour to turn the switch on and off. If it is time to get the prices from the Tibber Monitor QuickApp, this QuickApp runs every whole hour plus the seconds set in the intervalOffset. QuickApp logics onInit() getQuickAppVariables() --> Get all Quickapp Variables or create them createVariables() --> Create all Variables checkPrice() --> Determine the cheapest cycle of hours missionControl() --> The central loop If tibberChild0000 (Tibber Monitor Child devicenumber for "Today 00:00") doesn't exists --> disable QuickApp If current hour is hour to start --> turn the switch ON If current hour is hour to stop --> turn the switch OFF If current hour is 13:00 (tomorrowPrices) --> checkPrice() to check the prices again to calculate with the tomorrow prices and to plan a new start and stop hour If current hour is the end of the timeslot --> checkPrice() to check the prices again to plan a new start and stop hour If current hour is 00 and the timeslot doesn't goes through midnight (timeSlotStart < timeSlotEnd) --> checkPrice() to transfer the tomorrow prices to todays prices updateLabels() every whole hour missionControl() (see above) etc DISCLAIMERS Use this QuickApp at your own risk. You are responsible for ensuring that the information provided via this QuickApp do not contain errors. Tibber is a registered trademark being the property of TIBBER. TIBBER reserves all rights to the registered trademarks. Information which is published on TIBBER’s websites belongs to TIBBER or is used with the permission of the rights holder. Making of copies, presentations, distribution, display or any other transfer of the information on the website to the public is, except for strictly private use, prohibited unless done with the consent of TIBBER. Published material on dedicated TIBBER press websites, intended for public use, is exempt from the consent requirement. Also see: https://tibber.com/en/legal-notice Tibber API documentation: https://developer.tibber.com/docs/guides/calling-api Tibber API explorer: https://developer.tibber.com/explorer Tibber status: https://status.tibber.com Variables (mandatory and created automatically) tibberChild0000 = The Tibber Monitor Child devicenumber for "Today 00:00" durationHours = How many hours should the switch be ON (not more than 23 hours) timeSlotStart = At which hour should the timeslot start timeSlotEnd = At what hour should the timeslot end tomorrowPrices = At what hour are the Tibber tomorrow prices available (default = 13) setGlobalVar = true or false, whether you want tu use the Global Variables (default = false) intervalOffset = The offset time in seconds to the interval of every whole hour (default 310 seconds) debugLevel = Number (1=some, 2=few, 3=all (default = 1) language = Preferred language (default = English (en)) (supported languages are English (en), Dutch (nl), German (de), Swedish (se) and Norwegian (no)) Changes version 1.0 (20th June 2024) Added two global variables for the time ON and time OFF. To use them, set the QuickApp variable setGlobalVar to true. Added an extra check at midnight if the timeslot doesn't goes through midnight (timeSlotStart < timeSlotEnd) to transfer the tomorrow prices to todays prices (after midnight) Solved a bug with a timeslot starting at the next day 23:00. Changed the label layout in case the prices aren't available yet. Changed the time tomorrow prices calculations will take place to hh:mm:ss in stead of "13:00 (+310 seconds)" Changes version 0.3 (19th March 2024) Solved a small bug when timeslot end was greater than 23 hours Changes version 0.2 (15th February 2024) Optimized calculations and turnOn/TurnOff Added translations for Dutch (nl), German (de), Swedish (se) and Norwegian (no) Initial (beta) version 0.1 (11th February 2024) Initial beta version How to install Open the Configuration Interface Go to Settings > Devices Click + Choose Other Device Choose Upload File Choose file from your computer with .fqax Tibber_Trigger-10.fqax
  3. This is a Quickapp script for HC3. I am trying to get this to work in a VD on HC2. Is it possible, or do I have to do it together with a scene to make it work? Can anyone help? function QuickApp:onInit() self:updateProperty("unit", "kr/kWh") self.refresh = 60 -- in seconds local function loop() self:webrequest(); setTimeout(loop,self.refresh * 1000) end if self.username ~= "changeme" then loop() end end function QuickApp:webrequest() local tid = os.date("%R") local minutt = os.date("%M") --OPPDATERER STRØMPRIS OG SNITT HVER TIME if (minutt == "00") then self:OppdaterPris(); self:OppdaterSnitt(); end end function QuickApp:OppdaterPris() --Opprette lokale variable local GammelStrompris = fibaro.get(126,"value") local NyStrompris --Definerer http local http = net.HTTPClient(); --Definerer strengen Payload til å være kommando til tibber local payload = '{"query": "{viewer {homes {currentSubscription{priceInfo{current{total}}}}}}", "variables": null, "operationName": null}'; --API.POST til Tibber-- http : request('https://api.tibber.com/v1-beta/gql', { options = { method = "POST", headers = { ['Authorization'] = '.........', --Min Tibber ID her. ['Content-Type'] = 'application/json' }, data = payload -- Query. }, success = function(response) --fibaro.debug (response.data) --Verifiser at en har fått response.data. Dette er data som en har fått fra Tibber local data = json.decode(response.data); --fjernet local under??? NyStrompris = json.encode(data.data.viewer.homes[1].currentSubscription.priceInfo.current.total); self:updateProperty("value", tonumber(NyStrompris)) --print("OK") end, error = function(err) fibaro.debug ("Error:" .. err) end }); end function QuickApp:OppdaterSnitt() --Definerer http local http = net.HTTPClient(); --Definerer strengen average til å være kommando til tibber local average = '{"query": "{viewer {homes {currentSubscription{priceRating{daily{entries{total}}}}}}}", "variables": null, "operationName": null}'; --API.POST Til Tibber http : request ('https://api.tibber.com/v1-beta/gql', { options = { method = "POST", headers = { ['Authorization'] = '...............', --Min Tibber ID her. ['Content-Type'] = 'application/json' }, data = average -- Query }, success = function(response) --fibaro.debug(response.data) --Verifiser at en har fått response.data. Dette er data som en har fått fra Tibber local data = json.decode(response.data); local Nypris = tostring(json.encode(data.data.viewer.homes[1].currentSubscription.priceRating.daily.entries[31].total)); self:updateProperty("log", tostring(Nypris)) end, } ) end
×
×
  • Create New...