homebridge-switchbot icon indicating copy to clipboard operation
homebridge-switchbot copied to clipboard

Feature Request: Switchbot K10+ Pro

Open NorbertM21 opened this issue 1 year ago • 13 comments

Problem

New Device K10+ Pro, so far is not supported:

Solution

device: {"deviceId":"360TY420801009805","deviceName":"Bot","deviceType":"K10+ Pro","enableCloudService":true,"hubDeviceId":""}

Alternatives

No response

Additional context

No response

NorbertM21 avatar Oct 11 '24 16:10 NorbertM21

Should work with v4.0.0

donavanbecker avatar Oct 12 '24 03:10 donavanbecker

Thanks for your quick response, but:

Device: undefined with Device Type: undefined, is currently not supported. Submit Feature Requests Here: https://tinyurl.com/SwitchBotFeatureRequest, device: {"configDeviceName":"SwitchBot","deviceId":"EC:31:4A:32:2D:8A","configDeviceType":"K10+ Pro","connectionType":"OpenAPI","scanDuration":2,"customBLEaddress":"B0:E9:FE:50:8B:B1"}

And - the tinyurl does not work.

NorbertM21 avatar Oct 12 '24 08:10 NorbertM21

Did you set the device in your config?

Also your deviceId has : in it. Take that out of your config.

donavanbecker avatar Oct 12 '24 08:10 donavanbecker

Sorry - i did copy&paste from the App with ":" But changing this, it still doesn't work.

Device: undefined with Device Type: undefined, is currently not supported. Submit Feature Requests Here: https://tinyurl.com/SwitchBotFeatureRequest, device: {"configDeviceName":"SwitchBot","deviceId":"EC314A322D8A","configDeviceType":"K10+ Pro","connectionType":"OpenAPI","scanDuration":2,"enableCloudService":true,"hubDeviceId":""}
{
  “options”: {
    “devices”: [
      {
        “configDeviceName”: “SwitchBot”,
        “deviceId”: “EC314A322D8A”,
        “configDeviceType”: “K10+ Pro”,
        “connectionType”: “OpenAPI”,
        “scanDuration”: 2,
        “enableCloudService”: true,
        “hubDeviceId”: “”
      }
    ],
    “BLE”: false,
    “discoverBLE”: false
  }
}

NorbertM21 avatar Oct 12 '24 10:10 NorbertM21

Can you please remove the device from your config, turn debug mode on under the plugins advanced settings and then post the logs?

donavanbecker avatar Oct 12 '24 12:10 donavanbecker

OK - I could solve the problem with help of the debug-log. The DeviceID is not, as usual, the MAC of the device, it is a constant number. I did not understand this from the readme.

Thanks for your patience.

NorbertM21 avatar Oct 12 '24 13:10 NorbertM21

So it is working now?

donavanbecker avatar Oct 12 '24 13:10 donavanbecker

Yes, but all K10 running with the same DeviceId - good to have only one. 😊

NorbertM21 avatar Oct 12 '24 14:10 NorbertM21

So, one more time. The switch works correct with on/off starting/stopping the robot. But after stopping (off), the button switches back to on, without starting the robot and it allways shows the wrong state.

The folowing debug-code appears every two minutes and sets the state to on:

[13.10.2024, 09:46:22] [SwitchBot] [DEBUG] Got device status: 360TY420801009805 [13.10.2024, 09:46:22] [SwitchBot] [DEBUG] statusCode: 200 [13.10.2024, 09:46:22] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"ChargeDone","onlineStatus":"online","battery":100},"message":"success"}

NorbertM21 avatar Oct 13 '24 08:10 NorbertM21

Can you get me debug logs for Thai.

  • Start at the dock
  • Start Cleaning
  • Return to dock
  • Docked

Then I can potentially get it to set the right status.

donavanbecker avatar Oct 13 '24 10:10 donavanbecker

Stop in Homekit (Robot in dock, off, but switch was on)

