-
Where did you get the camera module(s)?
Kickstarter -
Model number of the product(s)?
High Resolution Autofocus Camera Module for Raspberry Pi by Arducam
Raspberry Pi Zero 2 -
What hardware/platform were you working on?
Raspberry Pi OS Buster (Legacy), newest update -
Instructions you have followed. (link/manual/etc.)
Raspberry Pi libcamera Guide - Arducam
Also tried using vc4-kms-v3d,cma-96 and 128 in config.txt, as per the Libcamera & IMX519 FAQ
- Problems you were having?
Running Libcamera at its default settings results in “Failed to allocate buffers”:
It fails when the width parameter is greater than the height parameter.
pi@PiZero2:~ $ libcamera-hello
Preview window unavailable
[0:00:30.668841341] [866] INFO Camera camera_manager.cpp:293 libcamera v0.0.0
[0:00:30.709178945] [868] WARN CameraSensorProperties camera_sensor_properties.cpp:141 No static properties available for 'imx519'
[0:00:30.709330508] [868] WARN CameraSensorProperties camera_sensor_properties.cpp:143 Please consider updating the camera sensor properties database
[0:00:31.032610507] [868] ERROR DelayedControls delayed_controls.cpp:87 Delay request for control id 0x009a090a but control is not exposed by device /dev/video0
[0:00:31.042356549] [866] INFO Camera camera.cpp:937 configuring streams: (0) 2328x1748-YUV420
[0:00:31.043840195] [868] INFO RPI raspberrypi.cpp:122 Mode: 4656x3496 fmt RG10 Score: 2519 (best 2519)
[0:00:31.044064726] [868] INFO RPI raspberrypi.cpp:122 Mode: 3840x2160 fmt RG10 Score: 2148.24 (best 2148.24)
[0:00:31.044193320] [868] INFO RPI raspberrypi.cpp:122 Mode: 2328x1748 fmt RG10 Score: 1500 (best 1500)
[0:00:31.044313059] [868] INFO RPI raspberrypi.cpp:122 Mode: 1920x1080 fmt RG10 Score: 3819.24 (best 1500)
[0:00:31.044431184] [868] INFO RPI raspberrypi.cpp:122 Mode: 1280x720 fmt RG10 Score: 5819.24 (best 1500)
[0:00:31.044568737] [868] INFO RPI raspberrypi.cpp:122 Mode: 4656x3496 fmt pRAA Score: 2019 (best 1500)
[0:00:31.044688476] [868] INFO RPI raspberrypi.cpp:122 Mode: 3840x2160 fmt pRAA Score: 1648.24 (best 1500)
[0:00:31.044808684] [868] INFO RPI raspberrypi.cpp:122 Mode: 2328x1748 fmt pRAA Score: 1000 (best 1000)
[0:00:31.044924987] [868] INFO RPI raspberrypi.cpp:122 Mode: 1920x1080 fmt pRAA Score: 3319.24 (best 1000)
[0:00:31.045043528] [868] INFO RPI raspberrypi.cpp:122 Mode: 1280x720 fmt pRAA Score: 5319.24 (best 1000)
[0:00:31.045763059] [868] INFO RPI raspberrypi.cpp:624 Sensor: /base/soc/i2c0mux/i2c@1/imx519@1a - Selected mode: 2328x1748-pRAA
[0:00:31.221972591] [868] ERROR V4L2 v4l2_videodevice.cpp:1165 /dev/video14[15:cap]: Not enough buffers provided by V4L2VideoDevice
[0:00:31.231008632] [868] ERROR RPI raspberrypi.cpp:821 Failed to allocate buffers
I attempted smaller standard resolutions, but even down to 640x480 it would fail.
Then by accident I mixed up height and width, and typed in:
libcamera-jpeg --width 1080 --height 1920 -o test.jpg
…and it worked! So, I tried, and every portrait resolution worked, up to 1802x2324 (absolute max before failing)
I tried to see how close the width and height can be, and with a width of 1080, I can get as low as a height of 1228 before it fails. 600 x 682 works as well.
This means that it fails at anything under a 1:1.137 ratio.
The 1802x2324 is a different ratio, 1:128, but it might just due to the size that it’s failing.
-
The dmesg log from your hardware?
Every failed attempt produced this:
[ 2144.100678] cma: cma_alloc: alloc failed, req-size: 1516 pages, ret: -12
[ 2144.100701] bcm2835-isp bcm2835-isp: dma_alloc_coherent of size 6209536 failed -
Troubleshooting attempts you’ve made?
Attempted different resolution formats -
What help do you need?
Any suggestions on getting it to take a landscape pictures would be great!