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

SmartHomeEddy

Question


This Quickapp retrieves energy consumption, energy production, gas and water usage from the (P1 Monitor) energy, gas and water meter. 
This Quickapp uses the software of ztatz.nl to get the values from your smart energymeter. 
The ztatz plug-and-play software can run on a Raspberry Pi or in a Docker container. 

 

The Energy consumption and energy production are added to the HC3 energy panel. 
Use the child devices Todays Consumption and Todays Production to store energy data (kWh) in the Energy Panel. 
And use the child devices Consumption and Production for instantaneous power (Watt) in the Energy Panel calculations. 

 

 

Please login or register to see this attachment.

 

Child Devices for:

  • Consumption (Watt) (input for instantaneous power in Energy Panel calculations)
  • Production (Watt) (input for instantaneous power in Energy Panel calculations)
  • Todays Consumption (kWh) (input for energy panel)
  • Todays Production (kWh) (input for energy panel)
  • Waterflow (Liter)
  • Consumption High (kWh)
  • Consumption Low (kWh)
  • Production High (kWh)
  • Production Low (kWh)
  • Consumption L1 (Watt)
  • Consumption L2 (Watt)
  • Consumption L3 (Watt)
  • Production L1 (Watt)
  • Production L2 (Watt)
  • Production L3 (Watt)
  • Ampere L1 (Amp)
  • Ampere L2 (Amp)
  • Ampere L3 (Amp)
  • Voltage L1 (Volt)
  • Voltage L2 (Volt)
  • Voltage L3 (Volt)
  • Total Gas (m³)
  • Total Waterflow (m³)

 

Please login or register to see this image.

/monthly_2021_08/P1-monitor-1.png.98df79a87caffc2b6a1bc8e44bc86bf1.png" />   

 

Please login or register to see this attachment.


 

 

Interval: 
It is possible to process messages from the smart meter every second. Of course, this is only possible if the smart meter actually sends a message every second. This can be turned on via the ztatz software P1 port configuration page via the "maximum processing speed" option. Note that this gives a higher load on the Rpi (or Docker). It has been tested on the Rpi3/Rpi4 and works well on it. Older or other RPIs have not been tested.

The P1 Monitor QuickApp uses 2 API calls each cycle, and if you also use Waterflow, 3 API calls each cycle. With an interval setting of 10 seconds there is an API call every 5 seconds (and with Waterflow enabled, every 3.33 seconds). So the fastest interval setting will probably be 3 seconds with Waterflow and 2 seconds without Waterflow. 

 

Ztatz software:

Please login or register to see this link.

Docker container based on the ztatz.nl software: The container version has the same functionality as the full version for the Raspberry Pi. Docker container:

Please login or register to see this link.

 

I use a Raspberry Pi Smart Meter Cable Starter Kit

  • Raspberry Pi 4 Model B Rev 1.1 2GB
  • 32GB Micro SDHC
  • Smart Meter cable 
  • P1 Monitor software from: 

    Please login or register to see this link.

     
  • Water Flow Sensor (M18 8mm sensing DC 5V NPN NO LJ18A3-8-Z/BX-5V cylinder inductive proximity sensor switch work voltage 5VDC special for MCU)

 

 

 

903B0D58-BD03-487D-B599-093590680363.jpeg.4c5501ca5fafa28892e0ac7c64e2c722.jpeg             waterflow-sensor.png.c6d38b52168dc6cd5e9aa0f0add2893f.png

 

Version 2.0 (8th January 2023)

  • Changed child device types for optimal support of the Energy Panel: 
    •   kWh -> com.fibaro.energyMeter
    •   ampere/voltage -> com.fibaro.electricMeter
    •   Watt -> com.fibaro.powerMeter
    •   gas -> com.fibaro.gasMeter
    •   water -> com.fibaro.waterMeter
  • Removed Power device calculation
  • Removed child devices for gross consumption and device consumption
  • Changed code to multi file
  • Added for translations for English, French, Polish and Dutch

 

Version 1.6 (8th January 2022)

  • Changed the waterflow algoritme to show more stable and more acurate measurements
  • Small change in the code for checking existance of waterflow sensor
  • Changed the Waterflow unit from Liter to L/min
  • Added experimental net consumption to power 
  • Added Lasthour gas to labels
  • Changed the API request for status to json output


