homebridge-plugins / homebridge-govee

Homebridge plugin to integrate Govee devices into HomeKit.
MIT License
481 stars 49 forks source link

Error: Request failed with status code 400 and un-able to add to HomeKit #12

Closed Mike92115 closed 3 years ago

Mike92115 commented 3 years ago

What issue do you have? Please be as thorough and explicit as possible.

I emailed support and received my API key within a few minutes, I then installed the plugin for my H6160 and configured using the HomeBridge UI. My config at that point is what is below "name": "Govee", "apiKey": "**", "debug": false, "debugReqRes": false, "refreshTime": 15, "platform": "Govee"

I then tried to add to Homekit which failed as the light was not found, so I looked at the logs and saw a 400 error, While Homebridge is getting the 400 error, I am able to turn the light off/on in Homebridge but I am not able to add the light to HomeKit.

[Govee] [Bathroom Under Sinks] could not be updated and its status will be reverted soon. Error: Request failed with status code 400. (logs are at the end as requested)

so I removed the lines that were not in the example and set my config to the following with debug on and debugReqRes off (I will add the logs at the bottom with debugReqRes on where you requested): "name": "Govee", "apiKey": "**", "debug": true, "platform": "Govee"

The log messages are below, it is failing with the same error.

[10/29/2020, 10:00:14 AM] Homebridge v1.2.3 is running on port 51810. [10/29/2020, 10:00:14 AM] [LED Strip] DEVICE COLOR - (H,S,V): 112,100,100 (R,G,B): [ 33, 255, 0 ] [10/29/2020, 10:00:15 AM] [Govee] [1] devices loaded from your Govee account. [10/29/2020, 10:00:15 AM] [Govee] Govee setup complete. Don't forget to ⭐️ this plugin on GitHub if you're finding it useful!

[10/29/2020, 10:02:30 AM] [Govee] [Bathroom Under Sinks] has been turned [on].

[10/29/2020, 10:02:31 AM] [Govee] [Bathroom Under Sinks] could not be updated and its status will be reverted soon. Error: Request failed with status code 400.

...

Details of your setup. Do you use Homebridge or HOOBS? I use Homebridge running in Docker on my Synolgy NAS ...

Which version of Homebridge/HOOBS do you have? 1.2.3

I pasted at the bottom an image of my Homebridge home page so you can see all of the versions I am running for the software ...

Which version of this plugin (homebridge-govee) do you have? 2.0.6 ...

Please paste any relevant logs below. It helps if you can turn debug and debugReqRes in the package settings for more thorough logging.

If you are posting an error then it is helpful for me to also see the previous few lines as this can show the cause of the error.

This is before I tried to turn the light on/off in Homebridge [10/29/2020, 10:15:38 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:15:38 AM] [Govee] [1] devices loaded from your Govee account. [10/29/2020, 10:15:38 AM] [Govee] Govee setup complete. Don't forget to ⭐️ this plugin on GitHub if you're finding it useful! [10/29/2020, 10:15:38 AM] [Govee] Note: 'Request & Response Logging' is not advised for long-term use. [10/29/2020, 10:15:39 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:15:39 AM] Receiver 764A is running on port 59919. [10/29/2020, 10:15:39 AM] Please add [Receiver 764A] manually in Home app. Setup Code: 031-45-154 [10/29/2020, 10:15:47 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:15:47 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:15:48 AM] [Garage Door] State of Garage Door is: CLOSED [10/29/2020, 10:15:50 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:15:50 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:15:53 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:15:53 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:08 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:09 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:24 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:24 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:37 AM] [ADT Pulse] Security Panel (system-1) changed from "disarmed / all quiet" to "disarmed / motion". [10/29/2020, 10:16:38 AM] [ADT Pulse] Office Motion Detector (sensor-26) changed from "no motion" to "motion". [10/29/2020, 10:16:39 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:39 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:54 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:16:55 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 }

Below is the rest of the log (all that was shown that I could copy)

