I've made a water flow sensor and use MySensors to send the data to Domoticz.
It is presented with:
present(WATERFLOW_ID, S_WATER, "Water flow");
And sends messages:
MyMessage flowMsg(WATERFLOW_ID, V_FLOW);
MyMessage volumeMsg(WATERFLOW_ID, V_VOLUME);
What I would like is to measure the amount of water when a valve is opened, and then close the valve after a given amount has flown through the sensor.
I added it to Domoticz and it is not working as I hoped. First, it says, in the upper right corner of the sensor, 353880992 Litres?? Where did that number come from? And how do I reset it every time the water valve is opened? I don't want a overall total amount of water, I want the total for this specific open/close session of the valve.
On the Utility page there is also a 0.000m3 meter that seems to show the value for the current open/close session, but it is not shown when used on the dashboard, all I see then is 353880992 Litres. And I would liked to have the value in litres instead of cubic meters and shown on the dashboard.
Is it possible to get what I want? A representation showing the volume in litres for the last open/close session of the valve? It feels like Domoticz is made for some very specific setups/sensors, and maybe not very flexible in it's usage? But I could very well be my lack of knowledge. I hope it is.
Water meter
Moderator: leecollings
-
- Posts: 32
- Joined: Tuesday 14 June 2016 21:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Water meter
Not possible to solve this? Any suggestions on another way to do it?
-
- Posts: 12
- Joined: Thursday 10 April 2014 9:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Contact:
Re: Water meter
I don't if you still need it, but using a lua-script, a virtual meter and a uservariable it should be possible.
When the valve is opened, set the uservariable to the total water amount from the actual Waterflow sensor, and with each update of that sensor, set the value of the virtual meter to the difference in liters between Waterflow sensor and uservariable.
And to finish: If [virtual meter] >= [amount wanted] then [close valve]
When the valve is opened, set the uservariable to the total water amount from the actual Waterflow sensor, and with each update of that sensor, set the value of the virtual meter to the difference in liters between Waterflow sensor and uservariable.
And to finish: If [virtual meter] >= [amount wanted] then [close valve]
-
- Posts: 32
- Joined: Tuesday 14 June 2016 21:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Water meter
I still need it. Haven't found a solution. But all this is very new to me, so I don't really understand what kind of virtual meter to create?Yobby wrote:I don't if you still need it, but using a lua-script, a virtual meter and a uservariable it should be possible.
When the valve is opened, set the uservariable to the total water amount from the actual Waterflow sensor, and with each update of that sensor, set the value of the virtual meter to the difference in liters between Waterflow sensor and uservariable.
And to finish: If [virtual meter] >= [amount wanted] then [close valve]
-
- Posts: 12
- Joined: Thursday 10 April 2014 9:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Contact:
Re: Water meter
raptorjr wrote:I still need it. Haven't found a solution. But all this is very new to me, so I don't really understand what kind of virtual meter to create?
- Setup
- Hardware
- Add Dummy
- Create Virtual Sensors

-
- Posts: 32
- Joined: Tuesday 14 June 2016 21:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Water meter
Thank you for your reply. I could try the rain sensor. Not a problem for me to change the sketch and present the watermeter as a rain sensor. Then I wouldn't have to make a virtual sensor.
But anyway, I know how to make virtual sensors. But this custom sensor you talk about, how can I create it? In another thread I also got the advice to create a custom sensor, but never a explanation how to do that.
This is the only sensor types I have available when creating virtual sensors:

But anyway, I know how to make virtual sensors. But this custom sensor you talk about, how can I create it? In another thread I also got the advice to create a custom sensor, but never a explanation how to do that.
This is the only sensor types I have available when creating virtual sensors:

-
- Posts: 12
- Joined: Thursday 10 April 2014 9:18
- Target OS: Raspberry Pi / ODroid
- Domoticz version: beta
- Contact:
Re: Water meter
As you see above, I'm running the beta, version 3.5641
and I get this:

and I get this:

-
- Posts: 32
- Joined: Tuesday 14 June 2016 21:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Water meter
Thank you. Guess I'll have to test the beta then.
Who is online
Users browsing this forum: No registered users and 1 guest