Pi 5 Multiplexor ov5647 Only 1 Cam detected,

  1. Where did you get the camera module(s)?
    UCTRONICS # our Shipment #1000044768 for Order #1000032393

  2. Model number of the product(s)?

Quick-Start-Guide-for-Multi-Adapter-Board #for-quad-camera-adapter-boardb012001

4x Arducam Cameras
Raspberry-Pi-Camera Motorized-Focus-Camera Quick-Start-Guide OV5647-Motorized-Focus-Camera

  1. What hardware/platform were you working on?
    Pi 5

  2. Instructions you have followed. (link/manual/etc.)

Quick-Start-Guide-for-Multi-Adapter-Board

  1. Problems you were having?
    One Cam detected, No image

  2. The dmesg log from your hardware?
    See below

  3. Troubleshooting attempts you’ve made?
    Check Cableig , Check Config, Enable I2C, Search forums
    Clean Install Raspberry Pi 5 Os
    apt-get update && apt-get upgrade

  4. What help do you need?

I must be missing a driver or config or fault hardware?.

Usage ./diag.sh >> diags.txt 2>&1
------ dpkg -l | grep libcamera -----
ii  libcamera-ipa:arm64                  0.2.0+rpt20240418-1                 arm64        complex camera support library (IPA modules)
ii  libcamera-tools                      0.2.0+rpt20240418-1                 arm64        complex camera support library (tools)
ii  libcamera0.2:arm64                   0.2.0+rpt20240418-1                 arm64        complex camera support library
ii  pipewire-libcamera:arm64             0.3.65-3+rpt7+deb12u1               arm64        PipeWire libcamera plugin
ii  python3-libcamera:arm64              0.2.0+rpt20240418-1                 arm64        complex camera support library (Python bindings)
-------------------------------------

------ dmesg | grep ov56 ------
[    0.569264] platform 1f00110000.csi: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@88000/ov5647@36
[    3.129175] rp1-cfe 1f00110000.csi: found subdevice /axi/pcie@120000/rp1/i2c@88000/ov5647@36
[    3.164448] rp1-cfe 1f00110000.csi: Using sensor ov5647 6-0036 for capture
-------------------------------------

------ uname -a ------
Linux pi-ai 6.6.28+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.28-1+rpt1 (2024-04-22) aarch64 GNU/Linux
-------------------------------------

------ cat /etc/os-release ------
PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"
NAME="Debian GNU/Linux"
VERSION_ID="12"
VERSION="12 (bookworm)"
VERSION_CODENAME=bookworm
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
-------------------------------------

------ cat /proc/meminfo ------
MemTotal:        8244496 kB
MemFree:         6008048 kB
MemAvailable:    6958080 kB
Buffers:           38304 kB
Cached:          1202832 kB
SwapCached:            0 kB
Active:          1445056 kB
Inactive:         448144 kB
Active(anon):     884000 kB
Inactive(anon):        0 kB
Active(file):     561056 kB
Inactive(file):   448144 kB
Unevictable:      173312 kB
Mlocked:               0 kB
SwapTotal:        102384 kB
SwapFree:         102384 kB
Zswap:                 0 kB
Zswapped:              0 kB
Dirty:                32 kB
Writeback:             0 kB
AnonPages:        825424 kB
Mapped:           401152 kB
Shmem:            231904 kB
KReclaimable:      29840 kB
Slab:              71056 kB
SReclaimable:      29840 kB
SUnreclaim:        41216 kB
KernelStack:        6992 kB
PageTables:        17168 kB
SecPageTables:         0 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:     4224624 kB
Committed_AS:    3649936 kB
VmallocTotal:   68180246528 kB
VmallocUsed:       21936 kB
VmallocChunk:          0 kB
Percpu:             1280 kB
CmaTotal:         327680 kB
CmaFree:          311200 kB
-------------------------------------

------ cat /boot/config.txts ------
cat: /boot/config.txts: No such file or directory
-------------------------------------

