• DepthAI-v2
  • Getting the OAK 1 POE to work with raspberry pi

Hi, i'm having trouble to connect the OAK 1 POE to a raspberry pi with no Router or DHCP server.
My setup is my raspberry pi + TP Link POE Injector + OAK 1 POE

I could make work this setup (without a dhcp server) using the pre-compiled .exe demo software on my windows machine.
However, i could not make the demo codes & examples to connet to the camera on the raspberry pi.

I followed the directions here and here (installed raspbian dependencies too)

i can ping the device that falled back to the default ip address (169.254.1.222) but cant access it with the provided examples and demo.

The raspberry is connected to a wifi network that has its own DHCP server and also via ethernet to the OAK camera.

i can not figure how to configure a static IP that works with my setup

can you guide me ?
thanks,

greffeb

  • erik replied to this.

    Hello greffeb , could you set static IP of RPi to eg. 169.254.1.100?
    Thanks, Erik

      Hello erik, thank for the quick response

      i have some issues configuring the raspberry to accept a static IP

      i edited the dhcpcd file
      sudo nano /etc/dhcpcd.conf

      interface eth0
      static ip_address=169.254.1.100/24
      static routers=169.254.1.1
      static domain_name_servers=169.254.1.1

      after a reboot, the eth0 interface is now disabled and i cant ping the camera

      the current setup i have is RASP ---eth-----injector--------eth--------OAK
      no connexion to another external network

      i guess this is more a raspbian issue but any help is appreciated.

      greffeb

      Hi,

      to exclude most of my modifications from the equation, i did a clean install of the RPi and depthAI software package

      mkdir oak
      cd oak
      sudo apt update && sudo apt dist-upgrade -y
      PATH=$PATH:/home/pi/.local/bin
      sudo curl -fL https://docs.luxonis.com/install_dependencies.sh | bash
      python3 -m pip install depthai
      git clone https://github.com/luxonis/depthai-python.git
      cd depthai-python
      cd examples
      python3 install_requirements.py
      python3 ColorCamera/rgb_preview.py

      the RPi got the IP 169.254.183.118/16
      and i'm able to ping the camera at address 169.254.1.222

      when i run the rgb_preview.py script i hear a distinct clic from the camera indicating that somethins is happening. but the test scritp return this error :

      RuntimeError: Failed to find device after booting, error message: X_LINK_DEVICE_NOT_FOUND

      any clue ?

      ok i got it to work,

      the issue was the RPi wasn't accepting a static IP like 169.254.1.100, the dhcpcd service was bootlooping and never assigning the static ip.
      With an address under 192.168.xxx.xxx, i was able to set a static IP.

      However, the camera was still set at the fallback IP 169.254.1.222
      So to make it work, i had to setup a DHCP server on the RPi to assign automatically an IP when connecting the camera. (mostly following this tutorial)

      i still get X_LINK_DEVICE_NOT_FOUND sometimes but i could launch the demo

      • erik replied to this.

        Great that you figured it out greffeb ! WRT sporadic X_LINK_DEVICE_NOT_FOUND error - do you wait some time between canceling the program and re-executing it? As OAK PoE needs about 10sec in between re-connecting to the device.
        Thanks, Erik

        Hi again !
        i think i bricked the camera by setting a static IP.
        device is not pingable and nothing shows up on the network.

        i want to factory reset the camera but the script return this error :
        skipping X_LINK_UNBOOTED device having name "<error>

        other scripts also gives this same error

        i'm currently using a laptop with the last ubuntu distro and usb3 ports

        edit ->

        again i spoke too soon this issue was resolved using this solution

        echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="03e7", MODE="0666"' | sudo tee /etc/udev/rules.d/80-movidius.rules
        sudo udevadm control --reload-rules && sudo udevadm trigger

        sorry for the spam

        18 days later

        Guys I'm totally kinda like a noob 😂, so I've ran this command : (python3 ColorCamera/rgb_preview.py ) to test my OAK D and the following error appears to me!!!??
        [2022-03-14 20:23:55.510] [warning] skipping X_LINK_UNBOOTED device having name "<error>"
        Traceback (most recent call last):
        File "/home/pi/depthai-python/examples/ColorCamera/rgb_preview.py", line 24, in <module>
        with dai.Device(pipeline) as device:
        RuntimeError: No available devices
        So, what's this and how to solve it?,, and thanks in advance for the one who's gonna help me..

        • erik replied to this.

          Hello MontaserAI , I'm not 100% sure, but have you tried setting udev rules?

          echo 'SUBSYSTEM=="usb", ATTRS{idVendor}=="03e7", MODE="0666"' | sudo tee /etc/udev/rules.d/80-movidius.rules
          sudo udevadm control --reload-rules && sudo udevadm trigger

          Otherwise, I would suggest using a preconfigured RPi image.
          Thanks, Erik