Stand-alone from Simulink with avt cameras doesn't build

I'm trying to compile a simulink model using rsim to make a stand-alone with a camera Stingray F-080C from AVT. I'm using the AVTMatlab Adaptor from the AVT website. My model simply captures the video and save it in a .AVI file, using the imaq block and the "To Multimedia file" block. I use the next commands to build the stand-alone model:
mdlName = 'cam';
open_system(mdlName);
cs = getActiveConfigSet(mdlName);
cs.switchTarget('rsim.tlc',[]);
rtwbuild(mdlName);
When I use my webcam the process is successful but when I use the AVT camera I got the next warnings and error:
### Starting build procedure for model: CAM
### Generating code into build folder: D:\Documents\MATLAB\AVT_MATLAB\CAM_rsim_rtw
Warning: Unable to set the source property HighSNR on the device.
Warning: Unable to set the source property HighSNR on the device.
Warning: Code generation advisor detects potential issues with your model. Address issues in advisor
window. Or, turn off the advisor by selecting "Off" for "Check model before code generation" on the Code
Generation pane of the Configuration Parameters dialog
### Build procedure for model: 'CAM' aborted due to an error.
Error using tlc_c (line 174)
Undefined function or variable 'filename'.
Error in RTW.makertw/make_rtw (line 281)
buildResult = tlc_c(h,...
Error in make_rtw (line 22)
buildResult = h.make_rtw(varargin{:});
Error in C:\Program Files\MATLAB\R2011b\toolbox\simulink\simulink\private\build_target.p>RunBuildCmd (line
94)
Error in C:\Program Files\MATLAB\R2011b\toolbox\simulink\simulink\private\build_target.p>build_target (line
6)
Error in C:\Program
Files\MATLAB\R2011b\toolbox\simulink\simulink\private\build_standalone_rtw_target.p>build_standalone_rtw_target
(line 56)
Error in C:\Program
Files\MATLAB\R2011b\toolbox\simulink\simulink\private\slbuild_private.p>loc_codegenentry (line 591)
Error in C:\Program Files\MATLAB\R2011b\toolbox\simulink\simulink\private\slbuild_private.p>slbuild_private
(line 335)
Error in sl (line 16)
[varargout{1:nargout}]=feval(varargin{:});
Error in slbuild (line 62)
sl('slbuild_private', mdl, varargin{:});
Error in rtwbuild (line 174)
slbuild(sys, 'StandaloneRTWTarget', ...
Does anyone how to solve this problem? I really need to compile this model because I need to run this every 30 minutes during a couple of months.

Answers (0)

Categories

Asked:

on 3 Jan 2012

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!