Page 1 of 1

Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 3:59 am
by FrozenNick
Hi all,

I am building a project that needs to capture a fast moving object travelling at a speed of 1.5m/s, the distance from the object and lens is only 4cm. What I found from the camera here http://www.cambridgeincolour.com/tutori ... -speed.htm (using 1/3" sensor size), I need the camera speed approximately in between 1/8000 sec to 1/10000sec if I am using pi camera.

Does pi camera able to achieve that speed? Where do I get the reference from? I tried to search for a whole day and all I get is the longest exposure of 6 seconds, nothing on the fastest shutter speed.

Thanks a lot in advance for answering my question.

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 8:40 am
by 6by9
Minimum automatic exposure time is normally 200us, but 100us if you select the "sport" exposure mode. If manually set the exposure then you should be able to select any multiple of 18.9us (assuming you're taking still captures on a V2 sensor. Other modes will have a different base exposure unit).

HOWEVER, both Pi camera modules are rolling shutter sensors, therefore you will get rolling shutter effects which may make the camera unsuitable for your application.

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 9:10 am
by FrozenNick
6by9 wrote:Minimum automatic exposure time is normally 200us, but 100us if you select the "sport" exposure mode. If manually set the exposure then you should be able to select any multiple of 18.9us (assuming you're taking still captures on a V2 sensor. Other modes will have a different base exposure unit).

HOWEVER, both Pi camera modules are rolling shutter sensors, therefore you will get rolling shutter effects which may make the camera unsuitable for your application.
Thanks a lot for the clarification, just to confirm, there are no documentation stating these data right?

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 9:21 am
by Gavinmc42
http://elinux.org/Rpi_Camera_Module

You can google for data sheets or go Sony webpage.
90 or 120fps is as fast as you can go.
Rolling shutter alway assumed with CMOS image sensor unless they say specifically say global shutter, which is not common.

Look for a USB high speed camera, but that is a real fast camera, expect to pay lots.

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 9:25 am
by 6by9
FrozenNick wrote:Thanks a lot for the clarification, just to confirm, there are no documentation stating these data right?
The fact it is a rolling shutter sensor is documented in lots of places. https://picamera.readthedocs.io/en/late ... -operation also gives a pretty good explanation of the mechanics involved, although the wiki link I gave earlier also does a reasonable job.

The exact exposure times quite probably aren't documented. It's the standard engineering issue of engineers hating to write documentation, but conversely a huge number of users never read it anyway. How many users are actually needing to get down that low anyway? Very few as it generally means you need LOTS of light.
There is a huge amount that could be added under https://www.raspberrypi.org/documentati ... /README.md however waveform80 has done such a good job on the PiCamera library docs that it is easier to refer many users there than duplicate the effort.

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 9:30 am
by FrozenNick
Gavinmc42 wrote:http://elinux.org/Rpi_Camera_Module

You can google for data sheets or go Sony webpage.
90 or 120fps is as fast as you can go.
Rolling shutter alway assumed with CMOS image sensor unless they say specifically say global shutter, which is not common.

Look for a USB high speed camera, but that is a real fast camera, expect to pay lots.
Thanks for the link, helped me a lot! :D
I guess have to research more on rolling/global shutter :shock:

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 9:31 am
by 6by9
Gavinmc42 wrote:Rolling shutter alway assumed with CMOS image sensor unless they say specifically say global shutter, which is not common.
You need to be very careful to differentiate between global shutter and global reset.

Global shutter generally means that there is a full sample and hold arrangement for the whole sensor. That is obviously big and expensive (in silicon terms) so tends to only exist on lower resolution cameras.

Global reset has to be used in combination with an external mechanical shutter or controlled lighting to get sensible results. It's a way of resetting the whole rolling shutter array at the same moment for the start of exposure, but it will still take the normal readout time to capture the data. If you can't stop the pixels exposing with an external shutter then the exposure time increases as you go down the image. IIRC OV5647 does have a global reset but no external shutter, so it is of limited gain.

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 9:33 am
by FrozenNick
6by9 wrote:
FrozenNick wrote:Thanks a lot for the clarification, just to confirm, there are no documentation stating these data right?
The fact it is a rolling shutter sensor is documented in lots of places. https://picamera.readthedocs.io/en/late ... -operation also gives a pretty good explanation of the mechanics involved, although the wiki link I gave earlier also does a reasonable job.

The exact exposure times quite probably aren't documented. It's the standard engineering issue of engineers hating to write documentation, but conversely a huge number of users never read it anyway. How many users are actually needing to get down that low anyway? Very few as it generally means you need LOTS of light.
There is a huge amount that could be added under https://www.raspberrypi.org/documentati ... /README.md however waveform80 has done such a good job on the PiCamera library docs that it is easier to refer many users there than duplicate the effort.
Thanks a lot, sorry for troubling you, you really helped me a lot. Yes, nobody will need to have the shutter speed to go down to 200uS, it's absurd anyways. Thanks again for the help, really appreciate it a lot. ;)

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Apr 18, 2017 10:50 am
by Gavinmc42
Can you use strobes to freeze the motion?
But strobe output from sensor does not come out on the PCB :(

Multiple cameras triggered one after the other? Which would be hard if you are only 40mm away.
A macro lens will be needed.
You can only unscrew the V2 lens and macro focus down to about 100mm before the lens drops out.

May have to look else where
Google found this
https://photron.com/product-category/ca ... cam-minis/

Re: Pi Camera Fastest Shutter Speed

Posted: Thu May 24, 2018 2:25 pm
by anujgpatil
I am working on a similar application and the most viable solution seems to be Arducam's AR0134 Global Shutter Camera.

http://www.arducam.com/camera-modules/g ... er-camera/

Hope this helps!
@anujgpatil

Re: Pi Camera Fastest Shutter Speed

Posted: Thu May 24, 2018 4:22 pm
by HermannSW
Yes, nobody will need to have the shutter speed to go down to 200uS, it's absurd anyways.
I did need it today, and did 250μs before with raspiraw high framerate capturing.
Today I did need to go down to 200μs with raspivid 180fps video of rotating RC aircraft propeller:

Code: Select all

raspivid -md 7 -w 640 -h 480 -p 706,20,640,480 -fps 180 -ss 200 -pts test.200.pts -t 2000 -o test.200.h264
as it generally means you need LOTS of light.
Definitely, with 1000μs shutter time or below even 1000lm lit scene becomes dark. I used 5000lm light again to compensate for very short shutter time. Still not bright, but I can see everything I want. And as 6by9 said, rolling shutter effect can be extreme (the propeller is connected and not disconnected as shown by this frame):
Image

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Feb 26, 2019 11:36 pm
by HermannSW
FrozenNick wrote:
Tue Apr 18, 2017 9:33 am
Yes, nobody will need to have the shutter speed to go down to 200uS, it's absurd anyways.
As 6by9 stated:
If manually set the exposure then you should be able to select any multiple of 18.9us (assuming you're taking still captures on a V2 sensor. Other modes will have a different base exposure unit).
I needed much less than 200µs for capturing closing mouse trap bar:
https://www.raspberrypi.org/forums/view ... 1ea619a9d5

The bar speed short before touch down was 20m/s. With that speed the bar moves

Code: Select all

20m/s * 0.000200s = 0.004m =4mm
But the bar is 1mm thick, and you will get blurry bar frames.

For mode 7 (640xH) you can get exposures in multiples of 19.5µs, I got good frames with factors 1 (19.5µs) and 2 (39µs), and the best with factor 0 (which is not defined in Sony imx219 spec, but works):
Image

The bar only moves

Code: Select all

20m/s * 0.0000195s = 0.00039m = 0.39mm
in 19.5µs, which is 39% of the bar thickness, compared to 400% with 200µs.

Re: Pi Camera Fastest Shutter Speed

Posted: Tue Feb 26, 2019 11:49 pm
by HermannSW
6by9 wrote:
Tue Apr 18, 2017 9:31 am
Global reset has to be used in combination with an external mechanical shutter or controlled lighting to get sensible results. It's a way of resetting the whole rolling shutter array at the same moment for the start of exposure, but it will still take the normal readout time to capture the data. If you can't stop the pixels exposing with an external shutter then the exposure time increases as you go down the image. IIRC OV5647 does have a global reset but no external shutter, so it is of limited gain.
Interesting that v1 camera ov5647 has a global reset, but v2 imx219 does not have it.
ethanol100 described in posting in "capture flying rifle bullet with Raspberry camera" how to make use of global reset of v1 camera with an air spark flash (that has ultra short flash duration of <1µs) to simulate global shutter:
https://www.raspberrypi.org/forums/view ... 9#p1434563

So in this setup the shutter is not needed because the flash only lights for a very short time, and after that further changes in the scene (eg. bullet moving forward) will not do harm because it is dark after the spark.

The global reset of ov5647 is described in section 4.10:
https://cdn.sparkfun.com/datasheets/Dev ... df#page=43
In FREX mode, whole frame pixels start integration at the same time, rather than integrating row by row.
The FREX pin of ov5647 seems not to be exposed, at least not on th CSI-2 bus.
FREX mode 2 helps, in that mode the exposure request is sent via SCCB register 0x3B08 bit 0.

Next step is to enable raspiraw to make use of FREX mode 2 for global reset.