Hi, hoping someone can help. I’ve got an IMX519 16MP camera (the standard one, B0371) running on a Raspberry Pi 4. It sort of works but it’s really unstable — sometimes it captures, sometimes nothing. I can’t get a 16MP image out with autofocus at all. The install/debug instructions I keep finding contradict each other: one place says install the Slow driver, another says install the IMX519 driver, and I can’t tell which one I’m supposed to use. On top of that I don’t see anything about the camera in dmesg, which makes me think it isn’t even being detected properly. Am I doing something obviously wrong?
Welcome! Let’s clear up the driver confusion first, since that’s the most common mixup with these.\n\n- The standard IMX519 camera (B0371 — the one you have) uses the driver from the Raspberry Pi libcamera guide: https://www.arducam.com/docs/cameras-for-raspberry-pi/raspberry-pi-libcamera-guide/\n- The ‘low-speed’ driver is only for the special IMX519 variants, like the mini IMX519, Sync Quad IMX519, etc. It is NOT for the standard B0371. If a low-speed driver gets installed on a standard camera you can get exactly the flaky, intermittent behavior you’re describing.\n\nAlso, autofocus on this camera is driven through libcamera command-line options — you don’t need a separate focus script or the low-speed driver for it:\n\nlibcamera-still -t 0 --autofocus (one-shot autofocus)\nlibcamera-still -t 0 --continue-autofocus (continuous autofocus)\n\nStart by following the libcamera guide exactly for a standard B0371 and let me know how it goes.
Thanks, but the guide’s install instructions are incomplete. Step 5 ‘Install the focus adjustment software’ literally just clones a repo, there are no actual install steps after it. This is all it says:\n\n\nStep 5. Install the focus adjustment software\ngit clone https://github.com/ArduCAM/Arducam-Pivariety-V4L2-Driver.git\n\n\nAnd separately, my pictures come out 2700x1700, not 16MP. So something is still off here.
Good catches — let me break both of those down.\n\nOn the git clone step: that ‘focus adjustment software’ is only for manual focus adjustment. The wording is genuinely bad — cloning the repo doesn’t install anything, and it is not what you use for autofocus. For autofocus you just add --autofocus after the libcamera command, e.g. libcamera-still -t 0 --autofocus. I agree the doc is misleading and I’ll flag it to be improved.\n\nOn the 2700x1700 image: the output size depends on the command and the resolution you pass, so it doesn’t necessarily reflect the full capability of the sensor. Which exact command did you run to capture that image? If you tell me the command I can show you how to get the full resolution out of it.
OK, update after rebuilding the OS and following the link again. First attempt the camera wasn’t even found, and when I tried the autofocus option it told me the parameter is not found. I really need autofocus working — if I can’t get a decent 16MP autofocus picture then this won’t work for my project.\n\nAfter rebuilding a second time the camera at least shows up now, but autofocus still doesn’t work and the link looks deprecated. Here’s exactly what I’m running and what I get.\n\nCommands:\n\npi@raspberrypi-16MP:~ $ libcamera-still -t 5000 -o test.jpg\npi@raspberrypi-16MP:~ $ libcamera-still -t 5000 -o test.jpg -autofocus\n\n\nLog:\n\nPreview window unavailable\n[0:10:21.752157625] [2338] INFO Camera camera_manager.cpp:293 libcamera v0.0.0+3572-e13ccdd5\n[0:10:21.775280596] [2340] WARN CameraSensorProperties camera_sensor_properties.cpp:163 No static properties available for 'imx519'\n[0:10:21.775410931] [2340] WARN CameraSensorProperties camera_sensor_properties.cpp:165 Please consider updating the camera sensor properties database\n[0:10:21.776136679] [2340] ERROR CameraSensor camera_sensor.cpp:591 'imx519 10-001a': Camera sensor does not support test pattern modes.\n[0:10:21.802343495] [2340] WARN RPI raspberrypi.cpp:1263 Mismatch between Unicam and CamHelper for embedded data usage!\n[0:10:21.802941538] [2340] ERROR DelayedControls delayed_controls.cpp:87 Delay request for control id 0x009a090a but control is not exposed by device /dev/v4l-subdev0\n[0:10:21.803279320] [2340] INFO RPI raspberrypi.cpp:1386 Registered camera /base/soc/i2c0mux/i2c@1/imx519@1a to Unicam device /dev/media3 and ISP device /dev/media0\n[0:10:21.803915826] [2338] INFO Camera camera.cpp:1029 configuring streams: (0) 2328x1748-YUV420\n[0:10:21.804334404] [2340] INFO RPI raspberrypi.cpp:764 Sensor: /base/soc/i2c0mux/i2c@1/imx519@1a - Selected sensor format: 2328x1748-SRGGB10_1X10 - Selected unicam format: 2328x1748-pRAA\n[0:10:27.063367109] [2338] INFO Camera camera.cpp:1029 configuring streams: (0) 4656x3496-YUV420 (1) 4656x3496-SRGGB10_CSI2P\n[0:10:27.064900254] [2340] INFO RPI raspberrypi.cpp:764 Sensor: /base/soc/i2c0mux/i2c@1/imx519@1a - Selected sensor format: 4656x3496-SRGGB10_1X10 - Selected unicam format: 4656x3496-pRAA\nStill capture image received\n\n\nThe run without autofocus gives me a 4000x3000-ish image (not sure it’s really full 16MP, it looks small), and the autofocus run fails with:\n\nAutofocus does not work.\nERROR: *** unrecognised option '-autofocus' ***\n\n\nWhat I want is at least an 8-bit 16MP image with autofocus working. What are the correct autofocus commands?
Got it — and I can see both problems in what you posted.\n\n1. The autofocus failure is a typo. Look closely at your command: you ran -autofocus with a single dash. That’s why you get ERROR: *** unrecognised option ‘-autofocus’ . You need a double dash: --autofocus.\n\n2. The ‘small’ image is a resolution issue, not a hardware limit.* Your own log shows the sensor being set up at full size:\n\nconfiguring streams: (0) 4656x3496-YUV420 (1) 4656x3496-SRGGB10_CSI2P\nSensor: /base/soc/i2c0mux/i2c@1/imx519@1a - Selected sensor format: 4656x3496-SRGGB10_1X10\n\n4656x3496 is the full 16MP. If you don’t specify the size you get whatever mode the default pipeline picks.\n\nTry these:\n\nlibcamera-still --list-cameras\nlibcamera-still -t 5000 -o test.jpg --width 4656 --height 3496\nlibcamera-still -t 5000 -o test.jpg --width 4656 --height 3496 --autofocus\n\n\nNote again: --autofocus (double dash), not -autofocus (single dash).\n\nThe warnings in your log (No static properties available for ‘imx519’, the test pattern modes error, the Unicam/CamHelper mismatch, and the delayed controls error on 0x009a090a) are harmless here and don’t stop the capture. I’ve attached before/after autofocus shots so you can see what the effect should look like. Give the double-dash version a go.
Wow — I can’t believe I missed that. Single dash vs double dash, complete novice mistake on my part. The camera is working now: --autofocus does its thing and the full 4656x3496 picture looks very good. Next I’m going to drive it from Python and see if I can capture and process images that way. Thanks a lot for the help!
Glad that’s sorted! Recap for anyone finding this thread later:\n\n- The standard IMX519 (B0371) uses the driver from the Raspberry Pi libcamera guide. The low-speed driver is only for special IMX519 models (mini IMX519, Sync Quad IMX519, etc.) — don’t install it on a standard B0371.\n- Autofocus needs no extra driver or focus script. Just add --autofocus (double dash) to the libcamera command. Using -autofocus (single dash) fails with ‘unrecognised option’.\n- Full resolution is 4656x3496 (16MP). If your image looks small, it’s the command/resolution, not the camera — use --width 4656 --height 3496.\n- The ‘Install the focus adjustment software’ step only clones the repo and is for manual focus only; the wording is misleading and will be improved.\n\nHave fun with the Python side of it — come back if anything else comes up.