Example programs are located in the following directory:
$HOME/DALSA/GigeV/examples

The example programs are categorized by the basic functionality they demonstrate.
|
Grab/Display Frame Data |
Description |
|
genicam_c_demo |
The genicam_c_demo program demonstrates a grab and
display application using only C language calls to the Framework API. |
|
genicam_cpp_demo |
The genicam_cpp_demo program demonstrates a grab and
display application along with access to the underlying GenICam GenApi
classes. |
|
genicam_chunk_demo |
The
genicam_chunk_demo program demonstrates how to extract metadata from a frame
buffer using the chunk data layout information provided by the GenICam XML
file. Grab and display functionality is also demonstrated. |
|
genie_nano_metadata_demo |
The
genie_nano_metadata program demonstrates how to access metadata in a frame by
directly accessing the memory location in the frame buffer containing the
fixed chunk data layout provided by the Genie Nano family of cameras. Grab
and display functionality is also demonstrated. |
|
gevconsoledemo |
This demo is
provided for compatibility with older DALSA cameras; use newer demos for
reference when creating applications. The
gevconsoledemo program demonstrates a grab and display application utilizing
direct register access to the camera. Only cameras known to the API can be
used with this program since the camera register definitions need to be
hardcoded in a static table. For more
information, please see Appendix C: Feature Access Through Static
Registers. |
|
Archive Frame Data |
Description |
|
save_data_demo |
The
save_data_demo (in $HOME/DALSA/GigeV/examples/archive_data) saves frame data
to a container file (of type “.gevbuf”). It saves single frames or sequences
of frames to the “.gevbuf” containers with options to include metadata (chunk
data), and to control the type of image data decoding performed prior to
storage. |
|
restore_nano_data_demo |
The
restore_nano_data_demo (in $HOME/DALSA/GigeV/examples/archive_data) restores
frame data from the variable length “.gevbuf” containers created by the
save_data_demo. The program demonstrates how to recover the frame data,
perform any decoding required to generate usable images, and optionally save
the image data to TIFF files. If metadata (chunk data) is present in the
container, it is accessed as the fixed chunk data layout provided by the
Genie Nano family of cameras. |
|
GenICam Feature Access |
Description |
|
dumpfeatures |
The dumpfeatures
program (in $HOME/DALSA/GigeV/examples/dump_features) demonstrates how to access
the GenICam XML features of a camera and output the entire hierarchy of
features, including their type, to the screen. |
|
savefeatures |
The savefeatures
program (in $HOME/DALSA/GigeV/examples/dump_features) demonstrates how to save
the streamable features, as {feature_name : value} pairs, to the screen or to
a text file. |
|
loadfeatures |
The loadfeatures
program (in $HOME/DALSA/GigeV/examples/dump_features) demonstrates how to
load {feature_name : value} pairs, from a text file, to the camera. |
|
c_loadfeatures |
The
c_loadfeatures program (in $HOME/DALSA/GigeV/examples/dump_features)
demonstrates loading {feature_name : value } pairs from a text file to the
camera using only C callable functions from the Framework API. |
|
genicam_fileaccessdemo |
The
genicam_fileaccessdemo program demonstrates access to the file interface on
the camera. The files present can be detected and read or written, as allowed
by the definitions provided by the GenICam XML file associated with the
camera. |
|
GigE Vision ACTION_CMD |
Description |
|
nano_trigger_demo |
The
nano_trigger_demo (in $HOME/DALSA/GigeV/examples/genie_nano_actioncmd_demo) demonstrated
how to set up a camera for use with the action_cmd_demo. The demo sets camera
features to acquire images from a trigger provided by an action command
(Action1) using the default ACTION_CMD functionality provided by the Genie
Nano family of cameras. |
|
action_cmd_demo |
The
action_cmd_demo (in $HOME/DALSA/GigeV/examples/genie_nano_actioncmd_demo)
demonstrates how to send an action command to cameras on a network. The demo
sends an ACTION_CMD specific to the Genie Nano family of cameras to be
identified as Action1. The accompanying nano_trigger_demo will receive frames
triggered by Action1. |
|
|
Note: Running demos that display images, such as genicam_c_demo and genicam_cpp_demo, on an ARM hard float platform using the ARM soft float package (GigE-V-Framework_ARMsf_xxx) will not execute properly unless the required soft float library packages are installed. |
Each example program directory includes a makefile to compile the example. Examples must be compiled before using by running the make command in the example directory. For example, in Ubuntu:
sapera@computername:~/DALSA/GigeV/examples/genicam_c_demo$ make
|
|
Note: If the make operation fails on link, verify that the required prerequisites are installed for the given hardware architecture (for example, ARM hardfloat, ARM softfloat, and Intel x86). |
Call the program name to run program. For example, in Ubuntu, to run the program in the current directory, precede the program name with “./”:
sapera@computername:~/DALSA/GigeV/examples/genicam_c_demo$
./genicam_c_demo
If multiple cameras are connected, most example programs can be invoked using a camera index (starting from 0):
./genicam_c_demo 1
|
|
Note: For multiple cameras on the same NIC indices are not static and are populated dynamically when the program is run, therefore the index for a specific camera may change depending on the order it is acknowledged when the program is run. Functions are provided to perform automatic camera (device) discovery and enumeration; see the Automatic Camera Discovery section. Functions are also available to open cameras by IP address, name or serial number; see the Connecting to a Camera section for more information. |
The “-“ or “?” switch provides usage for most example programs. For example,
ubuntu@tegra-ubuntu:~/DALSA/GigeV/examples/dump_features$
./savefeatures ?
GigE Vision Library GenICam Feature Save Example (May 6 2016)
3 camera(s) on the network
Usage: savefeatures : Output features from
camera 0 to stdout.
savefeatures -
cam_index : Output features from
camera 'cam_index' to stdout. (Note the hyphen indicating stdout)
savefeatures
filename : Save features from
camera 0 to 'filename'.
savefeatures
filename cam_index : Save features from camera 'cam_index' to 'filename'.
ubuntu@tegra-ubuntu:~/DALSA/GigeV/examples/dump_features$
Related Topics
GigE-V Framework for Linux Overview
Image Display
Saving Images
Grab Demos
File Access Example
Feature Access Examples
Archive Data Examples
Action Command Example