[13.10.2024, 15:50:29] [SwitchBot] [DEBUG] Controlled device: 360TY420801009805 with command: dock and parameter: default
[13.10.2024, 15:50:29] [SwitchBot] [DEBUG] statusCode: 200

Start in Homekit (Robot starts cleaning)

[13.10.2024, 15:50:32] [SwitchBot] [DEBUG] Controlled device: 360TY420801009805 with command: start and parameter: default
[13.10.2024, 15:50:32] [SwitchBot] [DEBUG] statusCode: 200

Stop in Homekit (Robot returns to dock)

[13.10.2024, 15:50:44] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[13.10.2024, 15:50:44] [SwitchBot] [DEBUG] statusCode: 200
[13.10.2024, 15:50:44] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"Clearing","onlineStatus":"online","battery":99},"message":"success"}
[13.10.2024, 15:50:47] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[13.10.2024, 15:50:47] [SwitchBot] [DEBUG] statusCode: 200
[13.10.2024, 15:50:47] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"Clearing","onlineStatus":"online","battery":99},"message":"success"}
[13.10.2024, 15:51:06] [SwitchBot] [DEBUG] Controlled device: 360TY420801009805 with command: dock and parameter: default
[13.10.2024, 15:51:06] [SwitchBot] [DEBUG] statusCode: 200

Homekit Switch is on again

[13.10.2024, 15:51:22] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[13.10.2024, 15:51:22] [SwitchBot] [DEBUG] statusCode: 200
[13.10.2024, 15:51:22] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"GotoChargeBase","onlineStatus":"online","battery":99},"message":"success"}

NorbertM21 avatar Oct 13 '24 14:10 NorbertM21

Can you also just getting me all the logs together, there are other logs that the plugin spits out, so I can see how they flow from one to the other?

No need to explain in between because we have the above.

donavanbecker avatar Oct 13 '24 15:10 donavanbecker

That was the complete Log (start/clean/return to dock). But her again:

[14.10.2024, 16:57:52] [SwitchBot] [DEBUG] Controlled device: 360TY420801009805 with command: dock and parameter: default
[14.10.2024, 16:57:52] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:07] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[14.10.2024, 16:58:07] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:07] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"ChargeDone","onlineStatus":"online","battery":100},"message":"success"}
[14.10.2024, 16:58:08] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[14.10.2024, 16:58:08] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:08] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"ChargeDone","onlineStatus":"online","battery":100},"message":"success"}
[14.10.2024, 16:58:10] [SwitchBot] [DEBUG] Controlled device: 360TY420801009805 with command: dock and parameter: default
[14.10.2024, 16:58:10] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:15] [SwitchBot] [DEBUG] Controlled device: 360TY420801009805 with command: start and parameter: default
[14.10.2024, 16:58:15] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:25] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[14.10.2024, 16:58:25] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:25] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"Clearing","onlineStatus":"online","battery":99},"message":"success"}
[14.10.2024, 16:58:30] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[14.10.2024, 16:58:30] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:30] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"Clearing","onlineStatus":"online","battery":99},"message":"success"}
[14.10.2024, 16:58:46] [SwitchBot] [DEBUG] Controlled device: 360TY420801009805 with command: dock and parameter: default
[14.10.2024, 16:58:46] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:58:54] [Shelly Plus] [Heizung KS] Switch Status(0): off
[14.10.2024, 16:59:01] [SwitchBot] [DEBUG] Got device status: 360TY420801009805
[14.10.2024, 16:59:01] [SwitchBot] [DEBUG] statusCode: 200
[14.10.2024, 16:59:01] [SwitchBot] [DEBUG] response: {"statusCode":100,"body":{"deviceId":"360TY420801009805","deviceType":"K10+ Pro","workingStatus":"GotoChargeBase","onlineStatus":"online","battery":99},"message":"success"}

NorbertM21 avatar Oct 14 '24 15:10 NorbertM21