Cannot build Arducam .dto and .ko files - bug report attached

Hi, I’ve got a 16MP IMX519 camera on a Raspberry Pi 5 and I can’t get it to focus at all. It’s never worked properly since I got it. I mainly want to sort out the focus, but I’d also like to be able to set exposure and the other camera properties. Any idea where I should start?

Thanks for the details. To start diagnosing the focus issue on the IMX519 with a Pi 5, could you share a couple of photos of the hardware connection — one at the Raspberry Pi end and one at the camera end?

Also, please generate a camera bug report so we can see the current state of the system. After rebooting, run:

wget -O arducam-camera-bug-report https://github.com/Dion4cen/arducam-camera-bug-report/releases/download/Tool/arducam-camera-bug-report
chmod +x ./arducam-camera-bug-report
./arducam-camera-bug-report

That will create an arducam-bug-report.txt file in the current directory. Attach it here and I’ll take a look.

Here’s the first bug report:
https://cdn.arducam.com/forum/85e25deec412ec28823a24e89d5a7d17/arducam-bug-report.txt

I also tried building arducam.dto and .ko myself but couldn’t get them to build. Not sure if that’s related to the focus problem or a separate issue.

Thanks, I’ve got the report and I’m going through it now. If anything else stands out on your end, feel free to add it while I review.

I ran the tool again, this time with “arducam” selected in config.txt instead of imx519. Here’s the second report:
https://cdn.arducam.com/forum/c7dfc2efe8f993e8f1325b95f1ec6bc8/arducam-bug-report_with_arducam.txt

Still can’t get the camera working on the Pi Zero or the Pi 5.

Got the second one, thanks. You mentioned trying to build the driver earlier — when you run the bash file to build arducam.ko, what exactly happens? Do you get any error output, or does it just finish with nothing?

I downloaded the bash file and tried to build arducam.ko from it, but nothing gets generated — there’s no output at all. I also noticed the OS versions listed in the txt file don’t include my OS, which is in the 16.x range.

Thanks for the extra detail. Where are you at with libcamera and the camera apps now, and is autofocus behaving any differently after the build attempts?

I’ve made some progress — I can now build libcamera and the apps. But autofocus still isn’t working. At this point I’m starting to suspect the camera mechanism itself is physically damaged. Is there any way to check whether the hardware is damaged?

Also, as a side note, the build instructions should probably make sure the necessary header files etc. are installed first. That tripped me up for a while.

Good to hear the libcamera build is working now. To narrow down the autofocus issue, can you run:

libcamera-still -t 0

and paste the output here? That will show whether the module is being accessed properly and what the camera reports back. I’ve also noted your point about installing the required header files first in the instructions.