64mp can't take videos at 3840x2160 20fps

I am using one 64mp camera on raspberry pi 4B 4GB.
[email protected]:~ $ libcamera-vid --list-cameras
Available cameras
0 : arducam_64mp [9248x6944] (/base/soc/i2c0mux/[email protected]/[email protected])
Modes: ‘SRGGB10_CSI2P’ : 1280x720 [120.03 fps - (2064, 2032)/5120x2880 crop]
1920x1080 [60.04 fps - (784, 1312)/7680x4320 crop]
2312x1736 [30.00 fps - (0, 0)/9248x6944 crop]
3840x2160 [20.00 fps - (784, 1312)/7680x4320 crop]
4624x3472 [10.00 fps - (0, 0)/9248x6944 crop]
9152x6944 [2.70 fps - (0, 0)/9152x6944 crop]
[email protected]:~ $

[email protected]:~ $ libcamera-vid -t 0 --width 3840 --height 2160 --framerate 20 -o output1.mkv
Preview window unavailable
[1:10:40.076415119] [1602] INFO Camera camera_manager.cpp:293 libcamera v0.0.0+3897-c3c878a9
[1:10:40.084891584] [1604] WARN CameraSensorProperties camera_sensor_properties.cpp:174 No static properties available for ‘arducam_64mp’
[1:10:40.084936801] [1604] WARN CameraSensorProperties camera_sensor_properties.cpp:176 Please consider updating the camera sensor properties database
[1:10:40.109968739] [1604] WARN RPI raspberrypi.cpp:1280 Mismatch between Unicam and CamHelper for embedded data usage!
[1:10:40.111075176] [1604] ERROR DelayedControls delayed_controls.cpp:87 Delay request for control id 0x009a090a but control is not exposed by device /dev/v4l-subdev0
[1:10:40.111325890] [1604] INFO RPI raspberrypi.cpp:1404 Registered camera /base/soc/i2c0mux/[email protected]/[email protected] to Unicam device /dev/media3 and ISP device /dev/media0
[1:10:40.111983672] [1602] INFO Camera camera.cpp:1035 configuring streams: (0) 3840x2160-YUV420
[1:10:40.112494450] [1604] INFO RPI raspberrypi.cpp:765 Sensor: /base/soc/i2c0mux/[email protected]/[email protected] - Selected sensor format: 3840x2160-SBGGR10_1X10 - Selected unicam format: 3840x2160-pBAA
ERROR: *** failed to start output streaming ***
[email protected]:~ $

It is working fine with 1920x1080

[email protected]:~ $ libcamera-vid -t 0 --width 1920 --height 1080 --framerate 30 -o output1.mkv
Preview window unavailable
[0:29:03.280271042] [1457] INFO Camera camera_manager.cpp:293 libcamera v0.0.0+3897-c3c878a9
[0:29:03.288693369] [1459] WARN CameraSensorProperties camera_sensor_properties.cpp:174 No static properties available for ‘arducam_64mp’
[0:29:03.288770258] [1459] WARN CameraSensorProperties camera_sensor_properties.cpp:176 Please consider updating the camera sensor properties database
[0:29:03.313807887] [1459] WARN RPI raspberrypi.cpp:1280 Mismatch between Unicam and CamHelper for embedded data usage!
[0:29:03.314749800] [1459] ERROR DelayedControls delayed_controls.cpp:87 Delay request for control id 0x009a090a but control is not exposed by device /dev/v4l-subdev0
[0:29:03.314989635] [1459] INFO RPI raspberrypi.cpp:1404 Registered camera /base/soc/i2c0mux/[email protected]/[email protected] to Unicam device /dev/media3 and ISP device /dev/media0
[0:29:03.315622990] [1457] INFO Camera camera.cpp:1035 configuring streams: (0) 1920x1080-YUV420
[0:29:03.316007566] [1459] INFO RPI raspberrypi.cpp:765 Sensor: /base/soc/i2c0mux/[email protected]/[email protected] - Selected sensor format: 1920x1080-SBGGR10_1X10 - Selected unicam format: 1920x1080-pBAA