------ cat /boot/firmware/config.txt ------
# For more options and information see
# http://rptl.io/configtxt
# Some settings may impact device functionality. See link above for details

# Uncomment some or all of these to enable the optional hardware interfaces
dtparam=i2c_arm=on
#dtparam=i2s=on
#dtparam=spi=on

# Enable audio (loads snd_bcm2835)
dtparam=audio=on

# Additional overlays and parameters are documented
# /boot/firmware/overlays/README

# Automatically load overlays for detected cameras
camera_auto_detect=1
#add Following content: 
dtoverlay=camera-mux-4port,cam0-ov5647,cam1-ov5647,cam2-ov5647,cam3-ov5647


# Automatically load overlays for detected DSI displays
display_auto_detect=1

# Automatically load initramfs files, if found
auto_initramfs=1

# Enable DRM VC4 V3D driver
dtoverlay=vc4-kms-v3d
max_framebuffers=2

# Don't have the firmware create an initial video= setting in cmdline.txt.
# Use the kernel's default instead.
disable_fw_kms_setup=1

# Run in 64-bit mode
arm_64bit=1

# Disable compensation for displays with overscan
disable_overscan=1

# Run as fast as firmware / board allows
arm_boost=1

[cm4]
# Enable host mode on the 2711 built-in XHCI USB controller.
# This line should be removed if the legacy DWC2 controller is required
# (e.g. for USB device mode) or if USB support is not required.
otg_mode=1

[all]

-------------------------------------

------ libcamera-still  --list-cameras ------
Available cameras
-----------------
0 : ov5647 [2592x1944 10-bit GBRG] (/base/axi/pcie@120000/rp1/i2c@88000/ov5647@36)
    Modes: 'SGBRG10_CSI2P' : 640x480 [58.92 fps - (16, 0)/2560x1920 crop]
                             1296x972 [43.25 fps - (0, 0)/2592x1944 crop]
                             1920x1080 [30.62 fps - (348, 434)/1928x1080 crop]
                             2592x1944 [15.63 fps - (0, 0)/2592x1944 crop]

-------------------------------------

