The Logitech Webcam USB Camera Sometimes Can't Be Captured

I used one usb camera(Logitech Webcam,046d:0893) in my many Xavier NX machines to get stream and detect objects using opencv and yolov5 model.
Sometimes the usb camera can be recognized by the usb driver,but can’t be captured by the opencv function. This is not always happen.

When this happened, I can resume it by reboot the machine or re-insert the kernel mode.
Could anyone tell me why and how to fix the problem?

When it happened, I used the lsusb to confirm that the usb camera can be recognized as bellow:

Bus 002 Device 003: ID 046d:0893 Logitech, Inc.
Bus 002 Device 002: ID 1d5c:5001  
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 0bda:c82c Realtek Semiconductor Corp. 
Bus 001 Device 005: ID 2949:8247  
Bus 001 Device 002: ID 1d5c:5011  
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

I used the v4l2-ctl to confirm that the usb camera can not be recognized by v4l2:

Then I used the command bellow, and it can be resumed, but sometimes will become error after a few minutes.

 rmmod uvcvideo
 modprobe uvcvideo nodrop=1 timeout=5000

It looks like the device cannot be enumerated successfully sometimes. Please try the commands:
Power down USB ports - #4 by vsaw

To trigger re-enumeration and check if the device can be detected in second try.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.