User avatar
rkinch
Posts: 72
Joined: Sun Jun 02, 2013 7:19 am
Location: Palm Beach County, Florida USA
Contact: Website

Stock lens in the camera module 3.6mm f/2.9 [was: 4mm f/3.2]

Tue Jun 04, 2013 6:31 am

After repeating my measurements, I am retracting my original finding of f=4mm for the lens, and agreeing with the f=3.6mm f/2.9 finding that others have made. This is based on a new field measurement of 194.5 inches wide at 195 inches distance, and 38.5 inches wide at 38 inches. Repeating the calculations with these numbers yields f=3.6mm. My original pupil size measurement of 1.25mm is confirmed as correct, so with the focal length this yields f/2.9. I apologize for the error and thank all of those who reported their own measurements.

Here is my original report:
rkinch wrote:This is my analysis proving the 4mm focal length of the stock lens in the camera module based on my physical measurements and the Omivision OV5647 specs.

Shooting a full-resolution still (2592 x 1944 pixels) displays a field of view about 34.75 inches wide at 38 inches.

By optical principles, this corresponds to a 2*atan(0.5*34.75/38) = 49 degrees horizontal field of view. Likewise the vertical field of view is 37 degrees, and the diagonal 61 degrees.

The sensor chip is 3.674mm wide. Proportioning this by 38/34.75 = 4mm yields the lens focal length.

Comparing to a 35mm film camera (36mm x 24mm frame), the relative sensor size is 36mm/3.674mm = 9.8x, or 10x as an approximate rule of thumb. So the Raspberry Pi camera module with its 4mm lens acts like a 35mm camera with a 40mm lens, in terms of field of view. Depth of field is likewise scaled 10x. The aspect ratios also differ, namely 4:3 (Raspberry Pi) versus 3:2 (35mm film).

For the 1080p video frame, the system uses the center 1920 x 1080 pixel crop, and the field of view is proportionately different from the full frame. The 1920 pixel width corresponds to 2.721mm on the sensor. This cropping is 2952/1920 = 1.35x horizontally and 1944/1080 = 1.8x vertically from the full frame. A sample image shows a field of view 76 inches wide at 112 inches distance. Proportioning 112/76*2.721mm = 4mm focal length, as expected. HD 1080p field of view is 37 degrees horizontally, 21 degrees vertically, and 43 degrees diagonally.

The 35mm lens equivalent for the 1080p video mode would be 36mm/2.721mm*4mm = 53mm.

My microscopic examination of the lens entrance pupil shows it to be about 1.25mm diameter, so the f/number of this 4mm lens is 4mm/1.25mm = f/3.2.
For more details, see http://www.truetex.com/raspberrypi
Last edited by rkinch on Fri Jun 07, 2013 5:10 am, edited 1 time in total.

dan3008
Posts: 1172
Joined: Wed Aug 15, 2012 1:05 pm

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 9:06 am

Well, I never thought i'd see someone out talk my understanding of cameras when referring to the camera board for the pi.

You've actually taught me something there, and i'm going to go use the same basic technique to see if my lens's for my SLR tell the truth about there focal length, and max/min aperture.

well done, I'm impressed
dan3008 wrote:Pays your money, takes your choice

towolf
Posts: 421
Joined: Fri Jan 18, 2013 2:11 pm

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 11:00 am

How confident are you about the aperture F-number of 3.2? Another user here had estimated f/2. I was looking into the exposure parameters the auto exposure is using and the aperture was an unknown there.

User avatar
pluggy
Posts: 3635
Joined: Thu May 31, 2012 3:52 pm
Location: Barnoldswick, Lancashire,UK
Contact: Website

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 3:14 pm

Does the effective aperture matter if the depth of field is all to pot in comparison to old world photographic standards and I'm guessing the effective film speed is something of an unknown ?. You'd need a very small aperture on a 40mm focal length 35mm frame lens to get anywhere near the depth of field the Pi camera has (presumably f22 - f32).
Don't judge Linux by the Pi.......
I must not tread on too many sacred cows......

towolf
Posts: 421
Joined: Fri Jan 18, 2013 2:11 pm

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 4:58 pm

Ev = Av + Tv = Sv + Bv

We have Tv, Sv, and Bv. Av is what is missing.

Since Av is unset in the camera firmware, the exposure related values in the EXIF data are incorrect. I have a hunch that setting the aperture in some variable in the firmware will make EXIF correct and replicable with conventional exposure calculations.

This has nothing to do with depth of field.

User avatar
rkinch
Posts: 72
Joined: Sun Jun 02, 2013 7:19 am
Location: Palm Beach County, Florida USA
Contact: Website

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 6:03 pm