What does “ERROR: *** failed to start output streaming ***” mean? When I ran it at the highest resolution I got a different error message.

[email protected]:~ $ libcamera-vid -t 0 --width 9152 --height 6944 --framerate 10 -o output1.mkv
Preview window unavailable
[1:12:37.759079216] [1610] INFO Camera camera_manager.cpp:293 libcamera v0.0.0+3897-c3c878a9
[1:12:37.767502194] [1612] WARN CameraSensorProperties camera_sensor_properties.cpp:174 No static properties available for ‘arducam_64mp’
[1:12:37.767546394] [1612] WARN CameraSensorProperties camera_sensor_properties.cpp:176 Please consider updating the camera sensor properties database
[1:12:37.793021663] [1612] WARN RPI raspberrypi.cpp:1280 Mismatch between Unicam and CamHelper for embedded data usage!
[1:12:37.794028965] [1612] ERROR DelayedControls delayed_controls.cpp:87 Delay request for control id 0x009a090a but control is not exposed by device /dev/v4l-subdev0
[1:12:37.794277406] [1612] INFO RPI raspberrypi.cpp:1404 Registered camera /base/soc/i2c0mux/[email protected]/[email protected] to Unicam device /dev/media3 and ISP device /dev/media0
[1:12:37.794976402] [1610] INFO Camera camera.cpp:1035 configuring streams: (0) 9152x6944-YUV420
[1:12:37.795554759] [1612] INFO RPI raspberrypi.cpp:765 Sensor: /base/soc/i2c0mux/[email protected]/[email protected] - Selected sensor format: 9152x6944-SBGGR10_1X10 - Selected unicam format: 9152x6944-pBAA
[1:12:37.987297462] [1612] ERROR V4L2 v4l2_videodevice.cpp:1241 /dev/video14[16:cap]: Not enough buffers provided by V4L2VideoDevice
ERROR: *** failed to allocate capture buffers ***
[email protected]:~ $

I added --mode 4624:3472 and --codec mjpeg options, and then was able to take 3840x2160 video

[email protected]:~ $ libcamera-vid -t 0 --width 3840 --height 2160 --framerate 20 --mode 4624:3472 --codec mjpeg -o output1.mkv
Preview window unavailable
[2:43:31.464044511] [1997] INFO Camera camera_manager.cpp:293 libcamera v0.0.0+3897-c3c878a9
[2:43:31.472304694] [1999] WARN CameraSensorProperties camera_sensor_properties.cpp:174 No static properties available for ‘arducam_64mp’
[2:43:31.472349082] [1999] WARN CameraSensorProperties camera_sensor_properties.cpp:176 Please consider updating the camera sensor properties database
[2:43:31.497069981] [1999] WARN RPI raspberrypi.cpp:1280 Mismatch between Unicam and CamHelper for embedded data usage!
[2:43:31.497965724] [1999] ERROR DelayedControls delayed_controls.cpp:87 Delay request for control id 0x009a090a but control is not exposed by device /dev/v4l-subdev0
[2:43:31.498133795] [1999] INFO RPI raspberrypi.cpp:1404 Registered camera /base/soc/i2c0mux/[email protected]/[email protected] to Unicam device /dev/media3 and ISP device /dev/media0
Stream configuration adjusted
[2:43:31.499100944] [1997] INFO Camera camera.cpp:1035 configuring streams: (0) 3840x2160-YUV420 (1) 4624x3472-SBGGR10_CSI2P
[2:43:31.499540232] [1999] INFO RPI raspberrypi.cpp:765 Sensor: /base/soc/i2c0mux/[email protected]/[email protected] - Selected sensor format: 4624x3472-SBGGR10_1X10 - Selected unicam format: 4624x3472-pBAA