Why do I receive fatal error: could not open source file "stddef.h"when building my model using idelink_ert.tlc for TI F28335 DSP

4 ビュー (過去 30 日間)
fxg
fxg 2018 年 3 月 30 日
編集済み: fxg 2018 年 3 月 30 日
Elapsed: 10 sec ### Generating code into build folder: G:\dsp\F28335_ticcs ### Invoking Target Language Compiler on F28335.rtw ### Using System Target File: E:\Program Files (x86)\MAT\toolbox\idelink\foundation\pjtgenerator\rtw\idelink_ert.tlc ### Loading TLC function libraries Warning: The data type "int8" uses a word size that is not available on the intended target. Fixed-point signals using this data type will be put inside a larger word or multi words. When used, extra software will be generated to force this larger word or multi words to emulate a smaller word. This emulation is helpful when your prototype target and your final production target are not the same. If the smaller word size does NOT exist on the final production target, then consider increasing the word size to one that is supported. Warning: The data type "uint8" uses a word size that is not available on the intended target. . Warning: The data type "boolean" uses a word size that is not available on the intended target. . ### Initial pass through model to cache user defined code . ### Caching model source code ### Writing header file F28335.h . ### Writing header file F28335_types.h ### Writing header file rtwtypes.h ### Writing source file F28335.c ### Writing header file F28335_private.h . ### Writing source file F28335_data.c ### Writing source file F28335_main.c ### TLC code generation complete. ..### Creating HTML report file F28335_codegen_rpt.html ### Creating makefile: G:\dsp\F28335_ticcs\F28335.mk ### Makefile creation done. ### Building makefile... The call to idelink_ert_make_rtw_hook, during the exit hook generated the following error: Error while building the project.
The build process will terminate as a result. Caused by: Error while building the project. The build failed with the following message: "C:/ti/ccsv6/tools/compiler/ti-cgt-c2000-5.2.15/bin/cl2000.exe" -I"C:/MATLAB/SupportPackages/R2016a/toolbox/target/supportpackages/tic2000/inc" -I"E:/Program Files (x86)/MAT/simulink/include/sf_runtime" -I"G:/dsp/F28335_ticcs" -I"G:/dsp" -I"E:/Program Files (x86)/MAT/extern/include" -I"E:/Program Files (x86)/MAT/simulink/include" -I"E:/Program Files (x86)/MAT/rtw/c/src" -I"E:/Program Files (x86)/MAT/rtw/c/src/ext_mode/common" -I"E:/Program Files (x86)/MAT/rtw/c/ert" -D"__TICCSC__" -D"RT" -D"USE_RTMODEL" -ml -v28 --float_support=fpu32 -D"MODEL=F28335" -D"NUMST=1" -D"NCSTATES=0" -D"HAVESTDIO=" -D"ONESTEPFCN=1" -D"TERMFCN=1" -D"MAT_FILE=0" -D"MULTI_INSTANCE_CODE=0" -D"INTEGER_CODE=0" -D"MT=0" -D"CLASSIC_INTERFACE=0" -D"ALLOCATIONFCN=0" -D"TID01EQ=0" -I"include" -fr"./derived/" ./DSP2833x_ADC_cal.asm ./DSP2833x_CodeStartBranch.asm ./DSP2833x_CpuTimers.c ./DSP2833x_DMA.c ./DSP2833x_DefaultIsr.c ./DSP2833x_GlobalVariableDefs.c ./DSP2833x_PieCtrl.c ./DSP2833x_PieVect.c ./DSP2833x_SysCtrl.c ./DSP2833x_usDelay.asm ./F28335.c ./F28335_data.c ./F28335_main.c ./MW_c28xx_board.c ./MW_c28xx_csl.c [DSP2833x_ADC_cal.asm] [DSP2833x_CodeStartBranch.asm] [DSP2833x_CpuTimers.c] [DSP2833x_DMA.c] [DSP2833x_DefaultIsr.c] [DSP2833x_GlobalVariableDefs.c] [DSP2833x_PieCtrl.c] [DSP2833x_PieVect.c] [DSP2833x_SysCtrl.c] [DSP2833x_usDelay.asm] [F28335.c] ".\F28335.h", line 18: fatal error: could not open source file "stddef.h" 1 fatal error detected in the compilation of "./F28335.c". Compilation terminated.
>> Compilation failure gmake: * [derived/DSP2833x_ADC_cal.obj] Error 1
As a result: File: F28335_main.c
1 /* 2 * File: F28335_main.c 3 4 * Code generated for Simulink model 'F28335'. 5 * 6 * Model version : 1.9 7 * Simulink Coder version : 8.10 (R2016a) 10-Feb-2016 8 * C/C++ source code generated on : Fri Mar 30 12:41:18 2018 9 * 10 * Target selection: idelink_ert.tlc 11 * Embedded hardware selection: Texas Instruments->C2000 12 * Code generation objectives: Unspecified 13 * Validation result: Not run 14 */ 15 16 #include "F28335.h" 17 #include "rtwtypes.h" 18 #include "F28335_private.h" 19 #include "c2000_main.h" 20 #include "DSP2833x_Device.h" 21 #include "DSP2833x_Examples.h" 22 #include stdlib.h 23 #include stdio.h 24 25 void init_board(void); 26 void enable_interrupts(void); 27 void config_schedulerTimer(void); 28 void disable_interrupts(void); 29 volatile int IsrOverrun = 0; 30 static boolean_T OverrunFlag = 0; 31 32 / Function: rt_OneStep ------------------------------------------- 33 34 * Abstract: 35 * Perform one step of the model. Single-tasking implementation. 36 */ 37 void rt_OneStep(void) 38 { 39 / Check for overrun. Protect OverrunFlag against 40 * preemption. 41 / 42 if (OverrunFlag++) { 43 IsrOverrun = 1; 44 OverrunFlag--; 45 return; 46 } 47 48 asm(" SETC INTM"); 49 PieCtrlRegs.PIEIER1.all |= (1 << 6); 50 asm(" CLRC INTM"); 51 F28335_step(); 52 53 / Get model outputs here / 54 asm(" SETC INTM"); 55 PieCtrlRegs.PIEIER1.all &= ~(1 << 6); 56 asm(" RPT #5 NOP"); 57 IFR &= 0xFFFE; 58 PieCtrlRegs.PIEACK.all = 0x1; 59 asm(" CLRC INTM"); 60 OverrunFlag--; 61 } 62 63 / Function: main ------------------------------------------- 64 65 * Abstract: 66 * Entry point into the code. 67 */ 68 void main(void) 69 { 70 volatile boolean_T noErr; 71 init_board(); 72 rtmSetErrorStatus(F28335_M, 0); 73 F28335_initialize(); 74 config_schedulerTimer(); 75 noErr = 76 rtmGetErrorStatus(F28335_M) == (NULL); 77 enable_interrupts(); 78 while (noErr ) { 79 noErr = 80 rtmGetErrorStatus(F28335_M) == (NULL); 81 } 82 83 / Disable rt_OneStep() here / 84 85 / Terminate model / 86 F28335_terminate(); 87 disable_interrupts(); 88 } 89 90 / 91 * File trailer for generated code. 92 * 93 * [EOF] 94 */ 95

回答 (0 件)

カテゴリ

Help Center および File Exchange代码生成 についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!