/* Include files */ #include "modello2cam_sfun.h" #include "c2_modello2cam.h" #define CHARTINSTANCE_CHARTNUMBER (chartInstance.chartNumber) #define CHARTINSTANCE_INSTANCENUMBER (chartInstance.instanceNumber) #include "modello2cam_sfun_debug_macros.h" /* Type Definitions */ /* Named Constants */ #define c2_IN_NO_ACTIVE_CHILD (0) /* Variable Declarations */ /* Variable Definitions */ static SFc2_modello2camInstanceStruct chartInstance; /* Function Declarations */ static void initialize_c2_modello2cam(void); static void initialize_params_c2_modello2cam(void); static void enable_c2_modello2cam(void); static void disable_c2_modello2cam(void); static void update_debugger_state_c2_modello2cam(void); static const mxArray *get_sim_state_c2_modello2cam(void); static void set_sim_state_c2_modello2cam(const mxArray *c2_st); static void finalize_c2_modello2cam(void); static void sf_c2_modello2cam(void); static void init_script_number_translation(uint32_T c2_machineNumber, uint32_T c2_chartNumber); static const mxArray *c2_sf_marshall(void *c2_chartInstance, void *c2_u); static const mxArray *c2_b_sf_marshall(void *c2_chartInstance, void *c2_u); static void init_dsm_address_info(void); /* Function Definitions */ static void initialize_c2_modello2cam(void) { _sfTime_ = (real_T)ssGetT(chartInstance.S); chartInstance.c2_is_active_c2_modello2cam = 0U; } static void initialize_params_c2_modello2cam(void) { } static void enable_c2_modello2cam(void) { _sfTime_ = (real_T)ssGetT(chartInstance.S); } static void disable_c2_modello2cam(void) { _sfTime_ = (real_T)ssGetT(chartInstance.S); } static void update_debugger_state_c2_modello2cam(void) { } static const mxArray *get_sim_state_c2_modello2cam(void) { return NULL; } static void set_sim_state_c2_modello2cam(const mxArray *c2_st) { sf_mex_destroy(&c2_st); } static void finalize_c2_modello2cam(void) { } static void sf_c2_modello2cam(void) { int32_T c2_i0; int32_T c2_i1; uint8_T c2_previousEvent; int32_T c2_i2; real_T c2_Jin[1000]; real_T c2_aim; real_T c2_aip; real_T c2_nargout = 1.0; real_T c2_nargin = 3.0; real_T c2_i; real_T c2_Jout[1000]; int32_T c2_i3; real_T c2_b_i; real_T c2_a; real_T c2_y; real_T c2_b_a; real_T c2_b_y; int32_T c2_i4; real_T *c2_b_aim; real_T *c2_b_aip; real_T (*c2_b_Jout)[1000]; real_T (*c2_b_Jin)[1000]; c2_b_aim = (real_T *)ssGetInputPortSignal(chartInstance.S, 1); c2_b_aip = (real_T *)ssGetInputPortSignal(chartInstance.S, 2); c2_b_Jout = (real_T (*)[1000])ssGetOutputPortSignal(chartInstance.S, 1); c2_b_Jin = (real_T (*)[1000])ssGetInputPortSignal(chartInstance.S, 0); _sfTime_ = (real_T)ssGetT(chartInstance.S); _SFD_CC_CALL(CHART_ENTER_SFUNCTION_TAG,0); for (c2_i0 = 0; c2_i0 < 1000; c2_i0 = c2_i0 + 1) { _SFD_DATA_RANGE_CHECK((*c2_b_Jin)[c2_i0], 0U); } for (c2_i1 = 0; c2_i1 < 1000; c2_i1 = c2_i1 + 1) { _SFD_DATA_RANGE_CHECK((*c2_b_Jout)[c2_i1], 1U); } _SFD_DATA_RANGE_CHECK(*c2_b_aim, 2U); _SFD_DATA_RANGE_CHECK(*c2_b_aip, 3U); c2_previousEvent = _sfEvent_; _sfEvent_ = CALL_EVENT; _SFD_CC_CALL(CHART_ENTER_DURING_FUNCTION_TAG,0); for (c2_i2 = 0; c2_i2 < 1000; c2_i2 = c2_i2 + 1) { c2_Jin[c2_i2] = (*c2_b_Jin)[c2_i2]; } c2_aim = *c2_b_aim; c2_aip = *c2_b_aip; sf_debug_symbol_scope_push(7U, 0U); sf_debug_symbol_scope_add("nargout", &c2_nargout, c2_b_sf_marshall); sf_debug_symbol_scope_add("nargin", &c2_nargin, c2_b_sf_marshall); sf_debug_symbol_scope_add("i", &c2_i, c2_b_sf_marshall); sf_debug_symbol_scope_add("Jout", &c2_Jout, c2_sf_marshall); sf_debug_symbol_scope_add("aip", &c2_aip, c2_b_sf_marshall); sf_debug_symbol_scope_add("aim", &c2_aim, c2_b_sf_marshall); sf_debug_symbol_scope_add("Jin", &c2_Jin, c2_sf_marshall); CV_EML_FCN(0, 0); /* This block supports the Embedded MATLAB subset. */ /* See the help menu for details. */ _SFD_EML_CALL(0,4); for (c2_i3 = 0; c2_i3 < 1000; c2_i3 = c2_i3 + 1) { c2_Jout[c2_i3] = c2_Jin[c2_i3]; } c2_i = 1.0; c2_b_i = 1.0; while (c2_b_i <= 1000.0) { c2_i = c2_b_i; CV_EML_FOR(0, 0, 1); _SFD_EML_CALL(0,6); c2_a = c2_aim; c2_y = c2_a * 1000.0; if (CV_EML_COND(0, 0, c2_i > c2_y)) { c2_b_a = c2_aip; c2_b_y = c2_b_a * 1000.0; if (CV_EML_COND(0, 1, c2_i < c2_b_y)) { CV_EML_MCDC(0, 0, true); CV_EML_IF(0, 0, true); _SFD_EML_CALL(0,6); c2_Jout[_SFD_EML_ARRAY_BOUNDS_CHECK("Jout", (int32_T)_SFD_INTEGER_CHECK( "i", c2_i), 1, 1000, 1, 0) - 1] = c2_Jin[ _SFD_EML_ARRAY_BOUNDS_CHECK("Jin", (int32_T)_SFD_INTEGER_CHECK("i", c2_i), 1, 1000, 1, 0) - 1] + 1.0; goto label_1; } } CV_EML_MCDC(0, 0, false); CV_EML_IF(0, 0, false); _SFD_EML_CALL(0,7); c2_Jout[_SFD_EML_ARRAY_BOUNDS_CHECK("Jout", (int32_T)_SFD_INTEGER_CHECK("i", c2_i), 1, 1000, 1, 0) - 1] = 0.0; label_1: ; c2_b_i = c2_b_i + 1.0; sf_mex_listen_for_ctrl_c(chartInstance.S); } CV_EML_FOR(0, 0, 0); _SFD_EML_CALL(0,-7); sf_debug_symbol_scope_pop(); for (c2_i4 = 0; c2_i4 < 1000; c2_i4 = c2_i4 + 1) { (*c2_b_Jout)[c2_i4] = c2_Jout[c2_i4]; } _SFD_CC_CALL(EXIT_OUT_OF_FUNCTION_TAG,0); _sfEvent_ = c2_previousEvent; sf_debug_check_for_state_inconsistency(_modello2camMachineNumber_, chartInstance.chartNumber, chartInstance.instanceNumber); } static void init_script_number_translation(uint32_T c2_machineNumber, uint32_T c2_chartNumber) { } static const mxArray *c2_sf_marshall(void *c2_chartInstance, void *c2_u) { const mxArray *c2_y = NULL; int32_T c2_i5; real_T c2_b_u[1000]; const mxArray *c2_b_y = NULL; c2_y = NULL; for (c2_i5 = 0; c2_i5 < 1000; c2_i5 = c2_i5 + 1) { c2_b_u[c2_i5] = (*((real_T (*)[1000])c2_u))[c2_i5]; } c2_b_y = NULL; sf_mex_assign(&c2_b_y, sf_mex_create("y", &c2_b_u, 0, 0U, 1U, 0U, 1, 1000)); sf_mex_assign(&c2_y, c2_b_y); return c2_y; } static const mxArray *c2_b_sf_marshall(void *c2_chartInstance, void *c2_u) { const mxArray *c2_y = NULL; real_T c2_b_u; const mxArray *c2_b_y = NULL; c2_y = NULL; c2_b_u = *((real_T *)c2_u); c2_b_y = NULL; sf_mex_assign(&c2_b_y, sf_mex_create("y", &c2_b_u, 0, 0U, 0U, 0U, 0)); sf_mex_assign(&c2_y, c2_b_y); return c2_y; } const mxArray *sf_c2_modello2cam_get_eml_resolved_functions_info(void) { const mxArray *c2_nameCaptureInfo = NULL; c2_ResolvedFunctionInfo c2_info[14]; c2_ResolvedFunctionInfo (*c2_b_info)[14]; const mxArray *c2_m0 = NULL; int32_T c2_i6; c2_ResolvedFunctionInfo *c2_r0; c2_nameCaptureInfo = NULL; c2_b_info = (c2_ResolvedFunctionInfo (*)[14])c2_info; (*c2_b_info)[0].context = ""; (*c2_b_info)[0].name = "plus"; (*c2_b_info)[0].dominantType = "double"; (*c2_b_info)[0].resolved = "[B]plus"; (*c2_b_info)[0].fileLength = 0U; (*c2_b_info)[0].fileTime1 = 0U; (*c2_b_info)[0].fileTime2 = 0U; (*c2_b_info)[1].context = ""; (*c2_b_info)[1].name = "lt"; (*c2_b_info)[1].dominantType = "double"; (*c2_b_info)[1].resolved = "[B]lt"; (*c2_b_info)[1].fileLength = 0U; (*c2_b_info)[1].fileTime1 = 0U; (*c2_b_info)[1].fileTime2 = 0U; (*c2_b_info)[2].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[2].name = "class"; (*c2_b_info)[2].dominantType = "double"; (*c2_b_info)[2].resolved = "[B]class"; (*c2_b_info)[2].fileLength = 0U; (*c2_b_info)[2].fileTime1 = 0U; (*c2_b_info)[2].fileTime2 = 0U; (*c2_b_info)[3].context = ""; (*c2_b_info)[3].name = "mtimes"; (*c2_b_info)[3].dominantType = "double"; (*c2_b_info)[3].resolved = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[3].fileLength = 2336U; (*c2_b_info)[3].fileTime1 = 1213659289U; (*c2_b_info)[3].fileTime2 = 0U; (*c2_b_info)[4].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[4].name = "nargin"; (*c2_b_info)[4].dominantType = ""; (*c2_b_info)[4].resolved = "[B]nargin"; (*c2_b_info)[4].fileLength = 0U; (*c2_b_info)[4].fileTime1 = 0U; (*c2_b_info)[4].fileTime2 = 0U; (*c2_b_info)[5].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[5].name = "isa"; (*c2_b_info)[5].dominantType = "double"; (*c2_b_info)[5].resolved = "[B]isa"; (*c2_b_info)[5].fileLength = 0U; (*c2_b_info)[5].fileTime1 = 0U; (*c2_b_info)[5].fileTime2 = 0U; (*c2_b_info)[6].context = ""; (*c2_b_info)[6].name = "numel"; (*c2_b_info)[6].dominantType = "double"; (*c2_b_info)[6].resolved = "[B]numel"; (*c2_b_info)[6].fileLength = 0U; (*c2_b_info)[6].fileTime1 = 0U; (*c2_b_info)[6].fileTime2 = 0U; (*c2_b_info)[7].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[7].name = "size"; (*c2_b_info)[7].dominantType = "double"; (*c2_b_info)[7].resolved = "[B]size"; (*c2_b_info)[7].fileLength = 0U; (*c2_b_info)[7].fileTime1 = 0U; (*c2_b_info)[7].fileTime2 = 0U; (*c2_b_info)[8].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[8].name = "isinteger"; (*c2_b_info)[8].dominantType = "double"; (*c2_b_info)[8].resolved = "[B]isinteger"; (*c2_b_info)[8].fileLength = 0U; (*c2_b_info)[8].fileTime1 = 0U; (*c2_b_info)[8].fileTime2 = 0U; (*c2_b_info)[9].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[9].name = "not"; (*c2_b_info)[9].dominantType = "logical"; (*c2_b_info)[9].resolved = "[B]not"; (*c2_b_info)[9].fileLength = 0U; (*c2_b_info)[9].fileTime1 = 0U; (*c2_b_info)[9].fileTime2 = 0U; (*c2_b_info)[10].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[10].name = "strcmp"; (*c2_b_info)[10].dominantType = "char"; (*c2_b_info)[10].resolved = "[B]strcmp"; (*c2_b_info)[10].fileLength = 0U; (*c2_b_info)[10].fileTime1 = 0U; (*c2_b_info)[10].fileTime2 = 0U; (*c2_b_info)[11].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[11].name = "isscalar"; (*c2_b_info)[11].dominantType = "double"; (*c2_b_info)[11].resolved = "[B]isscalar"; (*c2_b_info)[11].fileLength = 0U; (*c2_b_info)[11].fileTime1 = 0U; (*c2_b_info)[11].fileTime2 = 0U; (*c2_b_info)[12].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[12].name = "eq"; (*c2_b_info)[12].dominantType = "double"; (*c2_b_info)[12].resolved = "[B]eq"; (*c2_b_info)[12].fileLength = 0U; (*c2_b_info)[12].fileTime1 = 0U; (*c2_b_info)[12].fileTime2 = 0U; (*c2_b_info)[13].context = "[I]$matlabroot$/toolbox/eml/lib/matlab/ops/mtimes.m"; (*c2_b_info)[13].name = "gt"; (*c2_b_info)[13].dominantType = "double"; (*c2_b_info)[13].resolved = "[B]gt"; (*c2_b_info)[13].fileLength = 0U; (*c2_b_info)[13].fileTime1 = 0U; (*c2_b_info)[13].fileTime2 = 0U; sf_mex_assign(&c2_m0, sf_mex_createstruct("nameCaptureInfo", 1, 14)); for (c2_i6 = 0; c2_i6 < 14; c2_i6 = c2_i6 + 1) { c2_r0 = &c2_info[c2_i6]; sf_mex_addfield(c2_m0, sf_mex_create("nameCaptureInfo", c2_r0->context, 15, 0U, 0U, 0U, 2, 1, strlen(c2_r0->context)), "context", "nameCaptureInfo", c2_i6); sf_mex_addfield(c2_m0, sf_mex_create("nameCaptureInfo", c2_r0->name, 15, 0U, 0U, 0U, 2, 1, strlen(c2_r0->name)), "name", "nameCaptureInfo", c2_i6); sf_mex_addfield(c2_m0, sf_mex_create("nameCaptureInfo", c2_r0->dominantType, 15, 0U, 0U, 0U, 2, 1, strlen(c2_r0->dominantType)), "dominantType", "nameCaptureInfo", c2_i6); sf_mex_addfield(c2_m0, sf_mex_create("nameCaptureInfo", c2_r0->resolved, 15, 0U, 0U, 0U, 2, 1, strlen(c2_r0->resolved)), "resolved" , "nameCaptureInfo", c2_i6); sf_mex_addfield(c2_m0, sf_mex_create("nameCaptureInfo", &c2_r0->fileLength, 7, 0U, 0U, 0U, 0), "fileLength", "nameCaptureInfo", c2_i6); sf_mex_addfield(c2_m0, sf_mex_create("nameCaptureInfo", &c2_r0->fileTime1, 7, 0U, 0U, 0U, 0), "fileTime1", "nameCaptureInfo", c2_i6); sf_mex_addfield(c2_m0, sf_mex_create("nameCaptureInfo", &c2_r0->fileTime2, 7, 0U, 0U, 0U, 0), "fileTime2", "nameCaptureInfo", c2_i6); } sf_mex_assign(&c2_nameCaptureInfo, c2_m0); return c2_nameCaptureInfo; } static void init_dsm_address_info(void) { } /* SFunction Glue Code */ void sf_c2_modello2cam_get_check_sum(mxArray *plhs[]) { ((real_T *)mxGetPr((plhs[0])))[0] = (real_T)(3844266535U); ((real_T *)mxGetPr((plhs[0])))[1] = (real_T)(2853551497U); ((real_T *)mxGetPr((plhs[0])))[2] = (real_T)(996855293U); ((real_T *)mxGetPr((plhs[0])))[3] = (real_T)(3809718285U); } mxArray *sf_c2_modello2cam_get_autoinheritance_info(void) { const char *autoinheritanceFields[] = { "checksum", "inputs", "parameters", "outputs" }; mxArray *mxAutoinheritanceInfo = mxCreateStructMatrix(1,1,4, autoinheritanceFields); { mxArray *mxChecksum = mxCreateDoubleMatrix(4,1,mxREAL); double *pr = mxGetPr(mxChecksum); pr[0] = (double)(3062642142U); pr[1] = (double)(2216815091U); pr[2] = (double)(838134866U); pr[3] = (double)(1889160357U); mxSetField(mxAutoinheritanceInfo,0,"checksum",mxChecksum); } { const char *dataFields[] = { "size", "type", "complexity" }; mxArray *mxData = mxCreateStructMatrix(1,3,3,dataFields); { mxArray *mxSize = mxCreateDoubleMatrix(1,2,mxREAL); double *pr = mxGetPr(mxSize); pr[0] = (double)(1000); pr[1] = (double)(1); mxSetField(mxData,0,"size",mxSize); } { const char *typeFields[] = { "base", "fixpt" }; mxArray *mxType = mxCreateStructMatrix(1,1,2,typeFields); mxSetField(mxType,0,"base",mxCreateDoubleScalar(10)); mxSetField(mxType,0,"fixpt",mxCreateDoubleMatrix(0,0,mxREAL)); mxSetField(mxData,0,"type",mxType); } mxSetField(mxData,0,"complexity",mxCreateDoubleScalar(0)); { mxArray *mxSize = mxCreateDoubleMatrix(1,2,mxREAL); double *pr = mxGetPr(mxSize); pr[0] = (double)(1); pr[1] = (double)(1); mxSetField(mxData,1,"size",mxSize); } { const char *typeFields[] = { "base", "fixpt" }; mxArray *mxType = mxCreateStructMatrix(1,1,2,typeFields); mxSetField(mxType,0,"base",mxCreateDoubleScalar(10)); mxSetField(mxType,0,"fixpt",mxCreateDoubleMatrix(0,0,mxREAL)); mxSetField(mxData,1,"type",mxType); } mxSetField(mxData,1,"complexity",mxCreateDoubleScalar(0)); { mxArray *mxSize = mxCreateDoubleMatrix(1,2,mxREAL); double *pr = mxGetPr(mxSize); pr[0] = (double)(1); pr[1] = (double)(1); mxSetField(mxData,2,"size",mxSize); } { const char *typeFields[] = { "base", "fixpt" }; mxArray *mxType = mxCreateStructMatrix(1,1,2,typeFields); mxSetField(mxType,0,"base",mxCreateDoubleScalar(10)); mxSetField(mxType,0,"fixpt",mxCreateDoubleMatrix(0,0,mxREAL)); mxSetField(mxData,2,"type",mxType); } mxSetField(mxData,2,"complexity",mxCreateDoubleScalar(0)); mxSetField(mxAutoinheritanceInfo,0,"inputs",mxData); } { mxSetField(mxAutoinheritanceInfo,0,"parameters",mxCreateDoubleMatrix(0,0, mxREAL)); } { const char *dataFields[] = { "size", "type", "complexity" }; mxArray *mxData = mxCreateStructMatrix(1,1,3,dataFields); { mxArray *mxSize = mxCreateDoubleMatrix(1,2,mxREAL); double *pr = mxGetPr(mxSize); pr[0] = (double)(1000); pr[1] = (double)(1); mxSetField(mxData,0,"size",mxSize); } { const char *typeFields[] = { "base", "fixpt" }; mxArray *mxType = mxCreateStructMatrix(1,1,2,typeFields); mxSetField(mxType,0,"base",mxCreateDoubleScalar(10)); mxSetField(mxType,0,"fixpt",mxCreateDoubleMatrix(0,0,mxREAL)); mxSetField(mxData,0,"type",mxType); } mxSetField(mxData,0,"complexity",mxCreateDoubleScalar(0)); mxSetField(mxAutoinheritanceInfo,0,"outputs",mxData); } return(mxAutoinheritanceInfo); } static void chart_debug_initialization(SimStruct *S, unsigned int fullDebuggerInitialization) { if (ssIsFirstInitCond(S) && fullDebuggerInitialization==1) { /* do this only if simulation is starting */ if (!sim_mode_is_rtw_gen(S)) { { unsigned int chartAlreadyPresent; chartAlreadyPresent = sf_debug_initialize_chart (_modello2camMachineNumber_, 2, 1, 1, 4, 0, 0, 0, 0, 0, &(chartInstance.chartNumber), &(chartInstance.instanceNumber), ssGetPath(S), (void *)S); if (chartAlreadyPresent==0) { /* this is the first instance */ init_script_number_translation(_modello2camMachineNumber_, chartInstance.chartNumber); sf_debug_set_chart_disable_implicit_casting(_modello2camMachineNumber_, chartInstance.chartNumber,1); sf_debug_set_chart_event_thresholds(_modello2camMachineNumber_, chartInstance.chartNumber, 0, 0, 0); { unsigned int dimVector[1]; dimVector[0]= 1000; _SFD_SET_DATA_PROPS(0,1,1,0,SF_DOUBLE,1,&(dimVector[0]),0,0,0,0.0, 1.0,0,"Jin",0,c2_sf_marshall); } { unsigned int dimVector[1]; dimVector[0]= 1000; _SFD_SET_DATA_PROPS(1,2,0,1,SF_DOUBLE,1,&(dimVector[0]),0,0,0,0.0, 1.0,0,"Jout",0,NULL); } _SFD_SET_DATA_PROPS(2,1,1,0,SF_DOUBLE,0,NULL,0,0,0,0.0,1.0,0,"aim",0, c2_b_sf_marshall); _SFD_SET_DATA_PROPS(3,1,1,0,SF_DOUBLE,0,NULL,0,0,0,0.0,1.0,0,"aip",0, NULL); _SFD_STATE_INFO(0,0,2); _SFD_CH_SUBSTATE_COUNT(0); _SFD_CH_SUBSTATE_DECOMP(0); } _SFD_CV_INIT_CHART(0,0,0,0); { _SFD_CV_INIT_STATE(0,0,0,0,0,0,NULL,NULL); } _SFD_CV_INIT_TRANS(0,0,NULL,NULL,0,NULL); /* Initialization of EML Model Coverage */ _SFD_CV_INIT_EML(0,1,1,0,1,0,2,1); _SFD_CV_INIT_EML_FCN(0,0,"eML_blk_kernel",0,-1,232); _SFD_CV_INIT_EML_IF(0,0,150,181,205,228); _SFD_CV_INIT_EML_FOR(0,0,127,146,232); { static int condStart[] = { 153, 169 }; static int condEnd[] = { 165, 181 }; static int pfixExpr[] = { 0, 1, -3 }; _SFD_CV_INIT_EML_MCDC(0,0,153,181,2,0,&(condStart[0]),&(condEnd[0]),3, &(pfixExpr[0])); } _SFD_TRANS_COV_WTS(0,0,0,1,0); if (chartAlreadyPresent==0) { _SFD_TRANS_COV_MAPS(0, 0,NULL,NULL, 0,NULL,NULL, 1,NULL,NULL, 0,NULL,NULL); } { real_T (*c2_Jin)[1000]; real_T (*c2_Jout)[1000]; real_T *c2_aim; real_T *c2_aip; c2_aim = (real_T *)ssGetInputPortSignal(chartInstance.S, 1); c2_aip = (real_T *)ssGetInputPortSignal(chartInstance.S, 2); c2_Jout = (real_T (*)[1000])ssGetOutputPortSignal(chartInstance.S, 1); c2_Jin = (real_T (*)[1000])ssGetInputPortSignal(chartInstance.S, 0); _SFD_SET_DATA_VALUE_PTR(0U, c2_Jin); _SFD_SET_DATA_VALUE_PTR(1U, c2_Jout); _SFD_SET_DATA_VALUE_PTR(2U, c2_aim); _SFD_SET_DATA_VALUE_PTR(3U, c2_aip); } } } } else { sf_debug_reset_current_state_configuration(_modello2camMachineNumber_, chartInstance.chartNumber,chartInstance.instanceNumber); } } static void sf_opaque_initialize_c2_modello2cam(void *chartInstanceVar) { chart_debug_initialization(chartInstance.S,0); initialize_params_c2_modello2cam(); initialize_c2_modello2cam(); } static void sf_opaque_enable_c2_modello2cam(void *chartInstanceVar) { enable_c2_modello2cam(); } static void sf_opaque_disable_c2_modello2cam(void *chartInstanceVar) { disable_c2_modello2cam(); } static void sf_opaque_gateway_c2_modello2cam(void *chartInstanceVar) { sf_c2_modello2cam(); } static mxArray* sf_opaque_get_sim_state_c2_modello2cam(void *chartInstanceVar) { mxArray *st = (mxArray *) get_sim_state_c2_modello2cam(); return st; } static void sf_opaque_set_sim_state_c2_modello2cam(void *chartInstanceVar, const mxArray *st) { set_sim_state_c2_modello2cam(sf_mex_dup(st)); } static void sf_opaque_terminate_c2_modello2cam(void *chartInstanceVar) { if (sim_mode_is_rtw_gen(chartInstance.S) || sim_mode_is_external (chartInstance.S)) { sf_clear_rtw_identifier(chartInstance.S); } finalize_c2_modello2cam(); } extern unsigned int sf_machine_global_initializer_called(void); static void mdlProcessParameters_c2_modello2cam(SimStruct *S) { int i; for (i=0;i