koryhutchison / homebridge-opensprinkler-api

Homebridge plugin to control OpenSprinkler with Homekit
Apache License 2.0
8 stars 0 forks source link

OpenSprinkler-Status in HomeKit doesn't update #15

Closed Stefan-83 closed 2 years ago

Stefan-83 commented 2 years ago

Describe The Bug: When starting irrigation manual or scheduled by OpenSprinkler-Interface the status doesn't update in HomeKit. It still shows "scheduled" and is "turned off"

To Reproduce: Start irrigation in OpenSprinkler-Interface

Expected behavior: Status in Homekit of OpenSprinkler should be running

Logs: No Logfile-Activity, when starting irrigation.


**Plugin Config:**

```json
        {
            "password": {
                "md5": "REMOVED"
            },
            "valves": [
                {
                    "name": "WasserHaus",
                    "defaultDuration": 60
                },
                {
                    "name": "WasserGrundstück",
                    "defaultDuration": 60
                },
                {
                    "name": "WasserB",
                    "defaultDuration": 60
                }
            ],
            "host": "192.168.178.98",
            "pollInterval": 15,
            "platform": "HomebridgeOpenSprinklerApi"

Environment:

koryhutchison commented 2 years ago

Hm....I'm using v2.0.1 and my system ran the sprinklers yesterday with it's schedule as well as me manually triggering via OpenSprinkler and both times the status showed up in HomeKit. Your poll interval is 15 seconds, so depending on when the poll last triggered, it can take up to 15 seconds for the status to update in HomeKit. If you want it to update faster, you can decrease your poll interval. Also, are you using the Apple Home app? Or a different HomeKit app?

Stefan-83 commented 2 years ago

Hm, the connection between HomeKit and my OpenSprinkler doesn't seem to work anymore:

When I try to start an irrigation with HomeApp or Controller-App, nothing happens. It shows (for a short time): "Warten" (German: waiting) in both apps, then the switch goes off again :-(

image image

And noting happens in the logfile...

koryhutchison commented 2 years ago

Now that's some odd behavior. How long have you been using this plugin? Did you use any versions before v2.0.1? Because v2.0.1 brought a change where it would create a second sprinkler system and you need to remove the old one from the cache. Check to see if you have a second sprinkler system showing up in the room that your homebridge bridge is in. That's really my only explanation here. My guess is the one you're trying to use is no longer connected to the plugin.

You can remove the plugin from the Homebridge cache by navigating to homebridge settings. And don't be scared, removing an accessory from my plugin from the cache will have no ill effects. When Homebridge restarts, it will either find the one from the cache, or just create a new one.

But if my assumption isn't correct, you can try and start homebridge in debug mode and you'll get more logs from the plugin. But you'll also probably get logs from the other plugins too. But yeah let me know how things go and if you still aren't seeing anything I can make a beta release with some more detailed logs that you can use to debug your system.

Stefan-83 commented 2 years ago

yes, i'm using this plugin for years :-)

and yes: it was a caching issue. After I refreshed it, it works again like a charm. Thanks!

koryhutchison commented 2 years ago

That's great to hear that you've been using the plugin for a while! Glad we solved the problem!

Stefan-83 commented 2 years ago

I really enjoy this plugin. Thanks for your great work 👍