reload.m
来自「这是一个关于MATLAB的函数」· M 代码 · 共 41 行
M
41 行
function pfile = reload(cc,timeout)
%RELOAD Load the most recently used program file into the target.
% PFILE = RELOAD(CC,TIMEOUT) - The mostly recently loaded program file
% is reloaded into the target DSP. RELOAD is useful after a reset or
% any event that changes the DSP program memory to reinitialize the
% program for execution. The name of the program file that was
% loaded is returned in PFILE.
%
% PFILE = RELOAD(CC) same as above, except the timeout is
% replaced by the default timeout parameter from the CC object.
%
% See also LOAD, CD.
% Copyright 2001-2002 The MathWorks, Inc.
% $Revision: 1.6 $ $Date: 2002/06/12 15:30:32 $
error(nargchk(1,2,nargin));
if ~ishandle(cc),
error('First Parameter must be a CCSDSP Handle.');
end
pfile = ccsmexswitchyard([29,cc.boardnum,cc.procnum,0,0]);
if isempty(pfile),
warning('No action taken - First load a valid Program file before you reload');
else
% Parse timeout
if( nargin >= 2)&(~isempty(timeout)),
if ~isnumeric(timeout) | length(timeout) ~= 1,
error('TIMEOUT parameter must be a single numeric value.');
end
dtimeout = double(timeout);
else
dtimeout = double(get(cc,'timeout'));
end
if( dtimeout < 0)
error(['Negative TIMEOUT value "' num2str(dtimeout) '" not permitted.']);
end
cc.load(pfile,dtimeout);
end
% [EOF] reload.m
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?