I am making a surveillance system and it requires at least 6 cameras. Currently I have connected 4 to my PC by USB. I am using supplementary power for each camera since the USB output of my PC is sometimes not capable of delivering enough power.
currently they show up like this
kc@kc-B550I-AORUS-PRO-AX:~$ v4l2-ctl --list-devices
3.0 USB Camera: 3.0 USB Camera (usb-0000:05:00.0-1):
/dev/video4
/dev/video5
3.0 USB Camera: 3.0 USB Camera (usb-0000:0b:00.3-1):
/dev/video6
/dev/video7
3.0 USB Camera: 3.0 USB Camera (usb-0000:0b:00.3-2):
/dev/video0
/dev/video1
3.0 USB Camera: 3.0 USB Camera (usb-0000:0b:00.3-4):
/dev/video2
/dev/video3
However, when ruining the code only 3 shows up or 4 but one stops working immediately. I have try several combinations of USB ports and they keep failing. All the cameras are from the same brand and have identical characteristics the only difference is the path.
kc@kc-B550I-AORUS-PRO-AX:~$ sudo udevadm info --query=all --name=/dev/video0
[sudo] password for kc:
P: /devices/pci0000:00/0000:00:08.1/0000:0b:00.3/usb5/5-2/5-2:1.0/video4linux/video0
N: video0
L: 0
S: v4l/by-id/usb-3.0_USB_Camera_3.0_USB_Camera-video-index0
S: v4l/by-path/pci-0000:0b:00.3-usb-0:2:1.0-video-index0
E: DEVPATH=/devices/pci0000:00/0000:00:08.1/0000:0b:00.3/usb5/5-2/5-2:1.0/video4linux/video0
E: DEVNAME=/dev/video0
E: MAJOR=81
E: MINOR=0
E: SUBSYSTEM=video4linux
E: USEC_INITIALIZED=2221928306
E: ID_V4L_VERSION=2
E: ID_V4L_PRODUCT=3.0 USB Camera: 3.0 USB Camera
E: ID_V4L_CAPABILITIES=:capture:
E: ID_VENDOR=3.0_USB_Camera
E: ID_VENDOR_ENC=3.0\x20USB\x20Camera
E: ID_VENDOR_ID=05a3
E: ID_MODEL=3.0_USB_Camera
E: ID_MODEL_ENC=3.0\x20USB\x20Camera
E: ID_MODEL_ID=3291
E: ID_REVISION=1005
E: ID_SERIAL=3.0_USB_Camera_3.0_USB_Camera
E: ID_TYPE=video
E: ID_BUS=usb
E: ID_USB_INTERFACES=:0e0100:0e0200:
E: ID_USB_INTERFACE_NUM=00
E: ID_USB_DRIVER=uvcvideo
E: ID_PATH=pci-0000:0b:00.3-usb-0:2:1.0
E: ID_PATH_TAG=pci-0000_0b_00_3-usb-0_2_1_0
E: ID_FOR_SEAT=video4linux-pci-0000_0b_00_3-usb-0_2_1_0
E: COLORD_DEVICE=1
E: COLORD_KIND=camera
E: DEVLINKS=/dev/v4l/by-id/usb-3.0_USB_Camera_3.0_USB_Camera-video-index0 /dev/v4l/by-path/pci-0000:0b:00.3-usb-0:2:1.0-video-index0
E: TAGS=:seat:uaccess:
What can I do to keep them running?