MATLAB: What are the Simulink.CustomSignal and Simulink.CustomParameter objects referring to in the documentation for Real-Time Workshop Embedded Coder 4.0 (R14)

classclassescodecsccustomEmbedded Codergenerationrtwstorage

What are the Simulink.CustomSignal and Simulink.CustomParameter objects referring to in the documentation for Real-Time Workshop Embedded Coder 4.0 (R14)?
Specifically, the sections which describe how to update custom storage classes from R13 to R14 discuss these object, but my R13 Custom Storage Classes do not use them.

Best Answer

In R13, these objects were designed to be used for implementing Custom Storage Classes, but the semantics on this were not very clear. The "custom" objects differed from the normal ones by the initial RTWInfo class that was used to contain code generation data:
custom_object = Simulink.CustomParameter
custom_object =
Simulink.CustomParameter
RTWInfo: [1x1 Simulink.CustomParameterRTWInfo]
Description: ''
DocUnits: ''
Value: []
custom_object .RTWInfo
Simulink.CustomParameterRTWInfo
StorageClass: 'Custom'
Alias: ''
CustomAttributes: [1x1 Simulink.SCAttrib_BitField]
CustomStorageClass: 'BitField'
normal_object = Simulink.Parameter
normal_object =
Simulink.Parameter
RTWInfo: [1x1 Simulink.RTWInfo]
Description: ''
DocUnits: ''
Value: []
normal_object.RTWInfo
Simulink.RTWInfo
StorageClass: 'Auto'
Alias: ''
However, the Simulink.Parameter's RTWInfo could be overwritten with the required data structure:
normal_object.RTWInfo = thing.RTWInfo
normal_object =
Simulink.Parameter
RTWInfo: [1x1 Simulink.CustomParameterRTWInfo]
Description: ''
DocUnits: ''
Value: []
The Data Class Designer GUI also enforced the use of Simulink.Parameter initialized to a different RTWInfo structure, so it was difficult to do this in the expected way in R13. If your code does not derive from Simulink.CustomSignal or Simulink.CustomParameter objects, you will not need to change to these classes. However, you should be aware that the RTWInfo parameter is now more tightly controlled, so you should move any data which was formally contained in a custom RTWInfo object into the objects derived from Simulink.Signal or Simulink.Parameter.