I am upgrading from R2009a to R2012a. In R2009a, I use Simulink.AliasTypes with DataScope='Auto' and HeaderFile='myheader.h". I am using shared code placement (UtilityFuncGeneration='Shared'). I am also using data type replacement (EnableUserReplacementTypes='on' with the proper fields filled in). During RTW code generation, all works fine, and "myheader.h" is included in _sharedutils/rtwtypes.h.
In R2012a, with the same settings, I get the error:
Error using rtwbuild (line 240)
Error: Error occurred when generating shared data declaration: The data types for the following shared data does not exist in the current slprj directory:
The data type 'F32' of data [my signals] is not shared
The data type 'U8' of data [my signals] is not shared
To continue, set these data types to be shared
I have tried every combination of DataScope and HeaderFile, but all give errors.
Interestingly, "myheader.h" is still included in the _sharedutils/rtwtypes.h file though.
Any idea what has changed and how to rectify this?
Pete
Best Answer