To bring DDS concepts such as Domains, Topics, Types, and Quality of Service (QoS) into the Simulink® environment so that you can model and configure DDS applications, use the DDS Application Quick Start. The Quick Start enables you to import XML/IDL definitions or create default definitions and configure your application appropriately for its DDS vendor, RTI or eProsima, to provide the framework to model and build your application in Simulink.
To create DDS definitions and configure your application:
When you open a model in the DDS Blockset app, you are directed into the DDS Application Quick Start. The Quick Start enables you to name your application, specify your DDS vendor, and import or create DDS definitions required to configure your DDS application. To update these configuration options after completing the Quick Start, you can reopen the DDS Application Quick Start from the toolstrip by clicking Quick Start.
On the first page of DDS Application Quick Start, specify the DDS application name and vendor.
By default, the name of your DDS application is set to the name of its application model. To customize the name, in the Application name field, enter a customized name.
To specify your DDS vendor (and set your toolchain), from the Vendor drop-down list, select RTI or eProsima. If you do not intend to generate code, vendor selection does not affect simulation, so you can accept the default vendor.
On the second page of the DDS Application Quick Start, specify the source of your DDS definitions for your application. DDS definitions, whether created or imported, are stored in a section of the Simulink data dictionary called the DDS Dictionary. You can create and associate a DDS Dictionary with your application by using one of these options:
Use existing dictionary — If you have an existing DDS Dictionary, you can associate that dictionary with your new DDS application and reuse the definitions. This option is ideal for building applications set to similar requirements or standards.
Import from XML — If you have or would like to specify DDS definitions in XML, you can import XML definitions into a new DDS Dictionary and associate it with your application. XML specifications enable maximum flexibility and control over your definitions.
Create and use default dictionary — If you would like to have a new DDS Dictionary created for you based on your application model, you can select to create and use a default dictionary. This option is the quickest and simplest option to get started.
To wrap-up, click Finish. The Quick Start creates and associates a DDS Dictionary with your application and configures the application so that you can generate an executable specific to RTI or eProsima.
To verify your DDS definitions, you can use the DDS Dictionary or Code Mappings editor. To verify Domain, Topic, Type, or QoS definitions, you can use the DDS Dictionary to view and edit these definitions. For more information, see Manage DDS Definitions.
To verify imported DataReader and DataWriter definitions, use the Code Mappings
editor. To view the readers and writers, open the editor, set the Configuration
Use Reader XML Path or
Writer XML Path and verify that they appear as drop-down list options for
the inports or outports. If you select a reader or writer, you can also verify its Topic
and QoS properties loaded in the editor. For more information, see Interactively Configure DDS Interface.
If your imported definitions are not correct, examine and correct any errors in the imported XML or DDS Dictionary, and then associate the new definitions with your DDS application. To update or change vendor information,on the toolstrip, open the Quick Start and update the vendor.
Multiple XML Files — The Quick Start allows you to import one XML file. To import additional files, use the DDS Dictionary.
IDL File Import — To import IDL specifications, convert IDL to XML and import XML files.
Duplicate Data Imported — Imported XML files pull additional XML files referenced by the include mechanism into the DDS Dictionary. If an XML file is referenced multiple times its definitions are imported each time resulting in duplicates.