Public Member Functions

FCam::N900::Flash Class Reference

The LED flash on the Nokia N900. More...

#include <Flash.h>

Inheritance diagram for FCam::N900::Flash:
Inheritance graph
[legend]
Collaboration diagram for FCam::N900::Flash:
Collaboration graph
[legend]

List of all members.

Public Member Functions

int minDuration ()
 The flash on the N900 must fire for a multiple of 54.6 ms plus one millisecond (go figure).
int maxDuration ()
 The flash on the N900 can fire for up to 492.4ms.
float minBrightness ()
 The flash on the N900 has a minimum brightness setting of 2.0, using platform-specific units.
float maxBrightness ()
 The flash on the N900 has a maximum brightness settings of 19.0, using platform-specific units.
void fire (float brightness, int duration)
 Fire the flash with a given brightness for a given number of microseconds.
int fireLatency ()
 The N900's flash will begin to emit light about 3.45 ms after N900::Flash::fire is called, plus or minus about 100 microseconds.
float getBrightness (Time)
 Return the brightness of the flash at a specific time.
void tagFrame (FCam::Frame)
 Tag a frame with the state of the flash during that frame.

Detailed Description

The LED flash on the Nokia N900.

It is fairly weak, and can only fire for very specific amounts of time (multiples of 54.6ms + 1ms). The N900 has a rolling shutter sensor, so you will typically want to fire it at the start of the exposure and keep it illuminated for the entire exposure time plus the sensor's rolling shutter time (N900::Sensor::rollingShutterTime) - otherwise you will see different scanlines illuminated by different amounts. On the up-side, It has next to no recharge time so you can fire it as often as you want, even within a single exposure.

Definition at line 27 of file Flash.h.


Member Function Documentation

int FCam::N900::Flash::maxDuration (  )  [inline, virtual]

The flash on the N900 can fire for up to 492.4ms.

Implements FCam::Flash.

Definition at line 37 of file Flash.h.

float FCam::N900::Flash::minBrightness (  )  [inline, virtual]

The flash on the N900 has a minimum brightness setting of 2.0, using platform-specific units.

Todo:
Check that this is true - the flash seems to fire with constant brightness no matter the brightness setting.
Todo:
Calibrate the flash so we can switch to better units like peak lumens.

Implements FCam::Flash.

Definition at line 48 of file Flash.h.

float FCam::N900::Flash::maxBrightness (  )  [inline, virtual]

The flash on the N900 has a maximum brightness settings of 19.0, using platform-specific units.

Implements FCam::Flash.

Definition at line 52 of file Flash.h.

void FCam::N900::Flash::fire ( float  brightness,
int  duration 
) [virtual]

Fire the flash with a given brightness for a given number of microseconds.

Implements FCam::Flash.

Definition at line 52 of file Flash.cpp.

int FCam::N900::Flash::fireLatency (  )  [inline, virtual]

The N900's flash will begin to emit light about 3.45 ms after N900::Flash::fire is called, plus or minus about 100 microseconds.

Implements FCam::Flash.

Definition at line 62 of file Flash.h.

float FCam::N900::Flash::getBrightness ( Time  t  )  [virtual]

Return the brightness of the flash at a specific time.

The N900's flash has very little ramp-up and ramp-down time, so this will either return the requested brightness or zero.

Implements FCam::Flash.

Definition at line 159 of file Flash.cpp.

void FCam::N900::Flash::tagFrame ( FCam::Frame  f  )  [virtual]

Tag a frame with the state of the flash during that frame.

Implements FCam::Flash.

Definition at line 78 of file Flash.cpp.


The documentation for this class was generated from the following files: