function tclcmd = hdlcoderreconcmds
% CTCOSIMCMDS - Creates Tcl commands for the Image Reconstruction model.

%   Copyright 2006-2011 The MathWorks, Inc.
%      

srcfile1 = fullfile(matlabroot,'toolbox','hdlcoder','hdlcoderdemos',...
    'hdlfiles','dpram_model.vhd');
srcfile2 = fullfile(matlabroot,'toolbox','hdlcoder','hdlcoderdemos',...
    'hdlfiles','dpram_top.vhd');

tclsrcfile1 = ['"' strrep(srcfile1,'\','/') '"']; 
tclsrcfile2 = ['"' strrep(srcfile2,'\','/') '"'];

projdir = tempname; 
mkdir(tempdir,strrep(projdir,tempdir,''));
tclprojdir = strrep(projdir,'\','/');
    
accarg = '+acc+dpram_top';

tclcmd = { 
            'catch { wm geometry . 500x200+0+0 }',... % Try moving ModelSim out of the way
           ['cd ',tclprojdir],...            
            'vlib work',... %create library (if necessary)
           ['vcom ' accarg ' -performdefaultbinding ' tclsrcfile1],...
           ['vcom ' accarg ' -performdefaultbinding ' tclsrcfile2],...
           ['vsimulink -voptargs=+acc ' accarg ' work.dpram_top'],...
         };
     