?? mymethod0_sfun.c
字號:
/* Include files */
#include "mymethod0_sfun.h"
#include "c2_mymethod0.h"
/* Type Definitions */
/* Named Constants */
/* Variable Declarations */
/* Variable Definitions */
uint8_T _sfEvent_;
uint32_T _mymethod0MachineNumber_;
real_T _sfTime_;
/* Function Declarations */
/* Function Definitions */
void mymethod0_initializer(void)
{
_sfEvent_ = CALL_EVENT;
}
void mymethod0_terminator(void)
{
}
/* SFunction Glue Code */
unsigned int sf_mymethod0_method_dispatcher(SimStruct *simstructPtr, unsigned
int chartFileNumber, int_T method, void *data)
{
if(chartFileNumber==2) {
c2_mymethod0_method_dispatcher(simstructPtr, method, data);
return 1;
}
return 0;
}
unsigned int sf_mymethod0_process_check_sum_call( int nlhs, mxArray * plhs[],
int nrhs, const mxArray * prhs[] )
{
#ifdef MATLAB_MEX_FILE
char commandName[20];
if (nrhs<1 || !mxIsChar(prhs[0]) ) return 0;
/* Possible call to get the checksum */
mxGetString(prhs[0], commandName,sizeof(commandName)/sizeof(char));
commandName[(sizeof(commandName)/sizeof(char)-1)] = '\0';
if(strcmp(commandName,"sf_get_check_sum")) return 0;
plhs[0] = mxCreateDoubleMatrix( 1,4,mxREAL);
if(nrhs>1 && mxIsChar(prhs[1])) {
mxGetString(prhs[1], commandName,sizeof(commandName)/sizeof(char));
commandName[(sizeof(commandName)/sizeof(char)-1)] = '\0';
if(!strcmp(commandName,"machine")) {
((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(2308483623U);
((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(3424148644U);
((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(2827467229U);
((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(827026884U);
}else if(!strcmp(commandName,"exportedFcn")) {
((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(0U);
((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(0U);
((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(0U);
((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(0U);
}else if(!strcmp(commandName,"makefile")) {
((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(2436477407U);
((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(3132148161U);
((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(200691780U);
((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(1303230451U);
}else if(nrhs==3 && !strcmp(commandName,"chart")) {
unsigned int chartFileNumber;
chartFileNumber = (unsigned int)mxGetScalar(prhs[2]);
switch(chartFileNumber) {
case 2:
{
extern void sf_c2_mymethod0_get_check_sum(mxArray *plhs[]);
sf_c2_mymethod0_get_check_sum(plhs);
break;
}
default:
((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(0.0);
((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(0.0);
((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(0.0);
((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(0.0);
}
}else if(!strcmp(commandName,"target")) {
((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(2553529877U);
((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(1250385535U);
((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(3747036769U);
((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(84901116U);
}else {
return 0;
}
} else{
((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(1952163918U);
((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(2314747093U);
((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(902054370U);
((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(1432277397U);
}
return 1;
#else
return 0;
#endif
}
unsigned int sf_mymethod0_autoinheritance_info( int nlhs, mxArray * plhs[], int
nrhs, const mxArray * prhs[] )
{
#ifdef MATLAB_MEX_FILE
char commandName[32];
if (nrhs<2 || !mxIsChar(prhs[0]) ) return 0;
/* Possible call to get the autoinheritance_info */
mxGetString(prhs[0], commandName,sizeof(commandName)/sizeof(char));
commandName[(sizeof(commandName)/sizeof(char)-1)] = '\0';
if(strcmp(commandName,"get_autoinheritance_info")) return 0;
{
unsigned int chartFileNumber;
chartFileNumber = (unsigned int)mxGetScalar(prhs[1]);
switch(chartFileNumber) {
case 2:
{
extern mxArray *sf_c2_mymethod0_get_autoinheritance_info(void);
plhs[0] = sf_c2_mymethod0_get_autoinheritance_info();
break;
}
default:
plhs[0] = mxCreateDoubleMatrix(0,0,mxREAL);
}
}
return 1;
#else
return 0;
#endif
}
unsigned int sf_mymethod0_get_eml_resolved_functions_info( int nlhs, mxArray *
plhs[], int nrhs, const mxArray * prhs[] )
{
#ifdef MATLAB_MEX_FILE
char commandName[32];
if (nrhs<2 || !mxIsChar(prhs[0]) ) return 0;
/* Possible call to get the get_eml_resolved_functions_info */
mxGetString(prhs[0], commandName,sizeof(commandName)/sizeof(char));
commandName[(sizeof(commandName)/sizeof(char)-1)] = '\0';
if(strcmp(commandName,"get_eml_resolved_functions_info")) return 0;
{
unsigned int chartFileNumber;
chartFileNumber = (unsigned int)mxGetScalar(prhs[1]);
switch(chartFileNumber) {
case 2:
{
extern const mxArray
*sf_c2_mymethod0_get_eml_resolved_functions_info(void);
plhs[0] = (mxArray *)sf_c2_mymethod0_get_eml_resolved_functions_info();
break;
}
default:
plhs[0] = mxCreateDoubleMatrix(0,0,mxREAL);
}
}
return 1;
#else
return 0;
#endif
}
void mymethod0_debug_initialize(void)
{
_mymethod0MachineNumber_ =
sf_debug_initialize_machine("mymethod0","sfun",0,1,0,0,0);
sf_debug_set_machine_event_thresholds(_mymethod0MachineNumber_,0,0);
sf_debug_set_machine_data_thresholds(_mymethod0MachineNumber_,0);
}
void mymethod0_register_exported_symbols(SimStruct* S)
{
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -