📄 make_demodmappermindist.m
字号:
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Property of Freescale
% Freescale Confidential Proprietary
% Freescale Copyright (C) 2005 All rights reserved
% ----------------------------------------------------------------------------
% $RCSfile: make_DemodMapperMinDist.m.rca $
% $Revision: 1.1 $
% $Date: Fri Jan 26 13:05:43 2007 $
% Target: Matlab
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
% This function should be used to build the MEX object files. Simply type
%
% make_DemodMapper
%
% Matlab 7 Release 14 SP2
%
% Include path:
% The include path is given as follows
% -I'../source'
%
% Endianess:
% By default big endian is assumed. If little endian is required (e.g. on
% Windows PC) the following option must be used
% -DLITTLE_ENDIAN
%
% Optimized MEX-function:
% The option -O can be used.
%
% Debug information:
% The option -g can be used.
%
% Output file name:
% The output MEX object should have the same name as the M-file implementation.
% (just with an appropriate file extension). The following option can used to
% achieve this
% -output module_name
%
% Note:
% Only the wrapper is compiled, i.e. other required files must be included in
% the wrapper ".c".
%
%-- Matlab files used by this file
% FindRevision
% CreateReportMEX
%-- End of list
function make_DemodMapper
ModuleName='DemodMapperMinDist';
if ispc
%Windows PC
DLL = [ModuleName,'.dll'];
if exist(DLL,'file')
s=sprintf('Overwriting MEX object (PC): %s ...',DLL);
disp(s);
else
s=sprintf('Creating MEX object (PC): %s ...',DLL);
disp(s);
end
else
%Unix/Linux
type=computer;
switch type
case 'SOL2' %Solaris 2
MEXSOL = [ModuleName,'.mexsol'];
if exist(MEXSOL,'file')
s=sprintf('Overwriting MEX object (Solaris): %s ...',MEXSOL);
disp(s);
else
s=sprintf('Creating MEX object (Solaris): %s ...',MEXSOL);
disp(s);
end
case 'GLNX86' %Linux 32-bit
MEXGLX = [ModuleName,'.mexglx'];
if exist(MEXGLX,'file')
s=sprintf('Overwriting MEX object (Linux 32-bit): %s ...',MEXGLX);
disp(s);
else
s=sprintf('Creating MEX object (Linux 32-bit): %s ...',MEXGLX);
disp(s);
end
case 'GLNXA64' %Linux AMD 64-bit
MEXA64 = [ModuleName,'.mexa64'];
if exist(MEXA64,'file')
s=sprintf('Overwriting MEX object (Linux AMD64): %s ...',MEXA64);
disp(s);
else
s=sprintf('Creating MEX object (Linux AMD64): %s ...',MEXA64);
disp(s);
end
otherwise
s='Error: UNIX/Linux computer type not supported.';
error(s);
end
end
%remove eventually existing object from matlab environment
clear(ModuleName);
%build object
mex -I../../source -I../../../../../../CM/header -I../../../../../../CM/source -I../../../../../../CM/utility/matlab -I../../../../../../CM/matlab -I../../header -O -output DemodMapperMinDist DemodMapperMinDist.c
movefile('DemodMapperMinDist.dll','./..','f') %move the dll in the matlab level
%-- Create report
%-- Addpath for FindRevision.m and CreateReportMEX.m
addpath('../../../../../../CM/matlab');
sM=FindRevision('mDemodMapperMinDist.m');
sC=FindRevision('../../source/SBX_FPULSPK_DemodMapperMinDist.c');
CreateReportMEX(ModuleName,s,sM,sC);
rmpath('../../../../../../CM/matlab');
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -