IMX462 Camera on Waveshare CM4 IO POE

Hello.

Today I got ArduCam IMX462 module from Amazon ( Amazon.com: Arducam for Raspberry Pi 5 Camera Module, IMX462 Color Ultra Low Light Camera, CMOS Camera with 141°(H) Wide-Angle M12 Lens, High NIR Sensitivity Camera for Raspberry Pi : Electronics ). CM4 module with 4GB memory and 32GB EMMC, latest Bookworm official image that works good with official IMX500. But I can’t get ArduCam IMX462. I found firmware update for B0444 but it is failed:
[INFO] Firmware Version: 0x10003
[INFO] Sensor ID: 0x00B2
[INFO] ==================First stage==================
[INFO] Write update flag 2.
[INFO] Write checksum.
[INFO] Write update flag.
[INFO] Sending… |=================================================================================================| ETA: 0h01m02s
[INFO] All data has been sent.
[INFO] Updating…
[SUCCESS] Firmware update successful.
[INFO] Firmware Version: 0x10003
[INFO] Sensor ID: 0x00B2
[SUCCESS] ==================First stage success==================
[INFO] ==================Second stage==================
[INFO] Write update flag.
[INFO] Write checksum.
[INFO] Sending… |=================================================================================================| ETA: 0h00m01s
[INFO] All data has been sent.
[INFO] Updating…
[ERROR] Firmware verification failed. val: 2
[ERROR] The second stage fails, exit the program.

My config.txt:
#dtparam=i2c_arm=on
dtparam=i2s=on
#dtparam=spi=on

Enable audio (loads snd_bcm2835)

#dtparam=audio=on

Automatically load overlays for detected cameras

camera_auto_detect=0

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

dtoverlay=disable-wifi
dtoverlay=arducam-pivariety

hdmi_force_hotplug=1
config_hdmi_boost=10

disable_splash=1
dtoverlay=uart1
[cm4]
otg_mode=1

[cm5]
dtoverlay=dwc2,dr_mode=host

[all]
enable_uart=1

libcamera-hello app filed with error:
[0:01:01.056650722] [1623] INFO Camera camera_manager.cpp:327 libcamera v0.4.0+75-6a393eec-dirty (2025-02-05T06:09:21GMT)
[0:01:01.126156648] [1628] ERROR IPAProxy ipa_proxy.cpp:154 Configuration file ‘arducam-pivariety.json’ not found for IPA module ‘rpi/vc4’
terminate called after throwing an instance of ‘std::runtime_error’
what(): Exception during zlib decompression: (-3) unknown compression method
Aborted

What I have to do to fix it? Thanks

I found that problem is in tuning data that stored in camera. Tuning data is stage 2 in firmware update. Libcamera trying to read tuning data via i2c but got garbage and can’t decompress it and then crash. I made simple app to write tuning data via arducam-pivariety-sdk-dev but it is very unstable. It can write tuning data once but second call failed with the same error 2 as firmware update. After reboot I can write tuning data again but just once. Something wrong with current sensor firmware and have to be fixed by ArduCam. Also ArduCam have to change libcamera arducam helper to support ignoring tuning data in camera and load it from file.

I found the problem - low cpu speed on fimware upgrade. For some reason firmware upgrade unstable on low cpu speed. Once I turn performance scaling governor “echo performance | sudo tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor” I was able to finish firmware upgrade without errors and now camera works fine.

2 Likes

You are awesome for sharing this.