stvmallen / homebridge-roomba-stv

Homebrige plugin for Roomba 9xx
MIT License
38 stars 15 forks source link

Redundant requests for Roomba status #68

Open crowston opened 3 years ago

crowston commented 3 years ago

Expected Behavior

Homekit sends separate requests for four characteristics of the Roomba: running status, battery status, battery level and charging status. I would expect the plugin to retrieve the Roomba status once and use the data to answer all four queries.

Current Behavior

The plugin requests data from the Roomba four times.

Steps to Reproduce (for bugs)

Open the Home app and wait for the data to refresh.

Versions

Configuration

        {
            "name": "Roomba",
            "model": "890",
            "blid": "xxxx",
            "robotpwd": "xxxx,
            "ipaddress": "172.x.x.x",
            "autoRefreshEnabled": false,
            "accessory": "Roomba"
        }

Homebridge Log / Command Output

[8/24/2020, 9:12:51 AM] [Roomba] Running status requested
[8/24/2020, 9:12:51 AM] [Roomba] Battery status requested
[8/24/2020, 9:12:53 AM] [Roomba] Connected to Roomba
[8/24/2020, 9:12:53 AM] [Roomba] Roomba[{"running":0,"charging":1,"batteryLevel":100,"batteryStatus":0,"binFull":true}]
[8/24/2020, 9:12:56 AM] [Roomba] Connected to Roomba
[8/24/2020, 9:12:56 AM] [Roomba] Roomba[{"running":0,"charging":1,"batteryLevel":100,"batteryStatus":0,"binFull":true}]
[8/24/2020, 9:12:58 AM] [Roomba] Battery level requested
[8/24/2020, 9:12:58 AM] [Roomba] Charging status requested
[8/24/2020, 9:12:59 AM] [Roomba] Connected to Roomba
[8/24/2020, 9:13:00 AM] [Roomba] Roomba[{"running":0,"charging":1,"batteryLevel":100,"batteryStatus":0,"binFull":true}]
[8/24/2020, 9:13:02 AM] [Roomba] Connected to Roomba
[8/24/2020, 9:13:03 AM] [Roomba] Roomba[{"running":0,"charging":1,"batteryLevel":100,"batteryStatus":0,"binFull":true}]