Skip to main content

Raspberry Pi 5 CM Bookworm

Prepare SD card

  • Device: Raspberry Pi 5 (Raspberry Pi 5, 500, and Compute Module 5)
  • OS: Raspberry Pi OS (64-bit) (tested with release 2025-05-13)

Connect CSI2 camera

image-1750065490758.jpg

OS Prepare

Login to your Raspberry device and update it first.

sudo apt update
sudo apt upgrade -y

IMX462

Camera 462x-CSI-M12x

Setup camera

Edit config file:

sudo nano /boot/firmware/config.txt
# camera_auto_detect=1 --- Find camera_auto_detect=1 and comment it out.

# Paste these lines at the end of the config file
dtoverlay=imx462,cam0,clock-frequency=37125000
camera_auto_detect=0

Note absent cam1 argument in dtoverlay string. If cam1 or cam0 is present Raspberry Pi will not recognize camera.

Reboot

Test camera

Check if camera is detected

libcamera-hello --list-cameras

Available cameras
-----------------
0 : imx462 [1920x1080 12-bit RGGB] (/base/axi/pcie@1000120000/rp1/i2c@88000/imx290@1a)
    Modes: 'SRGGB10_CSI2P' : 1280x720 [60.00 fps - (320, 180)/1280x720 crop]
                             1920x1080 [60.00 fps - (0, 0)/1920x1080 crop]
           'SRGGB12_CSI2P' : 1280x720 [60.00 fps - (320, 180)/1280x720 crop]
                             1920x1080 [60.00 fps - (0, 0)/1920x1080 crop]

Capture picture to /tmp/test.jpg

libcamera-jpeg -o /tmp/test.jpg -n

[0:10:00.777872901] [1898]  INFO Camera camera_manager.cpp:326 libcamera v0.5.0+59-d83ff0a4
[0:10:00.784948139] [1901]  INFO RPI pisp.cpp:720 libpisp version v1.2.1 981977ff21f3 29-04-2025 (14:13:50)
[0:10:00.797335934] [1901]  WARN CameraSensor camera_sensor_legacy.cpp:501 'imx462 10-001a': No sensor delays found in static properties. Assuming unverified defaults.
[0:10:00.797738960] [1901]  INFO RPI pisp.cpp:1179 Registered camera /base/axi/pcie@1000120000/rp1/i2c@88000/imx290@1a to CFE device /dev/media0 and ISP device /dev/media2 using PiSP variant BCM2712_D0
Mode selection for 960:540:12:P
    SRGGB10_CSI2P,1280x720/0 - Score: 1125
    SRGGB10_CSI2P,1920x1080/0 - Score: 1375
    SRGGB12_CSI2P,1280x720/0 - Score: 125
    SRGGB12_CSI2P,1920x1080/0 - Score: 375
Stream configuration adjusted
[0:10:00.798351119] [1898]  INFO Camera camera.cpp:1205 configuring streams: (0) 960x540-YUV420 (1) 1280x720-RGGB_PISP_COMP1
[0:10:00.798444510] [1901]  INFO RPI pisp.cpp:1483 Sensor: /base/axi/pcie@1000120000/rp1/i2c@88000/imx290@1a - Selected sensor format: 1280x720-SRGGB12_1X12 - Selected CFE format: 1280x720-PC1R
Mode selection for 1920:1080:12:P
    SRGGB10_CSI2P,1280x720/0 - Score: 3000
    SRGGB10_CSI2P,1920x1080/0 - Score: 1000
    SRGGB12_CSI2P,1280x720/0 - Score: 2000
    SRGGB12_CSI2P,1920x1080/0 - Score: 0
Stream configuration adjusted
[0:10:06.029136925] [1898]  INFO Camera camera.cpp:1205 configuring streams: (0) 1920x1080-YUV420 (1) 1920x1080-RGGB_PISP_COMP1
[0:10:06.034005267] [1901]  INFO RPI pisp.cpp:1483 Sensor: /base/axi/pcie@1000120000/rp1/i2c@88000/imx290@1a - Selected sensor format: 1920x1080-SRGGB12_1X12 - Selected CFE format: 1920x1080-PC1R
Still capture image received