Did the right thing, deleted the device and re-added.
It's now counting correct. Thanks for the help.
1 thing to keep in mind for any future users, the device keeps the measured values, so when you re-add it you should subtract the measured values from the current meter standings when setting the offset.
Add HomeWizard WiFi watermeter in Domoticz
Moderators: leecollings, remb0
Re: Add HomeWizard WiFi watermeter in Domoticz
Great how-to, thanks for this!Broomer23 wrote: ↑Friday 07 October 2022 17:39 Not sure this is the right place but I want to share my successfull addition of HomeWizard Watermeter in Domoticz.
First start by looking up the IP address the Watermeter is using.
Then add hardware type HTTP/HTTPS poller in domoticz using the url with IP address including the API:
http://your-ip/api/v1/data
The name for the hardware can be WaterMeter, but is arbitrary
Be sure to select GET as Methode
Use water.lua as command.
Now create two virtual sensors
Water - WaterFlow
WaterTotaal - Custom - axis label: m3
Note the IDX value of both virtual sensors
water.lua
Next you must create the script called water.lua (name is arbitrary, but use the same name everywhere)
Connect to your domoticz via Putty and and go to the directory where domoticz is installed.
Go to the subfolder .../domoticz/scripts/lua_parsers
create the file water.lua with sudo privileges.
Insert the following:
Save the file, goto Domoticz and watch until values appear in the sensors.Code: Select all
[b]-- Read API values s = request['content']; -- -- Watermeter -- local idWater = [i]use the idx for the water sensor[/i] local a = domoticz_applyJsonPath(s,'.active_liter_lpm') domoticz_updateDevice(idWater,'',a*1000) local idWaterTotaal = [i]use the idx for the WaterTotaal sensor[/i] local b = domoticz_applyJsonPath(s,'.total_liter_m3') domoticz_updateDevice(idWaterTotaal,'',b*1000)[/b]
Success!
What should the renewal interval be for the HTTP poller? I've set mine to 4 seconds now, as it is required to fill it in.
I've also added wifi strength & ssid:
Code: Select all
-- Read API values
s = request['content'];
--
-- Watermeter
--
local idWaterStroom = -- use the idx for the WaterStroom sensor
local a = domoticz_applyJsonPath(s,'.active_liter_lpm')
domoticz_updateDevice(idWaterStroom,'',a)
--domoticz_updateDevice(idWaterStroom,'',a*1000)
local idWaterTotaal = -- use the idx for the WaterTotaal sensor
local b = domoticz_applyJsonPath(s,'.total_liter_m3')
domoticz_updateDevice(idWaterTotaal,'',b*1000)
local idWifiSSID = -- use the idx for the Wifi SSID
local c = domoticz_applyJsonPath(s,'.wifi_ssid')
domoticz_updateDevice(idWifiSSID,'',c)
local idWifiStrength = -- use the idx for the Wifi Strength
local d = domoticz_applyJsonPath(s,'.wifi_strength')
domoticz_updateDevice(idWifiStrength,'',d)
idWaterTotaal = Counter / type Water
wifi_ssid = Text
idWifiStrength = Percentage
Domoticz 2024.7 on Ubuntu 22.04 LTS VM on ESXi 7
SolarEdge Web API, P1 meter, RFXCOM433E, OpenZWave via ZMEEUZB1, MQTT AD Client Gateway ZWave-JS-UI, Philips Hue bridge, Kodi Media server, Panasonic TV, OWM, BuienRadar and HTTP/HTTPS poller Watermeter
SolarEdge Web API, P1 meter, RFXCOM433E, OpenZWave via ZMEEUZB1, MQTT AD Client Gateway ZWave-JS-UI, Philips Hue bridge, Kodi Media server, Panasonic TV, OWM, BuienRadar and HTTP/HTTPS poller Watermeter
- mvveelen
- Posts: 678
- Joined: Friday 31 October 2014 10:22
- Target OS: NAS (Synology & others)
- Domoticz version: Beta
- Location: Hoorn, The Netherlands
- Contact:
Re: Add HomeWizard WiFi watermeter in Domoticz
I'm using this plugin after my watermeter was swapped for a new one from Homewizard, but when I use water, I don't see the current water usage doing anything. Am I forgetting something?Eraser wrote: ↑Saturday 03 June 2023 15:15 I have written a Python plugin for the watermeter. Check the HomeWizard Wi-Fi Watermeter on Github.
RPi3b+/RFXCOM rfxtrx433E/Shelly/Xiaomi Gateway/Philips HUE Lights/Atag Zone One/2 SunnyBoy inverters/AirconWithMe/P1 smartmeter/Domoticz latest Beta
Re: Add HomeWizard WiFi watermeter in Domoticz
Did you enable the local API on the device in the 'Energy' app?
And is it showing usage in that app?
Also, is it battery powered? It will only report once every 4 Hours on battery
And is it showing usage in that app?
Also, is it battery powered? It will only report once every 4 Hours on battery
- mvveelen
- Posts: 678
- Joined: Friday 31 October 2014 10:22
- Target OS: NAS (Synology & others)
- Domoticz version: Beta
- Location: Hoorn, The Netherlands
- Contact:
Re: Add HomeWizard WiFi watermeter in Domoticz
Yes, the API is enabled and it’s adapter-powered.
Now you mention it: in the Homewizard app I also don’t see the flow-speed, only what is used per day, week, month, etc.
Now you mention it: in the Homewizard app I also don’t see the flow-speed, only what is used per day, week, month, etc.
RPi3b+/RFXCOM rfxtrx433E/Shelly/Xiaomi Gateway/Philips HUE Lights/Atag Zone One/2 SunnyBoy inverters/AirconWithMe/P1 smartmeter/Domoticz latest Beta
- mvveelen
- Posts: 678
- Joined: Friday 31 October 2014 10:22
- Target OS: NAS (Synology & others)
- Domoticz version: Beta
- Location: Hoorn, The Netherlands
- Contact:
Re: Add HomeWizard WiFi watermeter in Domoticz
Found it:
Callibrating went well when installing a few weeks ago, but a new callibration today didn’t work. Checked the mount of the sensor and it was shifted a bit. Corrected and is now working…..
Callibrating went well when installing a few weeks ago, but a new callibration today didn’t work. Checked the mount of the sensor and it was shifted a bit. Corrected and is now working…..
RPi3b+/RFXCOM rfxtrx433E/Shelly/Xiaomi Gateway/Philips HUE Lights/Atag Zone One/2 SunnyBoy inverters/AirconWithMe/P1 smartmeter/Domoticz latest Beta
Re: Add HomeWizard WiFi watermeter in Domoticz
I have a question, before I always used a P1 to PI USB cabel.
I tested if I can run HomeWizzard in my domoticz setup. (in test setup).
My question, can I hold the old values/statistics that I record with the USB-cabel in domoticz and now get the values from HomeWizzard and disconnect the USB, but go on with the stats.
Or do I have to start over with new statistics?
note: Im a noob with domoticz
I tested if I can run HomeWizzard in my domoticz setup. (in test setup).
My question, can I hold the old values/statistics that I record with the USB-cabel in domoticz and now get the values from HomeWizzard and disconnect the USB, but go on with the stats.
Or do I have to start over with new statistics?
note: Im a noob with domoticz
Who is online
Users browsing this forum: No registered users and 1 guest