Version 1.5 (4th September 2021)

  • Support of new Energy Panel: 
    • Changed Child device Net Consumption to Main device with type com.fibaro.powerSensor (value can be positive or negative)
    • Added Child device Todays Consumption to show the daily energy consumption in kWh
    • Added Child device Todays Production to show the daily energy production in kWh
    • Changed Child device Consumption High and Low to com.fibaro.energyMeter (kWh in property "value"; "rateType" = consumption). These values will be shown in the new energy panel. 
    • Changed Child device Production High and Low to com.fibaro.energyMeter (kWh in property "value"; "rateType" = production). These values will be shown in the new energy panel. 
    • Added automaticaly change rateType interface of Child device Consumption High and Low to "consumption" and Production High and Low to "production
    • Changed Child device Consumption and Production to type com.fibaro.powerSensor (Watt) to show power graphs
    • Changed Child device Consumption L1, L2 and L3 and Production L1, L2 and L3 to type com.fibaro.powerSensor (Watt) to show power graphs
  • Additional changes:
    • Added todays Maximum consumption and todays Maximum production and timestamp to the label text and Child device log text
    • Added todays Maximum consumption and todays Maximum production automatic format measurement to W, Kw, MW or GW
    • Added todays Consumption low and high (kWh) and todays Production low and high (kWh) to the label text and Child devices log text
    • Added todays Consumption of gas in the label text and Child device log text
    • Added Timestamp in format dd-mm-yyyy hh:mm:ss to log of Main device and labels
    • Placed production below consumption in the labels
    • Solved bug when Production is higher than Consumption with calculation of Gross Consumption (Gross Consumption = Net Consumption minus or plus Device Consumption)

 

Version 1.4 (11th April 2021)

  • Added Child Devices Waterflow and Total Waterflow

 

Version 1.3 (13th February 2021)

  • Added Child Devices for Voltage L1 L2 L3

 

Version 1.2 (6th February 2021)

  • Added a lot of Child Device

 

Version 1.1 (18th January 2021)

  • Solved a bug when powerID = 0

 

Version 1.0 (15th Januari 2021)

  • Changed routine te get Energy Device ID's fast (no more maxNodeID needed)
  • Added "Update Devicelist" button to update the Energy devicelist
  • Added Tarifcode High and Low (and empty for flat fee)
  • Rounded Consumption and Production to zero digits Watt
  • Added Quickapp variable for debug level (1=some, 2=few, 3=all). Recommended default value is 1. 
  • Re-aranged the labels
  • Cleaned up some code

 

Version 0.3 (16th August 2020)

  • Added Quickapp variables for easy configuration
  • Added Power Production
  • Changed method of adding QuickApp variables, so they can be edited


Tested on

  • P1 Monitor version: 20221105 V2.1.0
  • Raspberry Pi model: Raspberry Pi 4 Model B Rev 1.1
  • Linux-5.15.74-v7l+-armv7l-with-glibc2.31
  • Python version: 3.9.2

 

QuickApp variables (mandatory, they will be automatically added with the default values):

  • IPaddress = IP address of your P1 monitor
  • interval = Number in seconds, the P1 Monitor normally is updated every 10 seconds, sometimes even faster
  • debugLevel = Number (1=some, 2=few, 3=all) (default = 1)
  • waterMeter = Existance of watermeter true or false (default = false)
  • language = Preferred language (default = en) (supported languages are Engish (en), French (fr), Polish (pl) and Dutch (nl))

 

Download the QuickApp here (download the file and un-zip):

Please login or register to see this link.

or Fibaro Marketplace: 

Please login or register to see this link.

 

P1-monitor-logo.png.c3a78cf6227528f64f6a2aa204b1e5c9.png

 

How to install: 

  1. Open the Configuration Interface
  2. Go to Settings > Devices
  3. Click  +
  4. Choose Other Device
  5. Choose Upload File
  6. Choose file from your computer with .fqa

 

 

 

 

 

Edited by SmartHomeEddy
  • Like 3
Link to comment
Share on other sites

