arafatbhossain
Posts: 1
Joined: Wed Feb 08, 2023 3:19 am

Compatibility of DSLR with Raspberry Pi

Wed Feb 08, 2023 3:49 am

Hello everyone, we have a specific use case for DSLR and Raspberry Pi. Here are the set of actions we are now doing manually-
1. A DSLR is attached on a small mount
2. We use manual autofocus to make the DSLR focus on a particular portion of a small object. The mode of DSLR is manual.
3. As soon as we get the desired autofocus, we take the picture.

The autofocus part is the most challenging part here. We are thinking of interfacing the DSLR with Raspberry Pi and write a program that will make the DSLR autofocus on the desired position programmatically and take the picture and return the picture of raspberry pi for processing. Our three specific queries are-
- Is that something doable? If so, then how? A brief description on the methodology would be highly appreciated.
- What kind of DSLR camera should we look for that would enable us to achieve this level of programmability?
- The most challenging and main question, how do we programmatically bring back the captured image from DSLR to Raspberry Pi?

Would really appreciate if we could get some guidance.

Thanks in advance.

memjr
Posts: 2775
Joined: Fri Aug 21, 2020 5:59 pm

Re: Compatibility of DSLR with Raspberry Pi

Wed Feb 08, 2023 4:32 am

arafatbhossain wrote:
Wed Feb 08, 2023 3:49 am
- Is that something doable? If so, then how? A brief description on the methodology would be highly appreciated.
Yes it is, but the how is a function of the DSLR and software available to work with it and whether said software can be installed in the Pi. Canon for example does not provide drivers for the printer that work in a Pi, and canon printers are very common compared to DSLR owners who want to use a pi for their photography needs. In other words, should pick a canon DSLR, you will not be able to install canon software and drivers in the pi.
arafatbhossain wrote:
Wed Feb 08, 2023 3:49 am
- What kind of DSLR camera should we look for that would enable us to achieve this level of programmability?
That is a wrong question and suggests you need to reevaluate your approach to this project. The camera needs to be selected by your technical photographic needs first, followed by budget, because more often than not, the amount of money you have for the camera is going to dictate the technical capabilities you need to compromise in your final camera selection. Your ability to use software in a computer system or another will also influence this. If you MUST use a camera to has drivers for the pi, be prepared to be severily limited to the number of DSLRs you can choose from. You may even end up needing a camera that you will not be able to use with a Pi.
arafatbhossain wrote:
Wed Feb 08, 2023 3:49 am
- The most challenging and main question, how do we programmatically bring back the captured image from DSLR to Raspberry Pi?.
Again, you should already know how this needs to be done, and it will also be dictated on your choice of camera. Once you know that, you'll know what software is available for it and regardless of you using a pi, a Mac, or PC, the workflow and software will be the same. You may come here to ask for help getting it done withing the intricacies and bounds of the Pi, but we cannot determine what you need, you need to give us thenwhatmyou need and wemcsn try to give you a few options on how itmcan be done in the Pi, rather than done as whole.

So, go back and

- determine what kind of imaging and quality you MUST have.
- determine budget
- choose DSLR that meets your bate minimum requirements within your budget
- determine what computer architecture you your camera can work with (Canon may not provide drivers for the Pi, but a 3rd party may provide one)
- determine the language needed to code software, you may only know python, but may need to C instead because the camera only has drivers that can be used in C
- determine your needed workflow
- code the software tomaccomplish your goal.
Last edited by memjr on Wed Feb 08, 2023 4:24 pm, edited 1 time in total.

AndrewPiEater
Posts: 191
Joined: Wed Jul 16, 2014 4:45 pm

Re: Compatibility of DSLR with Raspberry Pi

Wed Feb 08, 2023 6:43 am

Software like gphoto2 (there are others) can control cameras over USB from a Pi. Here is an example project description :

https://pimylifeup.com/raspberry-pi-ds ... a-control/

It works with 100s of popular cameras.

There are numerous examples on the web of projects where people do something similar to your requirements.

User avatar
B.Goode
Posts: 14738
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: Compatibility of DSLR with Raspberry Pi

Wed Feb 08, 2023 10:00 am

Although it is the premise behind your question, maybe you don't actually need the DSLR Camera?

Perhaps an official Raspberry Pi Camera Module 3 with an appropriate lens will accomplish all you require? https://www.raspberrypi.com/products/camera-module-3/




I'm confused by this part of your specification:
We use manual autofocus to make the DSLR focus on a particular portion of a small object. The mode of DSLR is manual.
'Manual' or 'autofocus' I understand. What is meant by "We use manual autofocus"?


{Edit: typo - manual}
Last edited by B.Goode on Wed Feb 08, 2023 10:29 am, edited 1 time in total.

Heater
Posts: 19321
Joined: Tue Jul 17, 2012 3:02 pm

Re: Compatibility of DSLR with Raspberry Pi

Wed Feb 08, 2023 10:24 am

"manual autofocus" sounded like a self contradiction to me as well. But I guess it means that rather than have the camera fully automatically select a focus on whatever scene it is looking at you tell it to specifically to focus on some manually selected feature of the scene.

For example, if the camera is looking at a face it may automatically select a focus that is best for clarity of the entire face. But you may want to specifically focus on the persons ear which may not be optimal for the rest of the face.
Slava Ukrayini.

memjr
Posts: 2775
Joined: Fri Aug 21, 2020 5:59 pm

Re: Compatibility of DSLR with Raspberry Pi

Wed Feb 08, 2023 4:24 pm

From the description, what I got from "manual autofocus" is they will manually set the lens to focus in a spot, then use the computer to refocus as needed.

This is probably a macro stacking setup, and if not macro photography, the same focusing scheme.

Return to “Graphics, sound and multimedia”