• DepthAI-v2
  • Can two OAK-Ds be used on one raspberry pi4?

As far as I know/have heard, I can use multiple OAK-Ds with one Raspberry Pi 4. I'm running this example with two OAK-D connected to Raspberry Pi4 but it recognizes only one of them. Is there anything that I have to do to start both OAK-Ds run separately?

Greetings,
Here are the instructions for setting up multiple DepthAI devices per host.

as Mojo mentioned, it should be possible, but you should use contextlib, demo code here. Also here's a gist of multiple devices running mobilenet. And I'm not sure if RPI4 will be able to deliver enough power to both devices, so you might need to power the devices with power adapter (not via USB).

8 months later

I'm a litt...lot late to this party but as my RPi4 is using PoE I'm able to set the USB-C port to host mode and run the second DAI device that way.

Using the two USB 3 ports I could get two Oak-1-Lites to display live video but as soon as I tried to enable nn on either one I would get this dreaded message on one that fails:

inPreview = qPreview.tryGet()
RuntimeError: Communication exception - possible device error/misconfiguration. Original message 'Couldn't read data from stream: 'preview' Traceback (most recent call last):

Using the below command they're both running nn's.

modprobe -r dwc2 && dtoverlay dwc2 dr_mode=host && modprobe dwc2

https://forums.raspberrypi.com/viewtopic.php?t=246348#p1504269