@echo off IF [%1]==[] (set params_f1=.\Inu\wrapper_inu_1.c) IF NOT [%1]==[] (set params_f1=.\Inu\%1) echo %params_f1% set params_d1=-D"ML" -D"__IQMATHLIB_H_INCLUDED__" -D"_MATLAB_SIMULATOR" set params_d2=-D"_MATLAB_FAST_SIMULATOR" -D"PROJECT_SHIP=1" set params_i=-I"..\device_support_ml\include"^ -I"."^ -I".\Inu"^ -I".\Inu\Src\main"^ -I".\Inu\Src\N12_VectorControl"^ -I".\Inu\Src\main_matlab"^ -I".\Inu\Src\N12_Libs"^ -I".\Inu\Src\N12_Xilinx" set params_o=-outdir "." set params_f2=.\Inu\controller.c^ .\Inu\Src\main_matlab\IQmathLib_matlab.c^ .\Inu\Src\main_matlab\main_matlab.c^ .\Inu\Src\main_matlab\errors_matlab.c^ .\Inu\Src\main_matlab\adc_tools_matlab.c^ .\Inu\Src\main\v_pwm24_v2.c^ .\Inu\Src\N12_Libs\mathlib.c^ .\Inu\Src\N12_Libs\filter_v1.c^ .\Inu\Src\N12_Libs\pid_reg3.c^ .\Inu\Src\N12_Libs\rmp_cntl_v1.c^ .\Inu\Src\N12_Libs\svgen_dq_v2.c^ .\Inu\Src\N12_Libs\svgen_mf.c^ .\Inu\Src\N12_Libs\uf_alg_ing.c^ .\Inu\Src\N12_Xilinx\xp_write_xpwm_time.c^ .\Inu\Src\N12_Libs\global_time.c^ .\Inu\Src\N12_VectorControl\vector_control.c^ .\Inu\Src\N12_VectorControl\abc_to_dq.c^ .\Inu\Src\N12_VectorControl\regul_power.c^ .\Inu\Src\N12_VectorControl\regul_turns.c^ .\Inu\Src\N12_VectorControl\teta_calc.c^ .\Inu\Src\N12_VectorControl\dq_to_alphabeta_cos.c set params_f3=.\Inu\Src\N12_Libs\modbus_table.c^ .\Inu\Src\main\detect_overload.c^ .\Inu\Src\N12_VectorControl\filter_analog.c^ .\Inu\Src\N12_VectorControl\filter_bat2.c^ .\Inu\Src\main\PWMTools.c set params_obj=..\device_support_ml\source\C28x_FPU_FastRTS.obj ..\device_support_ml\source\DSP2833x_GlobalVariableDefs.obj echo mex %params_d1% %params_d2% %params_i% %params_o% %params_f1% %params_f2% %params_obj% -g mex %params_d1% %params_d2% %params_i% %params_o% %params_f1% %params_f2% %params_obj% -g