I am using a freshly installed Raspberry Pi OS and followed your tutorial:
$ uname -a
Linux raspberrypi 6.1.21-v8+ #1642 SMP PREEMPT Mon Apr 3 17:24:16 BST 2023 aarch64 GNU/Linux
$ cat /boot/config.txt
# For more options and information see
# Some settings may impact device functionality. See link above for details
# uncomment if you get no picture on HDMI for a default "safe" mode
# uncomment the following to adjust overscan. Use positive numbers if console
# goes off screen, and negative if there is too much border
# uncomment to force a console size. By default it will be display's size minus
# uncomment if hdmi display is not detected and composite is being output
# uncomment to force a specific HDMI mode (this will force VGA)
# uncomment to force a HDMI mode rather than DVI. This can make audio work in
# DMT (computer monitor) modes
# uncomment to increase signal to HDMI, if you have interference, blanking, or
# no display
# uncomment for composite PAL
#uncomment to overclock the arm. 700 MHz is the default.
# Uncomment some or all of these to enable the optional hardware interfaces
# Uncomment this to enable infrared communication.
# Additional overlays and parameters are documented /boot/overlays/README
# Enable audio (loads snd_bcm2835)
# Automatically load overlays for detected cameras
# Automatically load overlays for detected DSI displays
# Enable DRM VC4 V3D driver
# Run in 64-bit mode
# Disable compensation for displays with overscan
# 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.
# Run as fast as firmware / board allows
Capture at lower res behaves very much the same:
$ libcamera-jpeg -o test.jpg --width 1920 --height 1080 -v
info_text:#%frame (%fps fps) exp %exp ag %ag dg %dg
thumbnail width: 320
thumbnail height: 240
thumbnail quality: 70
AF on capture: 0
No connector ID specified. Choosing default from list:
Connector 32 (crtc 0): type 11, 0x0
Connector 42 (crtc 0): type 11, 0x0
Preview window unavailable
Running without preview window
[0:01:46.600644676]  INFO Camera camera_manager.cpp:299 libcamera v0.0.0+4226-8689dd6b
[0:01:46.619665669]  WARN CameraSensorProperties camera_sensor_properties.cpp:243 No static properties available for 'arducam_64mp'
[0:01:46.619719243]  WARN CameraSensorProperties camera_sensor_properties.cpp:245 Please consider updating the camera sensor properties database
[0:01:46.636289735]  WARN RPI raspberrypi.cpp:1366 Mismatch between Unicam and CamHelper for embedded data usage!
[0:01:46.637194254]  INFO RPI raspberrypi.cpp:1485 Registered camera /base/soc/i2c0mux/i2c@1/arducam_64mp@1a to Unicam device /dev/media2 and ISP device /dev/media1
Acquired camera /base/soc/i2c0mux/i2c@1/arducam_64mp@1a
Viewfinder size chosen is 4624x2600
[0:01:46.638772533]  INFO Camera camera.cpp:1028 configuring streams: (0) 4624x2600-YUV420
[0:01:46.639163459]  INFO RPI raspberrypi.cpp:851 Sensor: /base/soc/i2c0mux/i2c@1/arducam_64mp@1a - Selected sensor format: 4624x3472-SRGGB10_1X10 - Selected unicam format: 4624x3472-pRAA
Camera streams configured
NoiseReductionMode : [0..4]
AeEnable : [false..true]
FrameDurationLimits : [99997..237626997]
ColourCorrectionMatrix : [-16.000000..16.000000]
ScalerCrop : [(0, 0)/128x128..(0, 0)/9248x6944]
AwbMode : [0..7]
ExposureValue : [-8.000000..8.000000]
AeMeteringMode : [0..3]
Contrast : [0.000000..32.000000]
Saturation : [0.000000..32.000000]
LensPosition : [0.000000..32.000000]
AfRange : [0..2]
ColourGains : [0.000000..32.000000]
AnalogueGain : [1.000000..64.000000]
AfMetering : [0..1]
AfPause : [0..2]
ExposureTime : [254..237625637]
AfMode : [0..2]
AeConstraintMode : [0..3]
AfTrigger : [0..1]
AfSpeed : [0..1]
AeExposureMode : [0..3]
AfWindows : [(0, 0)/0x0..(65535, 65535)/65535x65535]
Brightness : [-1.000000..1.000000]
AwbEnable : [false..true]
Sharpness : [0.000000..16.000000]
Buffers allocated and mapped
Viewfinder setup complete
Initially I tried with one and two. I connected a second camera again. Now I got cameras connected to RX0 and RX1. Command output did not change (still hanging). I also tried to explicitly select one of the cameras (using i2cset -y 10 0x24 0x24 0x02 or i2cset -y 10 0x24 0x24 0x12). This still hangs.
So unfortunately no progress. We can try other RPIs (we got a bunch of them) or other SD cards with different OS if that helps. I am completely lost why this hangs and how to debug it. Should I hook up a logic analyser, scope, serial or JTAG somewhere?
Ok I understand now what you mean by two channel. So you have to populate RX0 or RX1 and RX2 or RX3? Guess that should go into the docs as it currently states that you can use “up to four cameras” which implies that a single camera should work as well.
I tried that and now it works. Thanks! I struggled a bit with the focus. Autofocus does not seem to work. Manual focus with a range of 6.5 (near infinity) to 5 (near) seems to be working.
We also bough four of those RJ45 extenders (U6248). Basically one for each of the cameras. Is there any trick to mount them on top of the hat? It seems like the upper connector on my hat is not populated. Even if it would not fit the power connector on the extender. Also stacking two extenders does not work. Looks like there is also no way to power extenders via USB like the hat. Any guidance on that?
I tried setting one channel via i2cset and that works fine. However, when I try autofocus I hear a loud click (similar but louder when you set a focus value above 9). It seems to drive the focus against one of the limits and fails to focus properly. This is not an issue for our usecase so don’t worry to much. We will just set focus manually.