towolf wrote:How confident are you about the aperture F-number of 3.2? Another user here had estimated f/2.
Just look at the entrance to the lens. If it were f/2 then the pupil would have to be 2mm diameter. It is obviously much smaller than that. I measure 1.25mm using a 10x reticle.

sharix
Posts: 200
Joined: Thu Feb 16, 2012 11:29 am
Location: Slovenia

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 7:39 pm

towolf wrote:Ev = Av + Tv = Sv + Bv

We have Tv, Sv, and Bv. Av is what is missing.

Since Av is unset in the camera firmware, the exposure related values in the EXIF data are incorrect. I have a hunch that setting the aperture in some variable in the firmware will make EXIF correct and replicable with conventional exposure calculations.

This has nothing to do with depth of field.
According to the equation, if you have Tv, Sv, and Bv you can calculate Av and Ev.

fastmapper
Posts: 27
Joined: Wed Mar 27, 2013 3:54 am

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 10:47 pm

rkinch wrote:Shooting a full-resolution still (2592 x 1944 pixels) displays a field of view about 34.75 inches wide at 38 inches.
How accurate do you believe your measurements were? I measured 48.8+/-0.1 inches horizontal cross range at 48.4+/-0.3 inches range. I also measured at 5 additional ranges up to 168.1 inches with similar results. The significant differences in our measurements suggest the possibility of different stock lenses.
rkinch wrote:The sensor chip is 3.674mm wide.
The Omnivision OV5647 product brief (see http://www.ovt.com/download_document.ph ... partid=171) does indicate that the horizontal image size is 3673.6 microns, but I believe this is for 2624 pixels at 1.4 microns each. The image you evaluated was only 2592 pixels at 1.4 microns per pixel or 3.6288mm. It is common practice for image sensors to have more active pixels than the largest standard size requires.

Since f-stop is dependent on focal length, any error in focal length will also be included in f-stop estimation.

My measurements suggested a focal length of 3.60+/-0.01mm.

towolf
Posts: 421
Joined: Fri Jan 18, 2013 2:11 pm

Re: Stock lens in the camera module shown to be 4mm f/3.2

Tue Jun 04, 2013 10:55 pm

sharix wrote:
towolf wrote:Ev = Av + Tv = Sv + Bv

We have Tv, Sv, and Bv. Av is what is missing.

Since Av is unset in the camera firmware, the exposure related values in the EXIF data are incorrect. I have a hunch that setting the aperture in some variable in the firmware will make EXIF correct and replicable with conventional exposure calculations.

This has nothing to do with depth of field.
According to the equation, if you have Tv, Sv, and Bv you can calculate Av and Ev.
Yes I didn’t give the full story. Bv is wrong, so it doesn’t add up.

User avatar
rkinch
Posts: 72
Joined: Sun Jun 02, 2013 7:19 am
Location: Palm Beach County, Florida USA
Contact: Website

Re: Stock lens in the camera module shown to be 4mm f/3.2

Wed Jun 05, 2013 6:39 am

fastmapper wrote:How accurate do you believe your measurements were?
Plus or minus a few percent. Not enough to account for 3.6mm vs 4.0mm focal length result. My vertical vs horizontal measurements differed by only 1.2 percent which was my check.

Indeed I erred as you suggest in counting dark pixels (extra 32 columns and 12 rows) so my sensor sizes were about 1 percent too large. But when I recalculate with the correct sizes, I actually get *closer* to an f=4.0mm result.
fastmapper wrote:My measurements suggested a focal length of 3.60+/-0.01mm.
And I believe you also found f/2, which would imply a 3.6mm/2 = 1.8mm pupil. I see a 1.25mm pupil. This should be a rather obvious difference available in a simple direct examination. So if you can have another look and confirm that you have a 1.8mm pupil (or anything much bigger than 1.25mm), then this would be direct evidence that we have different lenses.

towolf
Posts: 421
Joined: Fri Jan 18, 2013 2:11 pm

Re: Stock lens in the camera module shown to be 4mm f/3.2

Wed Jun 05, 2013 8:28 pm

The microscope I had access to today was too flimsy to make super-consistent measurements (i.e., switching from scale to object), but it largely confirms the 1.25mm+ pupil size

Image

JohnDennis
Posts: 3
Joined: Tue Oct 27, 2015 1:10 am

Re: Stock lens in the camera module 3.6mm f/2.9 [was: 4mm f/

Sat Oct 31, 2015 1:49 am

If the video uses a cropped portion of the sensor, wouldn't the angle of view be more narrow for video than stills? You estimated that the 35mm equivalent for stills was 45mm and 35mm for video

Return to “Camera board”