Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Error building Real-Time Workshop target

361 views
Skip to first unread message

LN

unread,
Jul 27, 2012, 3:49:13 AM7/27/12
to
I am trying to to build, compile and write a simulink model named P5_DTC3 in DSpace DS1104 hardware platform. I am using MATLAB R2008b and this is showing this error. I am pretty sure there isn't an issue with the version of MATLAB used because the same DS1104 has worked with other simulink models. Is there a configuration issue or is it something to do with the simulink model ? Thanks in advance.


----------------------------------------------------------------------
Starting build procedure with RTI 6.2 (RTI1104, 14-Nov-2008)
Model: "p5_DTC3" (C:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3\p5_DTC3.mdl)
----------------------------------------------------------------------
*** Using configuration set : "Configuration"
*** Working directory : "C:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3"
*** Initializing code generation
### Starting Real-Time Workshop build procedure for model: p5_DTC3
### Generating code into build directory: C:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3\p5_DTC3_rti1104
Warning: Matching "From" for "Goto" 'p5_DTC3/Estimated Motor Model/Goto' not found.
*** Optional User System Description File p5_dtc3_usr.sdf not available
### Invoking Target Language Compiler on p5_DTC3.rtw
tlc
-r
C:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3\p5_DTC3_rti1104\p5_DTC3.rtw
C:\dSPACE\matlab\rti1104\tlc\rti1104.tlc
-OC:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3\p5_DTC3_rti1104
-IC:\dSPACE\matlab\rti1104\tlc
-IC:\dSPACE\matlab\rti1104\tlc
-IC:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3\p5_DTC3_rti1104\tlc
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\mw
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\lib
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\blocks
-IC:\Program Files\MATLAB\R2008b\rtw\c\tlc\fixpt
-IC:\Program Files\MATLAB\R2008b\stateflow\c\tlc
-aEnforceIntegerDowncast=1
-aFoldNonRolledExpr=1
-aInlineInvariantSignals=0
-aInlineParameters=0
-aLocalBlockOutputs=1
-aRollThreshold=5
-aZeroInternalMemoryAtStartup=1
-aZeroExternalMemoryAtStartup=1
-aInitFltsAndDblsToZero=0
-aForceBlockIOInitOptimize=0
-aGenerateReport=0
-aGenCodeOnly=0
-aRTWVerbose=1
-aIncludeHyperlinkInReport=0
-aLaunchReport=0
-aGenerateTraceInfo=0
-aForceParamTrailComments=0
-aGenerateComments=1
-aIgnoreCustomStorageClasses=1
-aIncHierarchyInIds=0
-aMaxRTWIdLen=31
-aShowEliminatedStatements=0
-aIncDataTypeInIds=0
-aInsertBlockDesc=0
-aIgnoreTestpoints=0
-aSimulinkBlockComments=1
-aInlinedPrmAccess="Literals"
-aTargetFcnLib="ansi_tfl_table_tmw.mat"
-aIsPILTarget=0
-aLogVarNameModifier="rt_"
-aGenerateFullHeader=1
-aExtMode=0
-aExtModeStaticAlloc=0
-aExtModeTesting=0
-aExtModeStaticAllocSize=1000000
-aExtModeTransport=0
-aRTWCAPISignals=0
-aRTWCAPIParams=0
-aGenerateASAP2=0
-aInitialSimState="RUN"
-aExecutionMode="real-time"
-aExecutionModeNonUI="RTSIM"
-aTimeScaleFactor="1.0"
-aTimeScaleFactorNonUI="OPTION_DISABLED"
-aAssertionMode="OFF"
-aTAStimulusEngineEnable=0
-aCCompilerCommonOpts=""
-aCCompilerOptimizationOptsPopup_="Default"
-aCCompilerEffectiveOptimizationOpts="-Ot -Oi -Or -Ox -D_INLINE"
-aCCompilerOptimizationOpts=""
-aCCompilerOptimizationOptsNonUI="USE_DEFAULT"
-aLoadAfterBuild=1
-aLoadToFlash=0
-aLoadApplNonUI="ON"
-aPlatformSelectionPopup="Auto"
-aBoardName=""
-aBoardNameNonUI="OPTION_DISABLED"
-aTRCMaskParameters=0
-aTRCGenerateLabels=1
-aTRCGenerateVirtualBlocks=1
-aTRCGenerateStates=0
-aTRCGenerateDerivatives=0
-aTRCApplySubsystemPermissions=0
-aTRCGenerateParamValues=0
-aTRCIsOmitVdOn=0
-aGenerateTraceInfo=0
-aIgnoreTestpoints=0
-p10000

.

### Loading TLC function libraries

....
### Initial pass through model to cache user defined code
.....
*** Postprocessing RTI blocks
*** Starting I/O block checking