------ libcamera-hello ------
[0:07:39.350217120] [2688] e[1;32m INFO e[1;37mCamera e[1;34mcamera_manager.cpp:284 e[0mlibcamera v0.2.0+120-eb00c13d
[0:07:39.357996263] [2691] e[1;32m INFO e[1;37mRPI e[1;34mpisp.cpp:695 e[0mlibpisp version v1.0.5 999da5acb4f4 17-04-2024 (14:29:29)
[0:07:39.374446340] [2691] e[1;32m INFO e[1;37mRPI e[1;34mpisp.cpp:1154 e[0mRegistered camera /base/axi/pcie@120000/rp1/i2c@88000/ov5647@36 to CFE device /dev/media0 and ISP device /dev/media2 using PiSP variant BCM2712_C0
Made X/EGL preview window
[0:07:39.735033104] [2688] e[1;33m WARN e[1;37mV4L2 e[1;34mv4l2_pixelformat.cpp:344 e[0mUnsupported V4L2 pixel format RPBP
Mode selection for 1296:972:12:P
    SGBRG10_CSI2P,640x480/0 - Score: 3296
    SGBRG10_CSI2P,1296x972/0 - Score: 1000
    SGBRG10_CSI2P,1920x1080/0 - Score: 1349.67
    SGBRG10_CSI2P,2592x1944/0 - Score: 1567
Stream configuration adjusted
[0:07:39.735332849] [2688] e[1;32m INFO e[1;37mCamera e[1;34mcamera.cpp:1183 e[0mconfiguring streams: (0) 1296x972-YUV420 (1) 1296x972-GBRG_PISP_COMP1
[0:07:39.735462851] [2691] e[1;32m INFO e[1;37mRPI e[1;34mpisp.cpp:1450 e[0mSensor: /base/axi/pcie@120000/rp1/i2c@88000/ov5647@36 - Selected sensor format: 1296x972-SGBRG10_1X10 - Selected CFE format: 1296x972-PC1g
[0:07:44.481358839] [2691] e[1;33m WARN e[1;37mV4L2 e[1;34mv4l2_videodevice.cpp:2007 e[0;32m/dev/video4[16:cap]: e[0mDequeue timer of 1000000.00us has expired!
[0:07:44.481429859] [2691] e[1;31mERROR e[1;37mRPI e[1;34mpipeline_base.cpp:1334 e[0mCamera frontend has timed out!
[0:07:44.481440748] [2691] e[1;31mERROR e[1;37mRPI e[1;34mpipeline_base.cpp:1335 e[0mPlease check that your camera sensor connector is attached securely.
[0:07:44.481449359] [2691] e[1;31mERROR e[1;37mRPI e[1;34mpipeline_base.cpp:1336 e[0mAlternatively, try another cable and/or sensor.
ERROR: Device timeout detected, attempting a restart!!!
-------------------------------------


michael@pi-ai:~ $ libcamera-still -t 0 --camera 0
[0:09:23.618626493] [2776]  INFO Camera camera_manager.cpp:284 libcamera v0.2.0+120-eb00c13d
[0:09:23.626471137] [2779]  INFO RPI pisp.cpp:695 libpisp version v1.0.5 999da5acb4f4 17-04-2024 (14:29:29)
[0:09:23.642511449] [2779]  INFO RPI pisp.cpp:1154 Registered camera /base/axi/pcie@120000/rp1/i2c@88000/ov5647@36 to CFE device /dev/media0 and ISP device /dev/media2 using PiSP variant BCM2712_C0
Made X/EGL preview window
[0:09:24.015810960] [2776]  WARN V4L2 v4l2_pixelformat.cpp:344 Unsupported V4L2 pixel format RPBP
Mode selection for 1296:972:12:P
    SGBRG10_CSI2P,640x480/0 - Score: 3296
    SGBRG10_CSI2P,1296x972/0 - Score: 1000
    SGBRG10_CSI2P,1920x1080/0 - Score: 1349.67
    SGBRG10_CSI2P,2592x1944/0 - Score: 1567
Stream configuration adjusted
[0:09:24.016130501] [2776]  INFO Camera camera.cpp:1183 configuring streams: (0) 1296x972-YUV420 (1) 1296x972-GBRG_PISP_COMP1
[0:09:24.016270022] [2779]  INFO RPI pisp.cpp:1450 Sensor: /base/axi/pcie@120000/rp1/i2c@88000/ov5647@36 - Selected sensor format: 1296x972-SGBRG10_1X10 - Selected CFE format: 1296x972-PC1g
[0:09:30.051784478] [2779]  WARN V4L2 v4l2_videodevice.cpp:2007 /dev/video4[16:cap]: Dequeue timer of 1000000.00us has expired!
[0:09:30.051832683] [2779] ERROR RPI pipeline_base.cpp:1334 Camera frontend has timed out!
[0:09:30.051841461] [2779] ERROR RPI pipeline_base.cpp:1335 Please check that your camera sensor connector is attached securely.
[0:09:30.051848813] [2779] ERROR RPI pipeline_base.cpp:1336 Alternatively, try another cable and/or sensor.
ERROR: Device timeout detected, attempting a restart!!!
s

Images supporting above issue are here including what the Camera output currently looks like.

https://drive.google.com/drive/folders/1riWkl6YiJKXz2chzoCrpEncfJ9XASBn9?usp=sharing

I found a prospective solution but the forum thread was dated way back in 22.

Noted here.

Either the pulls been merged into the code base or something, either way the artefacts are gone.

sudo rpi-update pulls/5744
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
 *** Performing self-update
 *** Relaunching after update
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
FW_REV:
BOOTLOADER_REV:2bfd7cb74e6bc16559e040d0f5d788a4411819e4
 *** We're running for the first time
 *** Backing up files (this will take a few minutes)
 *** Remove old firmware backup
 *** Backing up firmware
 *** Remove old modules backup
 *** Backing up modules 6.6.28+rpt-rpi-2712
WANT_32BIT:0 WANT_64BIT:1 WANT_PI4:1 WANT_PI5:1
Downloading bootloader tools
Downloading bootloader images
 *** Downloading specific artifact revision (this will take a few minutes)
curl  -L https://builds.raspberrypi.com/github/linux/11357ac4f0bb0dad2ac567a680ae469cd4dc6a86/bcmrpi | zcat | tar xf - -C //root/.rpi-firmware --strip-components=2
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:04 --:--:--     0

gzip: stdin: unexpected end of file
tar: This does not look like a tar archive
tar: Exiting with failure status due to previous errors
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:04 --:--:--     0
Invalid artifact specified. Response: 404.

Hi,
Please change camera_auto_detect=1 to camera_auto_detect=0 in the config.txt file.
Besides, you can try the troubleshooting below:
https://docs.arducam.com/Raspberry-Pi-Camera/Native-camera/Troubleshooting/#12-time-error-occurs-when-using-multi-camera-adapter-board-on-pi5

Thanks Dion

I have moved the cable to the second camera port on the Pi5 as per you email. and changed the auto detect

# Automatically load overlays for detected cameras
camera_auto_detect=0
#add Following content: 
dtoverlay=camera-mux-4port,cam0-ov5647,cam1-ov5647,cam2-ov5647,cam3-ov5647

I’m now experiencing the following.
Camera detected in dmesg.

~ $ dmesg | grep ov56
[    0.975928] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@0/ov5647@36
[    0.976127] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@1/ov5647@36
[    0.977093] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@2/ov5647@36
[    0.977246] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@3/ov5647@36

Device is timing out.

michael@pi-ai:~ $ libcamera-still -t 0 --camera 3
[0:02:06.806204415] [2237]  INFO Camera camera_manager.cpp:284 libcamera v0.2.0+120-eb00c13d
[0:02:06.814954568] [2240]  INFO RPI pisp.cpp:695 libpisp version v1.0.5 999da5acb4f4 17-04-2024 (14:29:29)
[0:02:06.832811873] [2240]  INFO RPI pisp.cpp:1154 Registered camera /base/axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@2/ov5647@36 to CFE device /dev/media1 and ISP device /dev/media0 using PiSP variant BCM2712_C0
[0:02:06.832874062] [2240]  INFO RPI pisp.cpp:695 libpisp version v1.0.5 999da5acb4f4 17-04-2024 (14:29:29)
[0:02:06.852414628] [2240]  INFO RPI pisp.cpp:1154 Registered camera /base/axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@1/ov5647@36 to CFE device /dev/media1 and ISP device /dev/media0 using PiSP variant BCM2712_C0
[0:02:06.852507318] [2240]  INFO RPI pisp.cpp:695 libpisp version v1.0.5 999da5acb4f4 17-04-2024 (14:29:29)
[0:02:06.862006049] [2240]  INFO RPI pisp.cpp:1154 Registered camera /base/axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@0/ov5647@36 to CFE device /dev/media1 and ISP device /dev/media0 using PiSP variant BCM2712_C0
[0:02:06.862062201] [2240]  INFO RPI pisp.cpp:695 libpisp version v1.0.5 999da5acb4f4 17-04-2024 (14:29:29)
[0:02:06.879193948] [2240]  INFO RPI pisp.cpp:1154 Registered camera /base/axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@3/ov5647@36 to CFE device /dev/media1 and ISP device /dev/media0 using PiSP variant BCM2712_C0
Made X/EGL preview window
[0:02:07.240201409] [2237]  WARN V4L2 v4l2_pixelformat.cpp:344 Unsupported V4L2 pixel format RPBP
Mode selection for 1296:972:12:P
    SGBRG10_CSI2P,640x480/0 - Score: 3296
    SGBRG10_CSI2P,1296x972/0 - Score: 1000
    SGBRG10_CSI2P,1920x1080/0 - Score: 1349.67
    SGBRG10_CSI2P,2592x1944/0 - Score: 1567
Stream configuration adjusted
[0:02:07.240473961] [2237]  INFO Camera camera.cpp:1183 configuring streams: (0) 1296x972-YUV420 (1) 1296x972-GBRG_PISP_COMP1
[0:02:07.240594615] [2240]  INFO RPI pisp.cpp:1450 Sensor: /base/axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@0/ov5647@36 - Selected sensor format: 1296x972-SGBRG10_1X10 - Selected CFE format: 1296x972-PC1g
[0:02:08.308344656] [2240]  WARN V4L2 v4l2_videodevice.cpp:2007 /dev/video4[51:cap]: Dequeue timer of 1000000.00us has expired!
[0:02:08.308387381] [2240] ERROR RPI pipeline_base.cpp:1334 Camera frontend has timed out!
[0:02:08.308393140] [2240] ERROR RPI pipeline_base.cpp:1335 Please check that your camera sensor connector is attached securely.
[0:02:08.308398603] [2240] ERROR RPI pipeline_base.cpp:1336 Alternatively, try another cable and/or sensor.
ERROR: Device timeout detected, attempting a restart!!!

Will check your link for trouble shooting this issue.

Hi @Dion I have followed the instructions provided to attempt to resolve the time out issue.

However they seem to be out of dete.

I have successful downloaded and replaced the driver from here.

sudo cp /home/michael/Downloads/arducam-wiki-multicameraboard-driver-rp1-cfe.ko.xz /lib/modules/6.6.28+rpt-rpi-2712/kernel/drivers/media/platform/raspberrypi/rp1_cfe/rp1-cfe.ko.xz

then

sudo depmod -a

However the change in sudo rpi-update pulls/5744 fails.

sudo rpi-update pulls/5744
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
 *** Performing self-update
 *** Relaunching after update
 *** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
FW_REV:
BOOTLOADER_REV:61fb89536fc94a57c1e0afd42617849b6d0cac37
 *** We're running for the first time
 *** Backing up files (this will take a few minutes)
 *** Remove old firmware backup
 *** Backing up firmware
 *** Remove old modules backup
 *** Backing up modules 6.6.28+rpt-rpi-2712
WANT_32BIT:0 WANT_64BIT:1 WANT_PI4:1 WANT_PI5:1
Downloading bootloader tools
Downloading bootloader images
 *** Downloading specific artifact revision (this will take a few minutes)
curl  -L https://builds.raspberrypi.com/github/linux/11357ac4f0bb0dad2ac567a680ae469cd4dc6a86/bcmrpi | zcat | tar xf - -C //root/.rpi-firmware --strip-components=2
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:05 --:--:--     0

gzip: stdin: unexpected end of file
tar: This does not look like a tar archive
tar: Exiting with failure status due to previous errors
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:05 --:--:--     0
Invalid artifact specified. Response: 404.

The Current issue after the front end driver update and the failing to change rpi-update is

michael@pi-ai:~ $ dmesg | grep ov56
[    0.934445] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@0/ov5647@36
[    0.934910] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@1/ov5647@36
[    0.935123] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@2/ov5647@36
[    0.937374] platform video-mux: Fixed dependency cycle(s) with /axi/pcie@120000/rp1/i2c@80000/pca@70/i2c@3/ov5647@36
michael@pi-ai:~ $ libcamera-hello 
[0:10:26.321080629] [2842]  INFO Camera camera_manager.cpp:284 libcamera v0.2.0+120-eb00c13d
Made X/EGL preview window
ERROR: *** no cameras available ***

Please advise.

M