• DepthAI-v2
  • Tried all PoE troubleshooting, still have error message: X_LINK_DEVICE_NOT_FOUND

I have an OAK-D PoE camera and I can't get any examples to work reliably with Windows 11. In all the examples I have tried, I get the error message "Failed to connect to device, error message: X_LINK_DEVICE_NOT_FOUND". Occasionally the camera connects and I can run an example, but the next time I run it I get this same error code even though I don't change any code.

I have looked through the PoE troubleshooting docs multiple times and nothing has worked. I have tried updating depthai to the latest version and the bootloader has been updated as well. I can ping my camera and it is using a static ip address. I have short cables and have tried specifying usb2. None of these solutions work for me

  • jakaskerl replied to this.
  • My virtual environment wasn't set up correctly and so I think that adding DEPTHAI_WATCHDOG_INITIAL_DELAY=60000 DEPTHAI_BOOTUP_TIMEOUT=60000 to my run command in the terminal wasn't working well. Once I fixed the virtual environment then the time delays worked and the connection stopped timing out after booting.

    Hi nathan45654
    Have you tried explicitly setting the IP of the device you are able to ping?
    Example here.
    If so what is the log output?

    Thanks,
    Jaka

    I was able to set the IP using that example and this is the output:

    -------------------------------------

    "1" to set a static IPv4 address

    "2" to set a dynamic IPv4 address

    "3" to clear the config

    Enter the number: 1

    -------------------------------------

    Enter IPv4: 10.95.76.10

    Enter IPv4 Mask: 255.255.255.0

    Enter IPv4 Gateway: 10.95.76.1

    Flashing static IPv4 10.95.76.10, mask 255.255.255.0, gateway 10.95.76.1 to the POE device. Enter 'y' to confirm. y

    Flashing successful.

    I tried some basic examples afterwards though, and I still get this error:

    Failed to find device after booting, error message: X_LINK_DEVICE_NOT_FOUND

      nathan45654

      Edit /etc/dhcpcd.conf using "sudo nano" and enter those two lines after your interface (in my case : interface eth0) : "nodhcp" and "nolink". The reason why your camera times out is because it tries to get a Link-Local IP address, but fails to do so in time. By disabling it, you get the IP straight off the bat, and there is no timeout.

      @jakaskerl This solution is something I figured on my own. I couldn't find help from the Luxonis discord back in the day and I've googled this issue for days, to no avail. Tagging you for future reference, if someone asks a similar question.

        nathan45654

        My bad, I misread and thought, from the title, that I could help.

        You could try and see if it does this : run an ipconfig multiple times after launching a python script. Try to notice what happens with the IP. Does it appear after it gives you a XLINKDEVICENOTFOUND? Sometimes before? It could be that it tries to fetch an IP through DHCP/IPV4LL, and fails to do so in time.

        At this point, if that is the behaviour, I don't know about the Windows side of things. You could try pinging jakaskerl. I assume you already set a static IP from the network interface in Windows, since you mentionned it has a static IP adress.

        Anyway, that's the best I can personally give you. Good luck.

          Thanks FrancisGuindon I tried your advice and didn't see anything strange running ipconfig. I think that you're right about how it's something to do with the IP address.

          @jakaskerl Do you have any ideas as to what else I could try?

            Hi nathan45654
            Have you perhaps tried setting the DeviceInfo before connecting and uploading a pipeline?

            (found, info) = dai.DeviceBootloader.getFirstAvailableDevice()
            
            with dai.Device(info) as device:
            .
            .

            or just setting the info to the IP you set as static?

            Thanks,
            Jaka

            I finally found the fix, I added DEPTHAI_WATCHDOG_INITIAL_DELAY=60000 DEPTHAI_BOOTUP_TIMEOUT=60000 as suggested in the troubleshooting docs. I tried this before but after changing some other settings since then I must have gotten the right configuration because it is working every time now. Thank you for your help!

              Hi nathan45654
              Great! So what exactly did you change to fix the issue; just so anyone else stumbling across the thread can solve it as well?

              Thanks,
              Jaka

              My virtual environment wasn't set up correctly and so I think that adding DEPTHAI_WATCHDOG_INITIAL_DELAY=60000 DEPTHAI_BOOTUP_TIMEOUT=60000 to my run command in the terminal wasn't working well. Once I fixed the virtual environment then the time delays worked and the connection stopped timing out after booting.