AMoo-Miki / homebridge-tuya-lan

Homebridge plugin for IoT devices that use Tuya Smart's platform
MIT License
196 stars 50 forks source link

TUYA HOMEBRIDGE #241

Open Alexchev81 opened 3 years ago

Alexchev81 commented 3 years ago

I try to put my Tuya devices in Homekit but it does not work , someone could help me ?

messages error :

[TuyaDiscovery] Discovery started on port 6666. [TuyaDiscovery] Discovery started on port 6667. Starting to advertise 'Homebridge 2848 B2E7' using bonjour-hap backend! [5/6/2021, 5:17:57 PM] Homebridge v1.3.4 (Homebridge 2848) is running on port 51032. [5/6/2021, 5:17:58 PM] [TuyaLan] Discovered lumière salle à manger (bfb8004980a73000d7i8pc) identified as TWLight (3.3) [TuyaAccessory] Changing ping gap for lumière salle à manger to 9s [5/6/2021, 5:17:58 PM] [TuyaLan] Discovered lumière ma chérie (bf12cbe5962ba879a8itap) identified as TWLight (3.3) [TuyaAccessory] Changing ping gap for lumière ma chérie to 9s [5/6/2021, 5:17:58 PM] [Google Smart Home] Connected (1) - wss://homebridge-gsh.iot.oz.nu [5/6/2021, 5:17:58 PM] [TuyaLan] Connected to lumière ma chérie [TuyaAccessory] Sending first query to lumière ma chérie (3.3) [5/6/2021, 5:17:58 PM] [TuyaLan] Connected to lumière salle à manger [TuyaAccessory] Sending first query to lumière salle à manger (3.3) [TuyaAccessory] Heard back from lumière ma chérie with command 10 [5/6/2021, 5:17:58 PM] [TuyaLan] Ready to handle lumière ma chérie (TWLight:3.3) with signature {"20":false,"21":"white","22":152,"23":560,"25":"000e0d0000000000000000c80000","26":0,"41":true} [TuyaAccessory] Heard back from lumière salle à manger with command 10 [5/6/2021, 5:17:58 PM] [TuyaLan] Ready to handle lumière salle à manger (TWLight:3.3) with signature {"20":false,"21":"white","22":1000,"23":0,"25":"000e0d0000000000000000c80000","26":0} [5/6/2021, 5:17:59 PM] [TuyaLan] Discovered lumière tv bas samsung (bf18bffe659100827cnrw8) identified as RGBTWLight (3.3) [TuyaAccessory] Changing ping gap for lumière tv bas samsung to 9s [5/6/2021, 5:17:59 PM] [TuyaLan] Connected to lumière tv bas samsung [TuyaAccessory] Sending first query to lumière tv bas samsung (3.3) [TuyaAccessory] Heard back from lumière tv bas samsung with command 10 [5/6/2021, 5:17:59 PM] [TuyaLan] Ready to handle lumière tv bas samsung (RGBTWLight:3.3) with signature {"20":false,"21":"white","22":1000,"23":0,"24":"000003e803e8","25":"000e0d0000000000000000c80000","26":0,"101":true} [TuyaAccessory] Color format for lumière tv bas samsung (3.3) is undetectable. [5/6/2021, 5:18:00 PM] [TuyaLan] Discovered lumière coté tv bas (bf05403d0f79d7b189f05x) identified as TWLight (3.3) [TuyaAccessory] Changing ping gap for lumière coté tv bas to 9s [5/6/2021, 5:18:00 PM] [TuyaLan] Connected to lumière coté tv bas [TuyaAccessory] Sending first query to lumière coté tv bas (3.3) [TuyaAccessory] Heard back from lumière coté tv bas with command 10 [5/6/2021, 5:18:00 PM] [TuyaLan] Ready to handle lumière coté tv bas (TWLight:3.3) with signature {"20":false,"21":"white","22":1000,"23":0,"25":"000e0d0000000000000000c80000","26":0} [5/6/2021, 5:18:00 PM] [TuyaLan] Discovered lumière canapé bas (bfc9cd4483310bfbc6q47z) identified as RGBTWLight (3.3) [TuyaAccessory] Changing ping gap for lumière canapé bas to 9s [5/6/2021, 5:18:00 PM] [TuyaLan] Connected to lumière canapé bas [TuyaAccessory] Sending first query to lumière canapé bas (3.3) [TuyaAccessory] Heard back from lumière canapé bas with command 10 [5/6/2021, 5:18:00 PM] [TuyaLan] Ready to handle lumière canapé bas (RGBTWLight:3.3) with signature {"1":false,"2":"white","3":255,"4":255,"5":"ff00000000ffff","101":true} [TuyaAccessory] Color format for lumière canapé bas (3.3) identified as HEXHSB (length: 14). [5/6/2021, 5:18:00 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'On': characteristic value expected boolean and received undefined. See https://git.io/JtMGR for more info. [5/6/2021, 5:18:00 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'Brightness': characteristic was supplied illegal value: number -2 exceeded minimum of 0. See https://git.io/JtMGR for more info. [5/6/2021, 5:18:00 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'Color Temperature': characteristic value expected valid finite number and received "NaN" (number). See https://git.io/JtMGR for more info. [5/6/2021, 5:18:01 PM] [TuyaLan] Discovered lumière TV haut (bff793578be8c70455ftcl) identified as RGBTWLight (3.3) [TuyaAccessory] Changing ping gap for lumière TV haut to 9s [5/6/2021, 5:18:01 PM] [TuyaLan] Connected to lumière TV haut [TuyaAccessory] Sending first query to lumière TV haut (3.3) [TuyaAccessory] Heard back from lumière TV haut with command 10 [5/6/2021, 5:18:01 PM] [TuyaLan] Ready to handle lumière TV haut (RGBTWLight:3.3) with signature {"20":false,"21":"white","22":1000,"23":0,"24":"000003e803e8","25":"000e0d0000000000000000c80000","26":0,"101":true} [TuyaAccessory] Color format for lumière TV haut (3.3) is undetectable. [5/6/2021, 5:18:02 PM] [TuyaLan] Discovered lumière Alex (bf9b2c149e42fb0101isnf) identified as TWLight (3.3) [TuyaAccessory] Changing ping gap for lumière Alex to 9s [5/6/2021, 5:18:02 PM] [TuyaLan] Connected to lumière Alex [TuyaAccessory] Sending first query to lumière Alex (3.3) [TuyaAccessory] Heard back from lumière Alex with command 10 [5/6/2021, 5:18:02 PM] [TuyaLan] Ready to handle lumière Alex (TWLight:3.3) with signature {"20":false,"21":"white","22":126,"23":1000,"25":"000e0d0000000000000000c80000","26":0,"41":true} [5/6/2021, 5:18:12 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'Brightness': characteristic was supplied illegal value: number -2 exceeded minimum of 0. See https://git.io/JtMGR for more info. [5/6/2021, 5:18:12 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'Color Temperature': characteristic value expected valid finite number and received "NaN" (number). See https://git.io/JtMGR for more info. [5/6/2021, 5:18:12 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'On': characteristic value expected boolean and received undefined. See https://git.io/JtMGR for more info. [5/6/2021, 5:18:22 PM] [Google Smart Home] Finished instance discovery [5/6/2021, 5:18:37 PM] [Google Smart Home] Sending Sync Request [5/6/2021, 5:33:13 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'Brightness': characteristic was supplied illegal value: number -2 exceeded minimum of 0. See https://git.io/JtMGR for more info. [5/6/2021, 5:33:13 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'Color Temperature': characteristic value expected valid finite number and received "NaN" (number). See https://git.io/JtMGR for more info. [5/6/2021, 5:33:13 PM] [homebridge-tuya-lan] This plugin generated a warning from the characteristic 'On': characteristic value expected boolean and received undefined. See https://git.io/JtMGR for more info.

