New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

6 second exposures! #135

Closed
waveform80 opened this Issue Jul 29, 2014 · 7 comments

Comments

Projects
None yet
2 participants
@waveform80
Owner

waveform80 commented Jul 29, 2014

According to this forum thread there's a new mode to allow particularly long exposures. This should be added for 1.7.

@waveform80 waveform80 added this to the 1.7 milestone Jul 29, 2014

@waveform80 waveform80 self-assigned this Jul 29, 2014

@waveform80

This comment has been minimized.

Show comment
Hide comment
@waveform80

waveform80 Aug 2, 2014

Owner

I'm not sure I actually need to do anything with this. Just tested with firmware revision 700 and without fiddling with FPS_RANGE at all I could set framerate to 1/6fps and bump shutter speed up to 6s. The Exif in the resulting JPEG seemed to confirm that a 6s exposure was used. Curiously, querying FPS_RANGE from all the camera's output ports returns a low value of 0.004fps (256/65536) and a high of 30fps (1966080/65536), even when the camera's been switched into one of the high framerate modes, so I'm not convinced it's really operational (or actually doing much).

Here's a script which should produce a 6 second exposure:

import picamera
from fractions import Fraction

with picamera.PiCamera() as camera:
    camera.resolution = (1280, 720)
    camera.framerate = Fraction(1, 6)
    camera.shutter_speed = 6000000
    camera.exposure_mode = 'off'
    # This will take more than 6 seconds (due to mode switches etc.)
    camera.capture('foo.jpg')
    print camera.shutter_speed
    print camera.exposure_speed

Seems to work happily with video port captures and recording too.

Owner

waveform80 commented Aug 2, 2014

I'm not sure I actually need to do anything with this. Just tested with firmware revision 700 and without fiddling with FPS_RANGE at all I could set framerate to 1/6fps and bump shutter speed up to 6s. The Exif in the resulting JPEG seemed to confirm that a 6s exposure was used. Curiously, querying FPS_RANGE from all the camera's output ports returns a low value of 0.004fps (256/65536) and a high of 30fps (1966080/65536), even when the camera's been switched into one of the high framerate modes, so I'm not convinced it's really operational (or actually doing much).

Here's a script which should produce a 6 second exposure:

import picamera
from fractions import Fraction

with picamera.PiCamera() as camera:
    camera.resolution = (1280, 720)
    camera.framerate = Fraction(1, 6)
    camera.shutter_speed = 6000000
    camera.exposure_mode = 'off'
    # This will take more than 6 seconds (due to mode switches etc.)
    camera.capture('foo.jpg')
    print camera.shutter_speed
    print camera.exposure_speed

Seems to work happily with video port captures and recording too.

@waveform80

This comment has been minimized.

Show comment
Hide comment
@waveform80

waveform80 Aug 2, 2014

Owner

Added some recipes for this in 7ea6fb4 - I'll close the ticket for now

Owner

waveform80 commented Aug 2, 2014

Added some recipes for this in 7ea6fb4 - I'll close the ticket for now

@waveform80 waveform80 closed this Aug 2, 2014

@ethanol100

This comment has been minimized.

Show comment
Hide comment
@ethanol100

ethanol100 commented Sep 2, 2014

Exposure time seems to be still limited to 1s?
http://www.raspberrypi.org/forums/viewtopic.php?f=43&t=85856

@waveform80

This comment has been minimized.

Show comment
Hide comment
@waveform80

waveform80 Sep 2, 2014

Owner

Hmm, must admit my conclusion it was working was based solely off the exif data (i.e. I checked the exposure speed read 6s in the output) - unfortunately I lack the time for comprehensive testing of these things. Still, definitely looks like there's an issue. I'll re-open this for 1.8.

Owner

waveform80 commented Sep 2, 2014

Hmm, must admit my conclusion it was working was based solely off the exif data (i.e. I checked the exposure speed read 6s in the output) - unfortunately I lack the time for comprehensive testing of these things. Still, definitely looks like there's an issue. I'll re-open this for 1.8.

@waveform80 waveform80 reopened this Sep 2, 2014

@waveform80 waveform80 modified the milestones: 1.8, 1.7 Sep 2, 2014

@waveform80 waveform80 closed this in 7fca7fa Sep 4, 2014

@waveform80

This comment has been minimized.

Show comment
Hide comment
@waveform80

waveform80 Sep 4, 2014

Owner

I think this is fixed now; must admit I can't really tell as I don't have any analog clocks or other gizmos to hand which move in a regular fashion. Still, the picamera code is now doing more or less the same thing as the raspistill code (it's slightly different in that picamera sets FPS_RANGE in response to setting framerate rather than shutter-speed, but given framerate clamps shutter-speed that shouldn't make any difference - i.e. the underlying sequence of MMAL calls will remain equivalent).

Owner

waveform80 commented Sep 4, 2014

I think this is fixed now; must admit I can't really tell as I don't have any analog clocks or other gizmos to hand which move in a regular fashion. Still, the picamera code is now doing more or less the same thing as the raspistill code (it's slightly different in that picamera sets FPS_RANGE in response to setting framerate rather than shutter-speed, but given framerate clamps shutter-speed that shouldn't make any difference - i.e. the underlying sequence of MMAL calls will remain equivalent).

@ethanol100

This comment has been minimized.

Show comment
Hide comment
@ethanol100

ethanol100 Sep 4, 2014

Thanks! Can confirm that 6s shutterspeed are working now. I have checked it with an analog clock.

ethanol100 commented Sep 4, 2014

Thanks! Can confirm that 6s shutterspeed are working now. I have checked it with an analog clock.

@waveform80

This comment has been minimized.

Show comment
Hide comment
@waveform80

waveform80 Sep 4, 2014

Owner

@ethanol100 Excellent! Thanks for testing that - I was half considering a trip to the local junk shop to try and find an old kitchen timer or something similar! I've run the test suite over night and it looks like there's a few bits of breakage to fix up, but nothing major so we're on course for a release sometime tomorrow I think.

Owner

waveform80 commented Sep 4, 2014

@ethanol100 Excellent! Thanks for testing that - I was half considering a trip to the local junk shop to try and find an old kitchen timer or something similar! I've run the test suite over night and it looks like there's a few bits of breakage to fix up, but nothing major so we're on course for a release sometime tomorrow I think.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment