Settings Tab
The Settings tab can appear in two variants:
For AUTOSAR Interfaces
The Settings tab for AUTOSAR interfaces contains the following elements:
Interface represents an AUTOSAR service
If this option is activated, ASCET sets the IS-SERIVCE element to true in the generated ARXML code (i.e. <IS-SERVICE>true</IS-SERVICE>). This tells an AUTOSAR RTE generator that the interface is to be used for communication between an application software component and a service component (e.g. an AUTOSAR service, ECU abstraction or complex driver) located on the same ECU.
Note |
|---|
For communication between application software components, this option must be deactivated. |
AUTOSAR package name field
Allows to determine an AUTOSAR package name for the interface. The AUTOSAR package name must be of the following form:
/<package>/<subpackage>[/<interface>]
At least /<package>/<subpackage> must be given; if not, an error is issued during code generation.
The semantic of the give package name is as follows:
- If the name is empty, the general template for the associated interface kind, specified in the Target Settings window, will apply. See also Configuring the AUTOSAR XML Output.
- If the name is not empty, and of the proper form, it will be used as the package name (this includes the short-name) of the associated AUTOSAR interface.
Note |
|---|
The given name must not contain any template parameter (i.e. %...%), but is taken as is. |
Interface is defined externally
If this option is activated, the interface is defined externally and will not be generated by ASCET, only referred to.
Note |
|---|
If Interface is defined externally is activated, the "AUTOSAR package name" field must not be empty. If it is, an error (MMdl6490) is issued during code generation. |
"AUTOSAR Data Type Mapping Set" field
Allows to determine a data type mapping set that will be added to the software component for data types used in an external interface.
If the name is empty, the general template specified in the "ARXML Configuration Settings" window, will apply. See Configuring the AUTOSAR XML Output for details.
For Other Components
The Settings tab for other components than AUTOSAR interfaces contains the following elements:
Memory Location of Instance
Used to select the memory area in which the component is located. Possible values depend on the target selected in the associated project or default project and – in case of a referenced component – the internal access settings of the explicit reference.
Memory Segment
In a project context with an ASCET‑SE target, this combo box is used to select a memory segment. See the ASCET‑SE user guide, chapter "Memory Segments", for more information.
Hierarchical Code Generation for State Machines
Only available for state machines. See Hierarchical Code Generation for details.
Outline Automatically Generated Methods for State Machines
Only available for state machines. See Actions or Conditions for details.
Auto-Inline Private Methods (Smaller Code Size)
Only available for state machines. See Optimizing the State Machine for details.
Generate Data Structures
If activated, the code generation generates definitions, declarations and initialization of a component implementation.
Generate Method Body
Only available for classes. If activated, code is generated for the class.
Service Routine
If this option is activated, and if the target optionGenerate Method Body is set to Use Component Settings, the class is generated as service routine, i.e., only the class interfaces are generated by ASCET, but no method body.
This option can be effective only if you selected the code generator Implementation Experiment (experimental targets) or Object Based Controller Implementation (ASCET‑SE targets) in the Build node of the project properties window. The Production code only option determines if the option affects both code generators or only Object Based Controller Implementation.
See the ASCET‑SE user guide for details.
Prototype Implementation
If this option is activated, and if the target optionGenerate Method Body is set to Use Component Settings, the class is generated as service routine, i.e., only the class interfaces are generated by ASCET, but no method body. However, ASCET still offers the possibility to specify method contents as they could be needed in simulation experiments executed in ASCET.
This option can be effective only if you selected the code generator Implementation Experiment or Object Based Controller Implementation in the Build node of the project properties window. The Production code only option determines if the option affects both code generators or only Object Based Controller Implementation.
See the ASCET‑SE user guide for details.
Note |
|---|
Generate Method Body, Service Routine and Prototype Implementation are mutually exclusive. If the target optionGenerate Method Body is set to Yes for All Components, an activation of Service Routine or Prototype Implementation in the component implementation editor is ignored and Generate Method Body is used instead. |
Production code only
If this option is activated, the Service Routine or Prototype Implementation option is effective only for the Object Based Controller Implementation code generator.
If this option is deactivated, the Service Routine or Prototype Implementation option is effective for the Object Based Controller Implementation and the Implementation Experiment code generator.
Note |
|---|
If Production code only is activated, the class can be exported as AMD/AXL file only in AML V6.4.0 format or higher. |
Code generation for experimental targets ignores this option.
Optimize method calls
Note |
|---|
Only available if Generate Method Body is activated. |
If the option is activated, and if the target optionForce no self pointer optimization is deactivated, the following happens:
- If a class has a single instance in the project, the class instance data are placed in the C code file of the class.
- If a class has multiple instances in the project, the class instance data are placed in the source files of each instance's parent component.
If the option is deactivated, or if the target option Force no self pointer optimization is activated, the following happens:
- If a class has a single instance in the project, the class instance data are placed in the C code file of the parent component.
- If a class has multiple instances in the project, the class instance data are placed in the source files of each instance's parent component.
Additional Header Includes field
Note |
|---|
Only available if either Service Routine or Prototype Implementation is activated. |
Allows to determine a semicolon(;)-separated list of additional header files. These header files will then be included in the service routine or prototype component. If you enter header files with identical names, only one include is generated.
The placement of the includes depends on the Header/C Code Structure selected in the parent project:
Header/C Code Structure | Position of includes |
|---|---|
Component | at the top of the component header file for the service routine/prototype |
Project * | at the top of the project header file |