Rainmachine Irrigation Controller

I know I’m reviving an old thread, but just in case anybody else stumbles across this topic, I thought it worth mentioning that the Aqara Smart Water Sensor’s mentioned above are supported, you just have to have the Xiaomi Aqara Gateway and then setup the Xiaomi Gateway (Aqara) component.

1 Like

Hi ,

Is the integration broken right now? , I am on 0.70 and I see the error “Unable to find component rainmachine” , when starting the home assistant , I have this entry in the configuration.yaml

rainmachine:
ip_address: <ip_addr>
password:

No, it’s working fine for me (I’m on 0.70.1).

does anyone know if the rainmachine plugin supports multiple devices (2)?

Not currently. However, I have plans to add that support soon.

As far as I can tell, it’s busted on HA 0.81 with firmware 4.0.926 on my Rainmachine. It was working fine on version 0.5x of HA that I was on, but upon updating to 0.81 it says that my config file is incorrect based on the Rainmachine platform. IP and password are correct and working.

Post your RainMachine-specific config so I can help you debug.

Following up with two items:

  1. If you are comfortable using the configuration UI (Configuration >> Integrations), you can add multiple devices today.
  2. If you would like to accomplish the same via configuration.yaml, I just added a PR: https://github.com/home-assistant/home-assistant/pull/18989

thanks … just enabled configuration->integrations (thanks for tip) … i also try the yaml method when released … dan

1 Like

Hi,
is there a way to know the following information regarding the zones:

  • Last watering time and duration
  • Next planed watering time and duration

and maybe also enable/disable the programs.

Thanks

I’ll look into it!

Cool, I cross the fingers :wink:

Unfortunately, the RainMachine API doesn’t give endpoints that show consolidated run durations/times for zones (either in the past or the future), nor does it give an endpoint to enable/disable the programs. Bummer.

I’ll keep an eye out and should the API be updated, I’ll happily add to the HASS integration.

UPDATE 1: Well, I might be incorrect. Too early to tell for sure, but there may be a way to do both. Stand by.

UPDATE 2: Turns out that there’s no such concept as a “next run time” for a zone; those belong to programs. My forthcoming PR will add that as an attribute to each program switch. Unfortunately, there’s no obvious place to get a last run time in a way that makes sense.

UPDATE 3: Confirmed that there’s no great way to get last run time/duration… Can’t believe it, but the RainMachine API is weak there.

UPDATE 4: Confirmed that we can enable/disable programs/zones programmatically!

UPDATE 5: Check out https://github.com/home-assistant/home-assistant/pull/21785 and https://github.com/home-assistant/home-assistant/pull/21786, which add a good chunk of the requested functionality.

I will keep my eyes on the RainMachine API; as soon as additional functionality comes along that makes your other requests possible, I will implement it.

1 Like

Hi bachya,

thanks for your time!

I’m implementing sw since 20 years in ansi c for microcontrollers and various protocols, unfortunately it would take a quite big effort to dig inside of all those things and be familiar… and the problem of our days… we have not so much time :wink: and we have to put priorities…

@bachya Thanks for this component!

I have below errors in my log (from the start I have been using this component). Do you have any idea how to resolve? Just to make sure: Rainmachine is available via web interface and app and component seems to be working fine in Hassio (90.2) beside the errors in log

19-03-28 16:02:27 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/regenmaschine/client.py", line 85, in _request
    ssl=self._ssl) as resp:
  File "/usr/local/lib/python3.7/site-packages/aiohttp/client.py", line 1005, in __aenter__
    self._resp = await self._coro
  File "/usr/local/lib/python3.7/site-packages/aiohttp/client.py", line 497, in _request
    await resp.start(conn)
  File "/usr/local/lib/python3.7/site-packages/aiohttp/client_reqrep.py", line 844, in start
    message, payload = await self._protocol.read()  # type: ignore  # noqa
  File "/usr/local/lib/python3.7/site-packages/aiohttp/streams.py", line 588, in read
    await self._waiter
aiohttp.client_exceptions.ServerDisconnectedError: None

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/rainmachine/__init__.py", line 191, in refresh
    await rainmachine.async_update()
  File "/usr/local/lib/python3.7/site-packages/homeassistant/components/rainmachine/__init__.py", line 307, in async_update
    'current': await self.client.restrictions.current(),
  File "/usr/local/lib/python3.7/site-packages/regenmaschine/restriction.py", line 14, in current
    return await self._request('get', 'restrictions/currently')
  File "/usr/local/lib/python3.7/site-packages/regenmaschine/client.py", line 90, in _request
    'Error requesting data from {0}: {1}'.format(self.host, err))
regenmaschine.errors.RequestError: Error requesting data from 192.168.1.183: None

@Tyfoon Did this start recently?

No, I have been having these errors from when I started using the component. I have to guess here but would think started using it about 5 months ago.

Do they make sense?

Unfortunately, no. I, too, have been using the component for a long time and haven’t see this error. I know you can reach the device over your local network; is it possible there was a momentary blip? How frequently do these occur?

They happen every few hours. I have quite a stable network environment (Unifi with several AC Pro’s incl one few meters from the rainmachine). Also never have errors/issues when reaching web interface.

HI,
I saw that they enabled the flow sensor feature for the Touch version and on the API they added those info answering to {{HOST}}/provision?{{ACCESS_TOKEN}}:
“useFlowSensor”: true
“flowSensorStartIndex”: 22
“flowSensorWateringClicks”: 0
“flowSensorClicksPerCubicMeter”: 53000

It would be very nice to have those info available and even better the calculation in of consumed liters.