*** RTI Build: Invoking TLCCheck:
+ rti1104check()... passed.
*** Passed I/O block checking
.
### Caching model source code
.....................................................
### Writing header file p5_DTC3_types.h
### Writing header file p5_DTC3.h
.
### Writing source file p5_DTC3.c
### Writing header file rt_zcfcn.h
### Writing source file rt_zcfcn.c
### Writing header file rt_SATURATE.h
.
### Writing header file p5_DTC3_private.h
### Writing header file rtmodel.h
### Writing source file p5_DTC3_data.c
### Writing header file rt_nonfinite.h
.
### Writing source file rt_nonfinite.c
### Writing header file rtGetInf.h
### Writing source file rtGetInf.c
.
### Writing header file rtGetNaN.h
### Writing source file rtGetNaN.c
### TLC code generation complete.
### Generating TLC interface API.
..................................
*** Generating file p5_DTC3_rti.c
.
*** Generating file p5_DTC3_rti.mk
*** Generating Variable Description File p5_DTC3.trc

-------------------------------------------------------------------------------
NOTE: The following option in the Configuration Parameters dialog has been
used:

Optimization:
"Conditional input branch execution" On

This leads to code optimization in which blocks are not computed if their
outputs are not required in the simulation step, for example, if their
output values are used as input for a Switch block and the Switch
currently routes another signal. When the corresponding output signals
are displayed in ControlDesk, their values are static.

To ensure that the blocks are computed, turn off the
"Conditional input branch execution" option and rebuild the model.
-------------------------------------------------------------------------------

-------------------------------------------------------------------------------
NOTE: The following options in the Configuration Parameters dialog have been used:

Optimization:
"Signal storage reuse" on
"Reuse block outputs" on

As a consequence, in general no block output variables are written to the
-> p5_DTC3.trc
file and are therefore not accessible from within ControlDesk.

You can ensure that a specific block output is accessible by declaring
its Simulink signal as a test point. To do so, select the signal line and
choose "Signal properties..." from the Edit menu. In the Signal Properties
dialog, select the "Test point" option.
-------------------------------------------------------------------------------
........
*** Found User-Code File p5_DTC3_usr.c from 27-Jul-2012 02:14:01
*** Found User Makefile p5_DTC3_usr.mk from 27-Jul-2012 02:14:01
*** Optional User Variable Description File p5_DTC3_usr.trc not available
.
### Processing Template Makefile: C:\dSPACE\matlab\rti1104\m\rti1104.tmf
### p5_DTC3.mk which is generated from C:\dSPACE\matlab\rti1104\m\rti1104.tmf is up to date
### Building p5_DTC3: dsmake -f p5_DTC3.mk GENERATE_REPORT=0 EXTMODE_STATIC_ALLOC=0 TMW_EXTMODE_TESTING=0 EXTMODE_STATIC_ALLOC_SIZE=1000000 EXTMODE_TRANSPORT=0

BUILDING APPLICATION "p5_DTC3" (Single Timer Task Mode)

WORK DIRECTORY "C:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3"
BUILD DIRECTORY "C:\Documents and Settings\sriva079\Desktop\RA\DTC-1\DTC-2\DTC-3\p5_DTC3_rti1104"
TARGET COMPILER "C:\PPCTools33"

COMPILING "p5_DTC3.c"
COMPILING "p5_DTC3_data.c"
COMPILING "p5_DTC3_trc_ptr.c"
COMPILING "rtGetInf.c"
COMPILING "rtGetNaN.c"
COMPILING "rt_nonfinite.c"
COMPILING "rt_zcfcn.c"
COMPILING "C:\dSPACE\MATLAB\RTI1104\C\rti_sim_engine.c"

LINKING APPLICATION ...
LINKING FINISHED

LOADING APPLICATION "p5_DTC3.sdf" ...
[#1] ds1104 - RTI: Initializing ... (720)
[#2] ds1104 - RTLIB: dSPACE slave-DSP firmware rev. 3.5 detected. (500)
[#3] ds1104 - RTI: Initialization completed (721)
[#4] ds1104 - RTI: Simulation state: RUN (700)
[#5] ds1104 - RTI: Task Overrun: Program cannot be executed in real-time. (12)
[#6] ds1104 - RTI: Task Overrun: Occurred in task "Timer Task 1", execution step 2. (502)
[#7] ds1104 - RTI: Simulation state: STOP (702)
LOADING FAILED (2): Program has set an error message.

MAKE PROCESS ABORTED

----------------------------------------------------------------------
Error using ==> genMakefileAndBuild at 1139
*** Make process failed while compiling, linking, or loading
*** Detailed error messages are printed in the MATLAB Command Window
*** Aborted RTI build procedure for model p5_DTC3
----------------------------------------------------------------------
*** Stopped RTI build procedure for model: p5_DTC3.
----------------------------------------------------------------------

Pankaj

unread,
Jul 29, 2012, 3:01:26 AM7/29/12
to
Hi,
Seems like your model is compiling but just not loading to ds1104 in the CD.
Try removig the option of automatic loading from Matlab and load the compiled code explicitly in the CD.

You can also look in the configuration parameters and check only those boxes which are required for real time code generation in the simulation parameters.


"LN " <lnaca...@gmail.com> wrote in message <juth5p$v9$1...@newscl01ah.mathworks.com>...

LN

unread,
Jul 30, 2012, 3:27:45 PM7/30/12
to
Hi
I reduced the time step and there is no error showing up.
Reduced it from 10KHz to 9.9KHz and works fine. Any idea why ?
Thank you in advance.


"Pankaj" wrote in message <jv2n46$nvg$1...@newscl01ah.mathworks.com>...
0 new messages