NI-IMAQ Status Signals

NI IMAQ

NI-IMAQ Status Signals

NI-IMAQ contains several status signals that you can use to trigger the generation of a pulse or invoke a callback function. Acquisition in Progress (AQ_IN_PROGRESS) indicates that the device is acquiring image data. This signal becomes TRUE when the device initiates the acquisition either through a software or hardware triggered start. When the last piece of image data is transferred to memory, this signal becomes FALSE. If the acquisition is a sequence, acquisition in progress stays TRUE throughout the acquisition until the entire sequence is completed. Acquisition Done (AQ_DONE) is the inverse of Acquisition in Progress. This signal becomes TRUE when the last piece of data is transferred to memory, indicating that the acquisition has completed.

Frame Start (FRAME_START) and Frame Done (FRAME_DONE) indicate the status of an acquisition on a buffer basis. Frame Start indicates that a buffer is being acquired. This signal becomes TRUE when the device detects the first valid pixel in the current region of interest. The signal becomes FALSE when the device detects the last valid pixel of the frame. If the acquisition is a sequence, a ring, or a grab, Frame Start and Frame Done pulse for every buffer in the acquisition. Frame Done is the inverse of Frame Start and indicates when the image is transferred from the camera to the image acquisition device.

Buffer Complete (BUF_COMPLETE) indicates when the image data has been transferred to memory and is available for image processing. Buffer Complete becomes TRUE when the data in an image buffer has been transferred to memory, which may be either onboard or system memory, depending on the acquisition.

The following figure illustrates the values of the signals during a three-buffer sequence acquisition.

You can use the NI-IMAQ status signals for many purposes. You can generate pulses based on the assertion of any of these signals. Pulse generation allows you to generate specific timing pulses based on acquisitions to control other aspects of your system, such as a strobe light. Furthermore, you can configure callback functions that are invoked by any of these signals. For example, to initiate an image processing routine as soon as an image is in memory, configure a callback containing image processing code. Invoke the callback when you assert Buffer Complete.