Intermittent failure due to EMI - Astra MINI PRO - recovery mechanism

Hello There,

From some of our clients where we have deployed our system with orbbec astra mini pro, using OpenNI SDK 2.3.85/2.3.86, we sometimes an issue of random camera freeze. From the dmesg logs, we have this(this is a very fresh log):

[Wed Jul 24 07:05:19 2024] usb usb3-port1: disabled by hub (EMI?), re-enabling...
[Wed Jul 24 07:05:19 2024] usb 3-1: USB disconnect, device number 2
[Wed Jul 24 07:05:20 2024] sched: RT throttling activated
[Wed Jul 24 07:05:20 2024] usb 3-1: new high-speed USB device number 10 using xhci_hcd
[Wed Jul 24 07:05:20 2024] usb 3-1: New USB device found, idVendor=2bc5, idProduct=0404, bcdDevice= 0.01
[Wed Jul 24 07:05:20 2024] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[Wed Jul 24 07:05:20 2024] usb 3-1: Product: ORBBEC Depth Sensor
[Wed Jul 24 07:05:20 2024] usb 3-1: Manufacturer: Orbbec(R)

So, ok, there are some EMI issues or a slight camera frame skip. Attaching part of the code, we have this to get the frames:

  int ChangedIndex;
  openni::VideoFrameRef CurrentDepthFrame;
  openni::VideoFrameRef CurrentColorFrame;
  openni::Status RC = openni::OpenNI::waitForAnyStream(MapStreamsToSerial.at(ActiveCameraSerial), 2, &ChangedIndex);
  MapStreamsToSerial.at(ActiveCameraSerial)[0]->readFrame(&CurrentColorFrame);
  MapStreamsToSerial.at(ActiveCameraSerial)[1]->readFrame(&CurrentDepthFrame);
  Color = createColorImageFromCameraData(CurrentColorFrame);
  Depth = createDepthImageFromCameraData(CurrentDepthFrame);

If a camera freezes(there are only 2 plugged in at all times), we have a watchdog that kills the main process. Now for the questions:

  • Can we somehow recover from intermittent failures? If by any chance there is an EMI issue, there is a way to recover quickly from it and only see a slight image lag? What is the best way to do this using the sdk?
  • We noticed that there may be a bug in code, since waitForAnyStream can give either the color frame ready (index 0) or depth frame ready (index 1). Could waitForAnyStream be giving index 1 and the color stream is not ready to be read? If so, how can we force sync of both those frames, so that we wont have any issue? Or what would be the most correct usage of the sdk?
  • ActiveCameraSerial does not give empty string or strings that are not initialized by the map, so we have no problem here.
  • Is there a way to reduce EMI to the cameras themselves? We are using the duripod already.

I hope to hear from you soon.

Best regards,
Alexandre pires

Hello,

Could we have any hints here to ensure that at least we are on the right path?

Best regards,

Hello once again,

I am pinging once again. Is there any way to help?

Best regards,