[10/29/2020, 10:17:10 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:17:25 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:17:25 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:17:40 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:17:41 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:17:41 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:17:41 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:17:42 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:17:42 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:17:45 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:17:45 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:17:46 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:17:46 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:17:49 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:17:49 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:17:55 AM] [Govee] [updateDevice()] HTTP Request. This message is yellow for clarity: { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "cmd": { "name": "turn", "value": "off" } } [10/29/2020, 10:17:55 AM] [Govee] [updateDevice()] HTTP Response: { "code": 200, "message": "Success", "data": {} } [10/29/2020, 10:17:55 AM] [Govee] [Bathroom Under Sinks] has been turned [off]. [10/29/2020, 10:17:56 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:17:57 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:17:57 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:17:57 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:18:12 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:18:12 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:18:19 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:18:20 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:18:22 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:18:23 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:18:23 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:18:27 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:18:27 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:18:42 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:18:42 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:18:56 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:18:57 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:18:58 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:18:58 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:00 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:19:01 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:19:08 AM] [ADT Pulse] Security Panel (system-1) changed from "disarmed / motion" to "disarmed / all quiet". [10/29/2020, 10:19:08 AM] [ADT Pulse] Office Motion Detector (sensor-26) changed from "motion" to "no motion". [10/29/2020, 10:19:13 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:13 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:20 AM] [Govee] [updateDevice()] HTTP Request. This message is yellow for clarity: { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "cmd": { "name": "turn", "value": "on" } } [10/29/2020, 10:19:20 AM] [Govee] [updateDevice()] HTTP Response: { "code": 200, "message": "Success", "data": {} } [10/29/2020, 10:19:20 AM] [Govee] [Bathroom Under Sinks] has been turned [on]. [10/29/2020, 10:19:20 AM] [Govee] [updateDevice()] HTTP Request. This message is yellow for clarity: { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "cmd": { "name": "brightness", "value": 254 } } [10/29/2020, 10:19:20 AM] [Govee] [Bathroom Under Sinks] could not be updated and its status will be reverted soon. Error: Request failed with status code 400. [10/29/2020, 10:19:22 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:19:22 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:19:22 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:19:22 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:19:28 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:28 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:38 AM] [ADT Pulse] Security Panel (system-1) changed from "disarmed / all quiet" to "disarmed / motion". [10/29/2020, 10:19:38 AM] [ADT Pulse] Office Motion Detector (sensor-26) changed from "no motion" to "motion". [10/29/2020, 10:19:43 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:44 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:59 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:19:59 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:20:14 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:20:14 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:20:29 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:20:30 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:20:45 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:20:45 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:20:45 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:20:46 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:20:49 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:20:49 AM] [Govee] [updateDevice()] HTTP Request. This message is yellow for clarity: { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "cmd": { "name": "turn", "value": "off" } } [10/29/2020, 10:20:49 AM] [Govee] [updateDevice()] HTTP Request. This message is yellow for clarity: { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "cmd": { "name": "turn", "value": "on" } } [10/29/2020, 10:20:49 AM] [Govee] [updateDevice()] HTTP Response: { "code": 200, "message": "Success", "data": {} } [10/29/2020, 10:20:49 AM] [Govee] [Bathroom Under Sinks] has been turned [off]. [10/29/2020, 10:20:49 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:20:49 AM] [Govee] [updateDevice()] HTTP Response: { "code": 200, "message": "Success", "data": {} } [10/29/2020, 10:20:49 AM] [Govee] [Bathroom Under Sinks] has been turned [on]. [10/29/2020, 10:20:49 AM] [Govee] [updateDevice()] HTTP Request. This message is yellow for clarity: { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "cmd": { "name": "brightness", "value": 254 } } [10/29/2020, 10:20:50 AM] [Govee] [updateDevice()] HTTP Request. This message is yellow for clarity: { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "cmd": { "name": "turn", "value": "off" } } [10/29/2020, 10:20:50 AM] [Govee] [Bathroom Under Sinks] could not be updated and its status will be reverted soon. Error: Request failed with status code 400. [10/29/2020, 10:20:50 AM] [Govee] [updateDevice()] HTTP Response: { "code": 200, "message": "Success", "data": {} } [10/29/2020, 10:20:50 AM] [Govee] [Bathroom Under Sinks] has been turned [off]. [10/29/2020, 10:20:51 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:20:51 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:20:52 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:20:52 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:20:52 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:20:52 AM] [Receiver] Current input: ATT (HDMI1) [10/29/2020, 10:20:52 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:20:52 AM] [FamilyNAS] current power state is: true [10/29/2020, 10:21:00 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:21:01 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:21:16 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:21:16 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:21:31 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:21:31 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:21:46 AM] [Govee] [getDevices()] HTTP Response: { "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:21:47 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "off" }, { "brightness": 1 }, { "color": { "r": 0, "b": 255, "g": 0 } } ] }, "message": "Success", "code": 200 }

...

image
bwp91 commented 3 years ago

I’ve immediately updated your comment, removing your api key. will look into this in a little while!

Mike92115 commented 3 years ago

Thank you

bwp91 commented 3 years ago

Thanks for the detailed issue, it really helps to already have this info!

I wonder if you could do me a favour:

thanks!

Mike92115 commented 3 years ago

Interesting, I set the brightness to 100% as requested in the Govee app as requested and in HomeBridge the brightness is 39%. If you would like screen prints so that let me know, and I added the last few "lines" of the log below in case you need those.

Thank you, Mike

{ "data": { "devices": [ { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "deviceName": "Bathroom Under Sinks", "controllable": true, "retrievable": true, "supportCmds": [ "turn", "brightness", "color", "colorTem" ] } ] }, "message": "Success", "code": 200 } [10/29/2020, 10:42:28 AM] [Govee] [getDevice()] HTTP Response: { "data": { "device": "7E:59:A4:C1:38:D7:F0:3B", "model": "H6160", "properties": [ { "online": true }, { "powerState": "on" }, { "brightness": 100 }, { "color": { "r": 165, "b": 165, "g": 165 } } ] }, "message": "Success", "code": 200 }

bwp91 commented 3 years ago

There are some govee models that I need to make a little fix for. You should find it works fine right now if you never set the brightness above 39% 🤣 I’ll get an update out within the next few minutes and it should be working well!

Mike92115 commented 3 years ago

I don't set this light above about 10% normally as it's the night light in the bathroom so I am not woken up more than needed to see at night :) So that should be fine, the 2nd problem is that I am not able to add the light to homekit as it does not show up when I Add Accessory.

Thank you, Mike

bwp91 commented 3 years ago

Please try v2.0.7 for the brightness fix.

But I am also confused by your second issue. If the device is in Homebridge then it should appear in HomeKit already.

Have you added Homebridge to your HomeKit?

Mike92115 commented 3 years ago

I updated the plugin and the brightness issue has been resolved. Thank you on.

On the adding issue, I was confused normally I have to see and select the device to add it. The device did not show when I went to add it to Homekit.

BUT

I then went to the default room to make sure and it was already there without me having to add it YAY - We can call that a feature :-)

Thank you again for all of your help, Mike

bwp91 commented 3 years ago

Ah glad it’s sorted! Any accessory that you add to Homebridge will appear automatically in your Home app, without having to “add” anything further 🙂