Arducam B0392 no cameras available, B0264/B0331 driver install fails, /dev/video0 missing on Pi 4B

Hi, I’m stuck getting a few different Arducam boards working on a Raspberry Pi 4B (8GB) running the latest Raspberry Pi OS (April 4th 2022). The boards are B0392, B0337, B0264 and B0331.

The B0392 won’t capture anything at all. Running:
libcamera-still -t 5000 -o test.jpg
returns:
Made X/EGL preview window
INFO Camera camera_manager.cpp:293 libcamera v0.0.0=3431-c4602118
ERROR: *** no cameras available ***

For the B0264 I tried installing the Arducam v4l2 driver and it failed partway through with:
install: cannot stat ‘./bin/5.15.32-v7l+/arducam.ko’ : No such file or directory
install: cannot stat ‘./bin/5.15.32-v7l+/arducam.dtbo’ : No such file or directory
I continued the install anyway and then ls /dev/video0 gives:
access impossible at ‘/dev/video0’ : No such file or directory

The B0331 does exactly the same as the B0264 - same install failure and no /dev/video0.

I also tried installing the 2020-08 system for the other cameras, but the Pi won’t even boot with it. It says start4.elf is not compatible and that newer software is needed.

I followed the paper manual and the online docs (the libcamera guide for the B0392, the multi-camera adapter board doc for the B0264, and the synchronized stereo camera HAT doc for the B0331). I’ve attached my system info, the system log, a photo of the setup and the exact errors.

Do I need an older Raspberry Pi OS version? Ideally I want to use MATLAB to program the Pi and the cameras. Any help would be appreciated.

Thanks for the detailed writeup. Let’s split this into two separate problems so we don’t mix things up: first solve the B0392, then deal with the other three cameras.

The B0392 is supposed to work on the latest Raspberry Pi systems, so it failing like this is not normal. Can you send us the info requested in this post so we can diagnose it?

For the B0337, B0264 and B0331 - these do need an older Raspberry Pi OS to work. Please try this image:
http://downloads.raspberrypi.org/raspios_full_armhf/images/raspios_full_armhf-2020-08-24/

Ok, thanks. I’ll put together the info you asked for on the B0392 and give that older image a shot for the other three. I’ll report back once I have results.

Two updates for you:

  1. B0392 - I think I know what’s happening. It looks like the driver for the IMX519 was installed at some point, which leaves a conflicting dtoverlay entry in your boot config. Can you manually edit /boot/config.txt and delete the line dtoverlay=imx519 under the [all] tag? Reboot after that and try libcamera-still again.

  2. Other cameras - some testing is needed here. Please also try a newer buster image:
    Index of /raspios_full_armhf/images/raspios_full_armhf-2021-05-28

Also, we just tested that buster SD card image ourselves and it works, so it should be a good base for the B0337/B0264/B0331.

Good news - the B0392 works now! Removing dtoverlay=imx519 from /boot/config.txt was it, thank you.

Still stuck on the other three though (B0337, B0264, B0331). The Buster system does boot up and work, but I get the same errors as at the very start - the same install failures and still no /dev/video0. I’ve attached the errors, system info, system log and setup photos again for this remaining problem.

Sorry for the wait on this one. For the remaining cameras, please follow these installation instructions - they cover the Arducam OBISP MIPI camera module driver for the latest RPi update:
https://www.arducam.com/docs/arducam-obisp-mipi-camera-module/3-use-on-raspberry-pi/3-0-emergent-temporary-driver-for-the-lastest-rpi-2020-12-02-update/

Give that a try and let us know how it goes.

Made some progress, but two new things came up:

B0337 and B0264 - with arducamstill -t 0 -pixfmt GREY -w 2560 -h 800 I can display images in real time, but the brightness is way too high. I tried adjusting exposure with v4l2-ctl -c exposure=… and it didn’t change the display at all.

B0331 - it works and I can see images in VLC media player, but from the command window I get “Unsupported video format”, and it says that for every format I try.

Any ideas on these?

Both of these are fixable:

  1. Exposure on B0337/B0264 - from the log it looks like a setting-order issue. When the camera is running, open another terminal and set the exposure there so it actually takes effect. Sometimes due to cache problems you need to set two different values in a row, for example:
    v4l2-ctl -c exposure=100
    v4l2-ctl -c exposure=101

  2. B0331 “Unsupported video format” - this is a format problem. The B0331 is monochrome (GREY). Most software can handle GREY fine, but when color RAW Bayer formats (BA81, pBAA, BG10) are used, a lot of software doesn’t support that format, which is what triggers the error. Stick to the monochrome/GREY format and it should be fine.

Thanks, those helped. Last batch of issues, this time around framerate and getting the cameras to work in other tools:

I tried changing the framerate with v4l2-ctl and directly in MotionEye, but nothing changed.

Quick recap of where we stand:

  • B0392: solved. The leftover dtoverlay=imx519 under [all] in /boot/config.txt was the culprit.
  • B0337/B0264 exposure: set the exposure from a second terminal while the camera is running; if it doesn’t take effect, set two different values in a row because of caching.
  • B0331: use the monochrome GREY format. The color RAW Bayer formats (BA81, pBAA, BG10) aren’t widely supported and cause the “Unsupported video format” error.

On the MATLAB / MotionEye / OpenCV framerate side - that part is still open, we don’t have a confirmed fix yet. The 2-3 fps vs 65 fps and the cap.get(cv2.CAP_PROP_FPS) error point at a format/pipeline negotiation issue rather than a dead camera. To narrow it down, please share the exact OpenCV code you’re running, the full output of v4l2-ctl --list-formats-ext for the camera, and how MATLAB is connecting to the Pi. Once we have those we can dig into it.