Why do I receive an error when building code for a processor-in-the-loop (PIL) cosimulation with Embedded Target for Motorola MPC555 2.0 (R14)?

조회 수: 3 (최근 30일)
My model includes a noninlined S-function, for which a TLC file for the S-function is absent. When building code for a processor-in-the-loop (PIL) cosimulation using Embedded Target for Motorola MPC555 2.0 (R14), the following error is returned:
-- Building Subsystem_pil_sf.obj --
C:/matlab7/bin/win32/mex.bat -c -g -DPIL_S_FUNCTION -DS_FUNCTION_NAME#Subsystem_pil_sf -DPIL_S_FUNCTION -I. -I.. -IC:/matlab7/rtw/c/ert -IC:/matlab7/extern/include -IC:/matlab7/simulink/include -IC:/matlab7/rtw/c/src -IC:/matlab7/rtw/c/src/ext_mode/common -IC:/matlab7/toolbox/rtw/targets/common/profile/execution -IC:/matlab7/too
lbox/rtw/targets/mpc555dk/pil -IC:/matlab7/toolbox/rtw/targets/mpc555dk/pil/api/CommAPI/include -Ic:/pcmpc555/leo/matlab_rtw/pil_ss_mpc/simple -Ic:/pcmpc555/leo/matlab_rtw/pil_ss_mpc/simple/subsystem_mpc555pil -Ic:/matlab7/rtw/c/libsrcSubsystem_pil_sf.c
Error Subsystem_pil_sf.c: .\Subsystem.h: 112 invalid struct field declarations
Error Subsystem_pil_sf.c: .\Subsystem.h: 112 syntax error; found `RTWSfcnInfo' expecting `}'
Error Subsystem_pil_sf.c: .\Subsystem.h: 112 skipping `RTWSfcnInfo' `sfcnInfo'
Error Subsystem_pil_sf.c: .\Subsystem.h: 112 undefined size for field `incomplete struct defined at .\Subsystem.h 111'
Error Subsystem_pil_sf.c: .\Subsystem.h: 189 unrecognized declaration
Warning Subsystem_pil_sf.c: .\Subsystem.h: 189 empty declaration
5 errors, 1 warnings
C:\MATLAB7\\BIN\WIN32\MEX.PL: Error: Compile of 'Subsystem_pil_sf.c'
failed.
C:\matlab7\toolbox\rtw\targets\mpc555dk\bin\win32\make.exe: ***
[Subsystem_pil_sf.obj] Error 255
Error using ==> slbuild
Error using ==> RTW.makertw.make_rtw
Error using ==> rtw_c
Error(s) encountered while building model "Subsystem"

채택된 답변

MathWorks Support Team
MathWorks Support Team 2009년 6월 27일
We have verified that there is a bug in Embedded Target for Motorola MPC555 2.0 (R14) in the way that a PIL cosimulation handles a non-inlined S-function.
To work around this issue, use inlined S-functions in your model. Information that explains how to inline an S-function is provided in the Real-Time Workshop 6.0 (R14) documentation, accessed by typing the following at the MATLAB prompt:
web([docroot '/toolbox/rtw/tlc_ref/cp_inlin.html'])

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Embedded Coder Supported Hardware에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by