MY config json :

"platform": "TuyaLan",
"devices": [
    {
        "name": "lumière ma chérie",
        "type": "TWLight",
        "manufacturer": "LSC",
        "model": "A60 GOLD",
        "id": "XX",
        "key": "XX",
        "dpPower": 20,
        "dpBrightness": 22,
        "dpColorTemperature": 23,
        "minWhiteColor": 140,
        "maxWhiteColor": 400,
        "scaleBrightness": 1000,
        "scaleWhiteColor": 1000
    },
    {
        "name": "lumière Alex",
        "type": "TWLight",
        "manufacturer": "LSC",
        "model": "A60 GOLD 2",
        "id": "XX",
        "key": "XX",
        "dpPower": 20,
        "dpBrightness": 22,
        "dpColorTemperature": 23,
        "minWhiteColor": 140,
        "maxWhiteColor": 400,
        "scaleBrightness": 1000,
        "scaleWhiteColor": 1000
    },
    {
        "name": "lumière TV haut",
        "type": "RGBTWLight",
        "manufacturer": "LSC",
        "model": "LSC Light Strip-RGBCW-Wifi",
        "id": "XX",
        "key": "XXa",
        "dpPower": 20,
        "dpBrightness": 22,
        "dpColorTemperature": 23,
        "minWhiteColor": 140,
        "maxWhiteColor": 400,
        "scaleBrightness": 1000,
        "scaleWhiteColor": 1000
    },
    {
        "name": "lumière canapé bas",
        "type": "RGBTWLight",
        "manufacturer": "LSC",
        "model": "lumière canapé",
        "id": "XX",
        "key": "XX",
        "dpPower": 20,
        "dpBrightness": 22,
        "dpColorTemperature": 23,
        "minWhiteColor": 140,
        "maxWhiteColor": 400,
        "scaleBrightness": 1000,
        "scaleWhiteColor": 1000
    },
    {
        "name": "lumière salle à manger",
        "type": "TWLight",
        "manufacturer": "LSC",
        "model": "LSC A60 CCT",
        "id": "XX",
        "key": "XX",
        "dpPower": 20,
        "dpBrightness": 22,
        "dpColorTemperature": 23,
        "minWhiteColor": 140,
        "maxWhiteColor": 400,
        "scaleBrightness": 1000,
        "scaleWhiteColor": 1000
    },
    {
        "name": "lumière coté tv bas",
        "type": "TWLight",
        "manufacturer": "LSC",
        "model": "Lumière côté Tv",
        "id": "XX",
        "key": "XX",
        "dpPower": 20,
        "dpBrightness": 22,
        "dpColorTemperature": 23,
        "minWhiteColor": 140,
        "maxWhiteColor": 400,
        "scaleBrightness": 1000,
        "scaleWhiteColor": 1000
    },
    {
        "name": "lumière tv bas samsung",
        "type": "RGBTWLight",
        "manufacturer": "LSC",
        "model": "Lumière TV bas",
        "id": "XX",
        "key": "XX",
        "dpPower": 20,
        "dpBrightness": 22,
        "dpColorTemperature": 23,
        "minWhiteColor": 140,
        "maxWhiteColor": 400,
        "scaleBrightness": 1000,
        "scaleWhiteColor": 1000
    }
]

Why I can't see my device in HOMEKIT ?

Many thanks to help

kanmapoo commented 2 years ago

hi, try this "dpPower": "20", "dpMode": "21", "dpBrightness": "22", "dpColorTemperature": "23", "dpColor": "24", "maxWhiteColor": "221", "colorFunction": "HSB", "minBrightness": 10, "scaleBrightness": 1000, "scaleWhiteColor": 1000

SoCuul commented 10 months ago

Thank you so much!! You saved my ass haha.