Recommended Posts

  • 0
  • Inquirer
  • On 2/14/2021 at 6:42 PM, SmartHomeEddy said:

    The only measurement left, is the Water Flow. Is anyone using a Water Flow Sensor?

     

     

    I do now, so soon to come: Water Flow Device

    ?


    Please login or register to see this attachment.


     

     

    • Like 2
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Please login or register to see this attachment.



     

    Please login or register to see this attachment.


     

    Please login or register to see this link.


     

     

     

    this should do the job: 

     

    € 3,98 | M18 8mm sensing DC 5V NPN NO LJ18A3-8-Z/BX-5V cylinder inductive proximity sensor switch work voltage 5VDC special for MCU

    Please login or register to see this link.

     

     
     

    € 5,95  6% Off | 20pcs PCB Prototype Board Circuit Protoboard Universal Stripboard Prototyping Veroboard 2X8 3X7 4X6 5X7 5Pcs Each Mixed Double

    Please login or register to see this link.



     

    € 0,66  4% Off | 10pcs/lot EL4N35 DIP-6 SMD-6 4N35 In Stock

    Please login or register to see this link.

     

     


    € 0,09  4% Off | 50pcs 1/4W Metal film resistor 1R ~ 1M 100R 220R 330R 1K 1.5K 2.2K 3.3K 4.7K 10K 22K 47K 100K 100 220 330 1K5 2K2 3K3 4K7 ohm

    Please login or register to see this link.


     

     

    € 0,50  10% Off | Dupont Line 10Cm Male to Male + Male to Female + Female to Female Jumper Wire Dupont Cable

    Please login or register to see this link.

     

    Edited by SmartHomeEddy
    • Like 1
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • and already integrated in P1 Monitor, soon to be released


    Please login or register to see this image.

    /monthly_2021_03/7B406317-8787-4889-BADA-37F9037C0AA4.jpeg.00fcc0c8cc12b3070eae37739cac53f7.jpeg" />  E16818A2-4958-4E1D-9CDA-F3006F8B3138.jpeg.988e892ad7b7a91579f96f356ea42ab2.jpeg

     

    Please login or register to see this attachment.


     

    Please login or register to see this attachment.


     

     

     

    Edited by SmartHomeEddy
    • Like 1
    Link to comment
    Share on other sites

    • 0

    Mooi project, houdertje voor de inductieve sensor 3d-printen en het is helemaal af.

     

    Please login or register to see this link.

     

    Please login or register to see this link.

     

    Heb bijna alle onderdelen uit China om hier ook eens mee aan de slag te gaan.

    • Like 1
    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Looks great but I don't have a 3D printer. Maybe I leave it this way, maybe I drill a hole in the cover. Someone suggested to just use some silicone sealant. It holds the sensor in its place and is still easy to remove, you can piel it off. 

    Link to comment
    Share on other sites

    • 0

    Drilling in property of the watercompany. I would be careful, if they accuse you of stealing water you will have a serious problem. 

    Currently I am focussed on the P1 part of your project, but if I get around to the watermeter part I can probably easily get you a 'copy' of the holder, depends on where you are in the Nethelands with shipping.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • Although it is only the cover, indeed I am somewhat holding back to drill that hole in the cover. 

     

    The P1 part of the Monitor should be do-able. The software from

    Please login or register to see this link.

     is technically plug-and-play on the Raspberry Pi, just upload it on a SD card and plug it in. Maybe you need to fill in some configurations in the software. 

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • 1 minute ago, claudent said:

    Hi, can you please share how you managed the formula (pulse/min into liter) in HC? Thanks


    I don’t have to, I take the easy road, the software from 

    Please login or register to see this link.

     does all of that (and more) and the QuickApp gets all the values with an API from the software.
     

    Additional I store all information from the HC3, so also energy usage, water flow, etc. to an Influx database to show fancy graphics in Grafana. 

    Link to comment
    Share on other sites

    • 0

    Thank you for the prompt reply, actually I am using a waterflow meter inserted in the waterpipe and pulses are collected via Fibaro Smart implant.

     

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • I also measure water flow (next to energy usage) and the pulses are (really) collected by the 

    Please login or register to see this link.

     software. And in this case collected in the way of measuring the pulses, calculating them to liters, adding them to a total usage and storing the results. Those results are available via an interface to get them in the HC3. 

    Link to comment
    Share on other sites

    • 0

    I get the point. First I started with an Esp8266, but hard to send data to HC3, i have decided to use the FB smart implant

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • 18 minutes ago, claudent said:

    started with an Esp8266, but hard to send data to HC3


    It is more easy to get data with the HC3 from the ESP8266 platform, then to send data from the platform to the HC3. I use ESP8266 boards for air quality sensors, they are cheap and work great for that purpose (and with already build software from sensor.community). 

     

    For energy and water measurement you can start from scratch with a smart implant, but I prefer to use the great ideas of others. And I know for sure I can’t do a better job. The builder of

    Please login or register to see this link.

     spend a lot of time to make great (free) software. So you must have a lot of reasons, to start from scratch. 
     

    For the price of a Smart Implant, you can also buy a Raspberry Pi. For more money, you can buy a Iungo sensor with build in software. All of them communicate with the HC3 with already build QuickApps. 

    But I am still curious how to use a smart implant to do the job. So I follow the post with great interest. 

    Link to comment
    Share on other sites

    • 0
    On 3/3/2020 at 9:26 PM, SmartHomeEddy said:

    Found it ?

    Hi, 

    I am using qubino smartmeter for electricity, actually I can see the consumption values in HC3, but what is strange is that i do not get Watt value where it is supposed to be therefore when running scene, no data is saved to influxdb. Is there something that needs to be adjusted? tks.

    Please login or register to see this attachment.

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • I don’t know how the Qubino itself works, I don’t use it. Indeed to write a value to Influx, you need a value in the device. 
     

    With the construction of the P1 Monitor QuickApp I have full control what to write to the values of all child devices. I think that is not the case with Qubino. In other post I have read some issues with Qubino in combination with the Homecenter. 
     

    I like the control via the QuickApp. In the QuickApp I calculate for example all power consumption of the devices in the Homecenter, or for example I put the power usage of non-devices in a (spare) device to see the overall power consumption in the homecenter. 
     

    It is a different approach to the Qubino. 

    Link to comment
    Share on other sites

    • 0
  • Inquirer
  • If you have a watermeter like this, you can measure the water flow with a very simple (1 euro) HALL sensor. 
     

    Please login or register to see this image.

    /monthly_2021_04/3DC4E6DA-9A33-4D36-AA83-505C45E337AE.jpeg.315c7b476549006d1580686d5a58e69d.jpeg" />     B222F936-0FF9-46B0-9C62-092BE02EDDCA.jpeg.a74242e3b943515dc5b9d8dfa5ebd669.jpeg

    Please login or register to see this attachment.

     

    Please login or register to see this link.

     

     

     

     

    Edited by SmartHomeEddy
    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.

    ×
    ×
    • Create New...