just released a new update Release v2023.11.0 · jeroenterheerdt/HAsmartirrigation · GitHub. Please install and see if this matches your expectations a bit better. at a minimum the unnecessary conversion to metric that caused the weird duration is gone now.
In V1 about 0.15 bucket would give me about 15 minutes run time. 4 days of no rain = 1 hour run time.
I don’t even know why the bucket is -7 I have max bucket set to 1.5, does it need to be -1.5? I don’t see anything about it in the readme.
Today at 3 AM the irrigation ran and rest the bucket. I set the throughput to 0.25 gal/min a few days ago and that seems to give more reasonable values.
However right now it is already showing -3.4 bucket and 1279 run time! 1279 run time seems a little high but not too far off where it should be, but -3.4 bucket seems excessive if that is measured in inches.
Also I thought update all zones button was to save any changes made
We’re making progress here. You don’t need to save changes they are saved automatically. And the maximum bucket is there to have a ceiling for the bucket, it isn’t a minimum. So of course it doesn’t get applied.
Which version do you have installed? Also, how come your bucket has updated already? It’s supposed to only update once a day. Please reset everything and start over. Stay aware from manual updates and calculates. Everything will most likely do what it needs to do. This is now too confusing
Oh and the bucket is in mm, not in.
Bucket updates at 23:00 which was a few minutes before I posted. If it’s in MM then -3.4 seems fine.
Maybe the other measurements should show a unit? It’s confusing when throughput is gal/minute and the others are in metric but unlabeled.
yeah, that’s fair feedback. I think we documented somewhere that all internal things are metric, but would hurt to make it clearer in the UI.
new version changes this (v2023.11.2). Bucket and max bucket are now in inch or mm depending on your setup and it’s shown in the UI. Explanation is still in metric, but added a lable to that to explain.
Thanks for your patience. I still haven’t updated in fear of breaking things again.
However I notice the bucket is not accurate ether.
It’s rained about 0.56 inch in the past few days, but bucket shows “27.8” which if measured in mm equals 1.09 inch.
so we’re down to about .5 inch of difference. That is “nothing”. Let’s keep in mind that all of this is done based on predictions / aggregated measurements, except the rain rate in your case. Since you’re using a weather station for that you should be ok to assume that is accurate (although many time it is not). Given that you use OWM for the other stuff this .5 inch difference is actually completely normal. I have seen 1-5 inch difference when purely relying on OWM. OWM is just not very accurate, but .5 inch is really really close.
Anybody here who is using this with “Irrigation Unlimited”?
Im trying to make a simple automation that resets individual buckets, but writing YAML automations is still a bit of rocket science to me…i just cant get the logic of some parts.
i have 2 different sequences in Irrigation Unlimited , one for “lawns” and one for “trees” that fire different zones on different days.
i want to reset the individual buckets of the zones that finished.
something like this:
But i have no clue on how IF THEN or the CHOOSE works with templates
trigger:
- platform: event
event_type: irrigation_unlimited_finish
enabled: true
action:
#here is where i have no idea how to implement an IF THEN sequence with the templates:
if {{ trigger.event.data.sequence.name }} = trees
then
- data: {}
service: smart_irrigation.reset_bucket
target:
entity_id: sensor.smart_irrigation_trees
if {{ trigger.event.data.sequence.name }} = lawn
then
- data: {}
service: smart_irrigation.reset_bucket
target:
entity_id: sensor.smart_irrigation_lawn
i hope someone is able to give me some tips!
You may get some inspiration here
It shall be noticed they are several indentation issues in your code. To start with, I would recommend to use Settings/Automations GUI in order to get acquainted with YALM subtleties. A step by step approach is highly recommended.
I’m getting very frustrated with this V2, V1 never gave these issues, and my irrigation has not worked properly in quite a while.
Right now in the past week my sensor shows 0.01 inch of rainfall, but somehow smart irrigation is calculating to have a bucket of 1.8 inch!
Where do these numbers come from?? How can I get this working again like the old version, or even downgrade it?
{
"id": 0,
"name": "Lawn",
"size": 60.0,
"throughput": 0.2,
"state": "automatic",
"bucket": 1.750000056,
"old_bucket": 21.441150604040928,
"delta": 27.284185072466023,
"duration": 0,
"module": 0,
"multiplier": 1.0,
"explanation": "Note: this explanation uses '.' as decimal separator, shows rounded and metric values. Module returned Evapotranspiration deficiency of 27.3. Bucket was 21.4.<br/>maximum bucket size is 44.4.New bucket value is [old_bucket]+[delta]=21.4+27.3=44.4.<br/>Since bucket >= 0, no irrigation is necessary and duration is set to 0",
"mapping": 0,
"lead_time": 30.0,
"maximum_duration": 4140.0,
"maximum_bucket": 1.75,
"last_calculated": "2023-12-12T23:55:00.469251"
},
If there is 0 rain why does bucket increase? Here is the full debug, someone please help me fix this.
Here is the full debug, someone please tell me how to fix this
{
“home_assistant”: {
“installation_type”: “Home Assistant OS”,
“version”: “2023.11.3”,
“dev”: false,
“hassio”: true,
“virtualenv”: false,
“python_version”: “3.11.6”,
“docker”: true,
“arch”: “x86_64”,
“timezone”: “America/New_York”,
“os_name”: “Linux”,
“os_version”: “6.1.63-haos”,
“supervisor”: “2023.11.6”,
“host_os”: “Home Assistant OS 11.2”,
“docker_version”: “24.0.7”,
“chassis”: “vm”,
“run_as_root”: true
},
“custom_components”: {
“smart_irrigation”: {
“version”: “v2023.12.0”,
“requirements”:
},
“irrigation_unlimited”: {
“version”: “2023.11.0”,
“requirements”: [
“crontab”
]
},
“alexa_media”: {
“version”: “4.8.0”,
“requirements”: [
“alexapy==1.27.10”,
“packaging>=20.3”,
“wrapt>=1.14.0”
]
},
“winix”: {
“version”: “1.1.5”,
“requirements”: [
“winix==0.2.1”
]
},
“adaptive_lighting”: {
“version”: “1.20.0”,
“requirements”: [
“ulid-transform”
]
},
“hacs”: {
“version”: “1.33.0”,
“requirements”: [
“aiogithubapi>=22.10.1”
]
},
“smartthinq_sensors”: {
“version”: “0.35.5”,
“requirements”: [
“pycountry>=20.7.3”,
“xmltodict>=0.12.0”,
“charset_normalizer>=2.0.0”
]
}
},
“integration_manifest”: {
“domain”: “smart_irrigation”,
“name”: “Smart Irrigation”,
“codeowners”: [
“@jeroenterheerdt”
],
“config_flow”: true,
“dependencies”: [
“http”,
“panel_custom”
],
“documentation”: “GitHub - jeroenterheerdt/HAsmartirrigation: Smart Irrigation custom component for Home Assistant”,
“iot_class”: “local_push”,
“issue_tracker”: “Issues · jeroenterheerdt/HAsmartirrigation · GitHub”,
“requirements”: ,
“version”: “v2023.12.0”,
“is_built_in”: false
},
“data”: {
“config”: {
“entry_id”: “284ca9d34a73073f30647797d91b4b61”,
“version”: 1,
“domain”: “smart_irrigation”,
“title”: “Smart Irrigation”,
“data”: {
“owm_api_key”: “XXXXXXXX”,
“owm_api_version”: “2.5”,
“use_owm”: true,
“name”: “Smart Irrigation”
},
“options”: {
“owm_api_key”: “XXXXXXXXXXX”,
“owm_api_version”: “3.0”,
“use_owm”: true
},
“pref_disable_new_entities”: false,
“pref_disable_polling”: false,
“source”: “user”,
“unique_id”: “Smart Irrigation”,
“disabled_by”: null
},
“storage”: {
“config”: {
“calctime”: “23:55”,
“units”: “imperial”,
“use_owm”: true,
“autocalcenabled”: true,
“autoupdateenabled”: true,
“autoupdateschedule”: “hours”,
“autoupdatedelay”: “0”,
“autoupdateinterval”: “2”,
“autoclearenabled”: true,
“cleardatatime”: “23:59”,
“starteventfiredtoday”: false
},
“zones”: [
{
“id”: 0,
“name”: “Lawn”,
“size”: 60.0,
“throughput”: 0.2,
“state”: “automatic”,
“bucket”: 1.750000056,
“old_bucket”: 21.441150604040928,
“delta”: 27.284185072466023,
“duration”: 0,
“module”: 0,
“multiplier”: 1.0,
“explanation”: “Note: this explanation uses ‘.’ as decimal separator, shows rounded and metric values. Module returned Evapotranspiration deficiency of 27.3. Bucket was 21.4.
maximum bucket size is 44.4.New bucket value is [old_bucket]+[delta]=21.4+27.3=44.4.
Since bucket >= 0, no irrigation is necessary and duration is set to 0”,
“mapping”: 0,
“lead_time”: 30.0,
“maximum_duration”: 4140.0,
“maximum_bucket”: 1.75,
“last_calculated”: “2023-12-12T23:55:00.469251”
},
{
“id”: 1,
“name”: “Landscape”,
“size”: 40.0,
“throughput”: 0.2,
“state”: “automatic”,
“bucket”: 1.8000000576,
“old_bucket”: 21.441150604040928,
“delta”: 27.284185072466023,
“duration”: 0,
“module”: 0,
“multiplier”: 1.0,
“explanation”: “Note: this explanation uses ‘.’ as decimal separator, shows rounded and metric values. Module returned Evapotranspiration deficiency of 27.3. Bucket was 21.4.
maximum bucket size is 45.7.New bucket value is [old_bucket]+[delta]=21.4+27.3=45.7.
Since bucket >= 0, no irrigation is necessary and duration is set to 0”,
“mapping”: 0,
“lead_time”: 30.0,
“maximum_duration”: 1900.0,
“maximum_bucket”: 1.8,
“last_calculated”: “2023-12-12T23:55:00.764410”
}
],
“modules”: [
{
“id”: 0,
“name”: “PyETO”,
“description”: “Calculate duration based on the FAO56 calculation from the PyETO library.”,
“config”: {
“coastal”: true,
“forecast_days”: “4”
},
“schema”: [
{
“type”: “boolean”,
“name”: “coastal”,
“optional”: true,
“default”: false
},
{
“type”: “select”,
“options”: [
[
“1”,
“EstimateFromTemp”
],
[
“2”,
“EstimateFromSunHours”
],
[
“3”,
“DontEstimate”
]
],
“name”: “solrad_behavior”,
“required”: true,
“default”: “1”
},
{
“type”: “integer”,
“name”: “forecast_days”,
“required”: true,
“default”: 0
}
]
},
{
“id”: 1,
“name”: “Static”,
“description”: “‘Dummy’ module with a static configurable delta.”,
“config”: null,
“schema”: [
{
“type”: “float”,
“name”: “delta”,
“required”: true,
“default”: 0
}
]
},
{
“id”: 3,
“name”: “Passthrough”,
“description”: “Passthrough module that returns the value of an Evapotranspiration sensor as delta.”,
“config”: {},
“schema”:
}
],
“mappings”: [
{
“id”: 0,
“name”: “Default sensor group”,
“mappings”: {
“Dewpoint”: {
“source”: “owm”,
“sensorentity”: “”,
“unit”: “”
},
“Evapotranspiration”: {
“source”: “none”,
“sensorentity”: “”,
“unit”: “”,
“static_value”: “0.156”
},
“Humidity”: {
“source”: “owm”,
“sensorentity”: “”,
“unit”: “”
},
“Precipitation”: {
“source”: “sensor”,
“sensorentity”: “sensor.gw1100b_v2_1_8_daily_rain_rate”,
“unit”: “”
},
“Pressure”: {
“source”: “owm”,
“sensorentity”: “”,
“unit”: “”
},
“Solar Radiation”: {
“source”: “none”,
“sensorentity”: “”,
“unit”: “”
},
“Temperature”: {
“source”: “owm”,
“sensorentity”: “”,
“unit”: “”
},
“Windspeed”: {
“source”: “owm”,
“sensorentity”: “”,
“unit”: “”
}
},
“data”: ,
“data_last_updated”: null
}
]
}
}
}
@ahj391 you can always downgrade using HACS to V1 if you wanted. However, that should not be necessary. I notice a couple of things:
- you have a 4 day forecast. This means even if it hasn’t rained today it will take into account forecast for the next four days.
- you have coastal set to True. Are you in a coastal area?
- you have a static ET value set up, but also sensors set up. What did you want to achieve?
4 day forecast… not sure I don’t see that option. I am set to use the local rain sensor.
Coastal I think is true but I am not certain. I used it in V1
Static ET we have discussed this already. It is disabled. Not sure why it shows in the debug.
Why is it making this massive bucket if there is no rain?
I rains 0.1 inch today. I click reset bucket & calculate and the bucket is already 0.3 inch!
I set forecast to 0, reset bucket & calculate and bucket is 0.0. I have no clue what is going on here.
I don’t understand how it can pull predicted rain from the forecast and add it to the bucket. Then it rains and it’s added to my sensor. So wouldn’t it get counted twice?
predicted rain is used only at calculation time, so it’s not for today, it’s for tomorrow, the day after or whatever. We take the average of what weather data you collected for today and whatever the forecast is. so that doesn’t count it twice.
if you reset bucket your bucket should return to 0. Makes sense.
If you calculate but don’t have any weather data collected, nothing happens, because there is no weather data. We don’t calculate an average of [no weather data for today] + X forecast days. So that behavior is as designed.
Also what I noticed in the debug is that you ET value is huge. 27.3 is very high. I will need to do some more digging to understand where that came from.
Can you please: schedule weather data collection for every hour or so and let it turn for 24 hours. Please don’t calculate in that period and make sure your weather data pruning is off. Send that debug file to me. It should contain weather data
(your current debug file contains none, see the last part of the debug file). With that I should be able to step through the logic to see if I can explain the high ET value which in turn is driving the high bucket.
Logger: homeassistant.config_entries
Source: config_entries.py:406
First occurred: 10:39:35 (1 occurrences)
Last logged: 10:39:35
Error setting up entry Smart Irrigation for smart_irrigation
Traceback (most recent call last):
File “/usr/src/homeassistant/homeassistant/config_entries.py”, line 406, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/config/custom_components/smart_irrigation/init.py”, line 64, in async_setup_entry
store = await async_get_registry(hass)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/config/custom_components/smart_irrigation/store.py”, line 561, in async_get_registry
return cast(SmartIrrigationStorage, await task)
^^^^^^^^^^
File “/config/custom_components/smart_irrigation/store.py”, line 556, in _load_reg
await registry.async_load()
File “/config/custom_components/smart_irrigation/store.py”, line 228, in async_load
inst = m(self.hass, modconfig)
^^^^^^^^^^^^^^^^^^^^^^^
File “/config/custom_components/smart_irrigation/calcmodules/static/init.py”, line 21, in init
super().init(name=“Static”, description=localize(“calcmodules.static.description”,hass.config.language)+“.”, config=config, schema=SCHEMA)
File “/config/custom_components/smart_irrigation/calcmodules/calcmodule.py”, line 26, in init
raise e
File “/config/custom_components/smart_irrigation/calcmodules/calcmodule.py”, line 24, in init
self._schema(config)
File “/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py”, line 272, in call
return self._compiled(, data)
^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py”, line 595, in validate_dict
return base_validate(path, iteritems(data), out)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/usr/local/lib/python3.11/site-packages/voluptuous/schema_builder.py”, line 433, in validate_mapping
raise er.MultipleInvalid(errors)
voluptuous.error.MultipleInvalid: expected float for dictionary value @ data[‘delta’]