Point Grey Research Knowledge Base

Article 99 - Imaging Products timestamping and different timestamp mechanisms.

Issue:
Imaging Products timestamping and different timestamp mechanisms.

Solution:

With the FlyCapture SDK, users have access to the following different timestamps:

 

  • PC system clock - This timestamp is generated from the PC's clock; captured images are timestamped once the last image packet arrives at the PC. This gives a rough time estimate and is generally not recommended for precision purposes. In the FlyCapture 1.x interface, this timestamp can be accessed through the FlyCaptureTimeStamp.ulSeconds and FlyCaptureTimeStamp.ulMicroSeconds members of the FlyCaptureImage structure. Using FlyCapture 2.x, reference the seconds and microseconds attributes of the TimeStamp structure, where seconds is UNIX time in seconds. For more information on these structures, consult the FlyCapture SDK Help.


  • 1394 cycle time - This timestamp is based on the 1394 cycle timer (which increments at 8kHz); captured images are timestamped at the time that the shutter was closed . In the FlyCapture 1.x interface, this timestamp can be accessed through the FlyCaptureTimeStamp.ulCycleSeconds and FlyCaptureTimeStamp.ulCycleCount members of the FlyCaptureImage structure. Using FlyCapture 2.x, reference the cycleSeconds and cycleCount attributes of the TimeStamp structure. For more information on these structures, consult the FlyCapture SDK Help.


  • Embedded image timestamp - This timestamp takes the 1394 cycle timer at the time that the shutter was closed and embeds the information in the image pixels. This is the most accurate of the timestamps. In order to access this, you need to set the appropriate bit of the FRAME_INFO register 12F8h or use flycaptureSetImageTimestamping() (PGR FlyCapture v1.5.x.x only), and then use a function to read the first 4 bytes of the image (the timestamp is located in the first 4 pixels of the image). For an example of how this is done in the FlyCapture interface, refer to the MultipleCameraEx sample program. For a FlyCapture 1.x example of how to manually parse the image data to retrieve this timestamp, download this sample program

The camera firmware is designed to grab at selected intervals of the 1394 cycle time. To compare any of these timestamps with the absolute cycle time information on the 1394 bus, query CYCLE_TIME register FF100200h.

Related Articles:
1.) Avoiding dropped or missed images using PGR FlyCapture.
2.) How does image data get from a PGR IEEE-1394 digital camera to the user?
3.) Embedding frame-specific data into the first N pixels of an image.


Article ID:
99
Published:
12:00:00 AM
Last Modified:
6/13/2012 12:37:02 PM
Keywords:
timestamp, image timestamp, synchronize, sync, synchronization, synchronized, FRAME_INFO, 12F8h, FRAME_TIMESTAMP
Issue Type:
Normal Use

Copyright © 2004 Point Grey Research Inc.