You are here: Service & Support / Knowledge Base/FAQ / VC20xx, VCSBC40xx, VC4xxx
Deutsch
English
Français
Japanese
Do you have a question?

Please contact us via email, contact form or phone
+49-7243-2167-23
(head office, Germany) or directly your local contact.

Special note

This knowledge base is updated regularly. If you need an information and don't find it here, please don't hesitate to contact us! Of course, we're also to your disposal at the phone:
+49 7243 2167-0

How do I take a picture with VC Smart Cameras?

The function capture_request() is the low-level function for capturing an image. All other image-capture functions are based on it.

int capture_request (int exp, int gain, int *start, int mode)

exp is determined from the desired exposure time exptime (µs) with the following formula:
exp = exptime/EXUNIT - 520/944

WARNING: exp is an integer, which means not all exposure times are available.

The value of the system variable EXUNIT depends on the camera model (see table, or use getvar(EXUNIT) on your camera).

Camera

VC2038

VC2048

VC2065

VC2068

VC4018

VC4038

EXUNIT

50

36

39

69

62

31

gain is determined from the desired gain G of the ADC with the following formula:
gain = 8.G(dB)-48

start is the start address for image storage.

mode defines the trigger mode: internal (software) if 0, external if 1. All VC4xxx cameras from VC4038 have a 2x binning mode: to activate it, simply add BINNING (defined in VCRT.h) to the mode parameter.

The function capture_request() sends a request to capture an image: each request is given a tracking number and is stacked. The maximum number of requests that can be stacked is 20. On trigger, the first request on the stack is evaluated and the image capture is made: the second request on the stack becomes first and waits for the trigger, and so on. If the trigger is internal, the capture is done immediately. The memory to store the image has to be allocated before using the function. To cancel a capture request use cancel_capture_rq() in a loop (returns 0 when successful, 1 if unsuccessful):

while(cancel_capture_rq());

The function tpict() captures an image with the internal trigger setting, and with standard exposure time and gain settings (which can be obtained with getvar(EXPCNT), getvar(GAIN)). The image is automatically saved in the image memory of the DRAM (see the document "Programming Tutorial Basics").

The function tenable() captures an image in the same way as tpict() with the external trigger setting and standard settings.

 

Home  |  Contact  |  Sitemap  |  Imprint  |  Terms  |  Knowledge Base / FAQ  |  RMA  |  Loan Systems  |  Consulting

© 2011 Vision Components GmbH - The Smart Camera People