User`s guide

19 Block Reference
19-4
information for your models. One of the Build Information functions that Simulink Coder
provides is packNGo. This function allows you to package model code and dependent
shared libraries into a zip file for deployment. The target system does not need to have
MATLAB installed but it does need to be supported by MATLAB.
The block supports use of the packNGo function. Source-specific properties for your
device are honored when code is generated. The generated code compiles with both C and
C++ compilers.
To set up packNGo:
set_param(gcs, 'PostCodeGenCommand', 'packNGo(buildInfo)');
In this example, gcs is the current model that you wish to build. Building the model
creates a zip file with the same name as model name. You can move this zip file to
another machine and the source code in the zip file can be built to create an executable
which can be run independent of MATLAB and Simulink. For more information on
packNGo, see packNGo.
Note: The From Video Device block supports the use of Simulink Rapid Accelerator mode
and code generation on Windows platforms. Code generation is also supported on Linux,
but Rapid Accelerator mode is not.
Note: If you get a “Device in use” error message when using the block with certain
hardware, such as Matrox, close any programs that are using the hardware, and then try
using the block again.
Note: On Linux platforms, you need to add the directory where you unzip the libraries to
the environment variable LD_LIBRARY_PATH.
Dialog Box
In the Source Block Parameters dialog box, the options that appear are dependent on
the device you are using. The first diagram illustrates the fields that may appear if your
device supports hardware triggering and Bayer Sensor Alignment as a color space option.