How LocalTuya discovers Tuya devices

Sdílet
Vložit
  • čas přidán 25. 08. 2024
  • The LocalTuya integration on Home Assistant can "discover" local Tuya devices. However there is little to no documentation on how this process relates to whether you configure LocalTuya with your Cloud API details or not.
    The summary is that the LocalTuya process listens for broadcasts on UDP port 6667. If your Tuya devices are on another subnet (like mine all are, along with all of my other "IoT" devices), LocalTuya will not detect them.
    This means you need to manually:
    1. Find the device's IP address
    2. Look up the device ID in the Tuya Cloud portal and copy it to the clipboard
    3. Enter the API Explorer in the cloud portal, paste the Device ID and click Submit
    4. Note down the Local Key
    5. Manually add a new device in Local Tuya, typing in the IP address, Device ID, and Local Key
    This is a bit of a pain in the ass. I'm looking into a way to do broadcast forwarding using the network equipment that I have.

Komentáře • 20

  • @Tinju87
    @Tinju87 Před 8 měsíci

    THANK YOU. In your video I saw that the device name must match. Mine had a space at the end in tuya cloud. Adding this space made it work

  • @fabioalmeida4515
    @fabioalmeida4515 Před 8 měsíci

    Thank you for sharing!

  • @netlob
    @netlob Před 4 měsíci

    legend

  • @Hedphelym
    @Hedphelym Před 7 měsíci

    Is this possible on a different subnet? I can see the broadcast packets on my home assistant server, but localtuya still doesn't auto pick them up. My IOT network and HA network are on different subnets.

    • @KaldekBoch
      @KaldekBoch Před 7 měsíci

      Yeah I ended up using a tool on Linux called "bcrelay" which is part of a package called "poptop".
      My disclaimer is that I have dumped all of Tuya. Everything has been reflashed with ESPHome, which is much, *much* better.

  • @mbunal
    @mbunal Před 2 měsíci

    can I found cuppon smart devices with this way?

    • @kaltek797
      @kaltek797  Před 2 měsíci

      I honestly have no idea, sorry.

  • @smartsynciot19
    @smartsynciot19 Před rokem

    Tuya limit only allow two devices to give API. I can integrate only two devices with HA. Is that correct?

  • @ewertonmeira123
    @ewertonmeira123 Před rokem

    hello friend. All my devices are zigbee and local tuya didnt detected the devices automaticaly, but I know how to get the ID'd and Local Key, but I dont know how to get their Host. What host is this? Is it my home assistant IP or the Device IP? If it is the device, where can I find their IP?

    • @tomhueb793
      @tomhueb793 Před rokem

      Did you find an answer to this?

    • @ewertonmeira123
      @ewertonmeira123 Před rokem

      @@tomhueb793 they said that zigbee dont have this because it only works with wifi

  • @hothpeter
    @hothpeter Před rokem

    Hi KalTek, what happens if my Tuya trial account expires and I buy a new Tuya device after that ? Can I still get the device ID for the new Tuya device ? Can I still setup/configure the new Tuya device when my Tuya account is expired ?

    • @KaldekBoch
      @KaldekBoch Před rokem

      Hi mate, no and this is the problem with Tuya. The LocalTuya plugin needs to be able to see the existence of devices on the network, then authenticate to a Developer account and ask it for the Local Key. Without the developer account you can't get the keys.
      I'm in the middle of either reflashing all of my Tuya devices to Tasmota (where possible) or replacing them with Zigbee based devices, since HA has excellent native support for that protocol and there's no cloud vendors involved.

    • @hothpeter
      @hothpeter Před rokem

      @@KaldekBoch Thanks mate for the info. Cheers.

  • @gt-tech
    @gt-tech Před rokem

    Hey nice video.. i have some questions. I have home assistand in other network and iot devices in other wifi inside my network.. But i am stack with ip address.. I am using local ip of device and cant configure. I use my static external ip and same.. what ip need to configure the device?

    • @arslanmehdi3743
      @arslanmehdi3743 Před 7 měsíci

      Hi, did you find any solution

    • @gt-tech
      @gt-tech Před 7 měsíci

      @arslanmehdi3743 No I don't find what ip need. I let all tuya devices outside assistant to work with wifi as a new device you buy. I don't have so much time and I stop making changes. If I try again I will send you the solution. Thanks

    • @arslanmehdi3743
      @arslanmehdi3743 Před 7 měsíci

      @@gt-tech thanks