getPlatformProperty
Description
gets the specified property for the specified dictionary element from a data dictionary
mapped to the AUTOSAR Classic Platform. The specified dictionary element can be a data
interface object or data element object.propValue
= getPlatformProperty(platformMapping
,dictElementObj
,propName
)
Examples
Get AUTOSAR Interface Property InterfaceKind
To get the kind of AUTOSAR communication interface that is defined
for the specified data interface, use the getPlatformProperty
function with the propName
argument InterfaceKind
.
For an example that shows more of the workflow for related functions, see Configure AUTOSAR Classic Data Interface and Properties in Data Dictionary.
archDataObj = Simulink.dictionary.archdata.open("MyInterfaces.sldd"); platformMapping = getPlatformMapping(archDataObj,"AUTOSARClassic"); interfaceObj = getInterface(archDataObj,"DataInterface"); propValue_Interface = ... getPlatformProperty(platformMapping,interfaceObj,"InterfaceKind")
propValue_Interface = 'NvDataInterface'
Get AUTOSAR Data Element Property SwCalibrationAccess
To get the calibration and measurement tool access defined for the
specified data element, use the getPlatformProperty
function with the
propName
argument SwCalibrationAccess
.
dataElemObj = interfaceObj.Elements(1); propValue_Sw_CalAccess = ... getPlatformProperty(platformMapping,dataElemObj,"SwCalibrationAccess")
propValue_Sw_CalAccess = 'ReadWrite'
Input Arguments
platformMapping
— Platform mapping object
autosar.dictionary.ARClassicPlatformMapping
object
Platform mapping object, specified as an autosar.dictionary.ARClassicPlatformMapping
object.
dictElementObj
— Element in dictionary object
Simulink.dictionary.archdata.DataInterface
object | Simulink.dictionary.archdata.DataElement
object
Element in a dictionary object from which you access the AUTOSAR
platform-specific properties and values, specified as a Simulink.dictionary.archdata.DataInterface
object or
Simulink.dictionary.archdata.DataElement
object.
The argument can be a data interface object, which is returned by a previous
call to addDataInterface
or getInterface
, or a data element object, which is
returned by a previous call to addElement
or getElement
.
propName
— Property name in dictionary element
character vector | string scalar
Property name of property in dictionary element.
For data interface objects, valid argument values are
"IsService"
, "Package"
, and
"InterfaceKind"
.
For data element objects, valid argument values are
"SwAddrMethod"
,
"SwCalibrationAccess"
, and
"DisplayFormat"
.
Example: "InterfaceKind"
Output Arguments
propValue
— Property value of dictionary element
character vector | string scalar
Property value of property in dictionary element.
For data interface objects, returned properties include:
Property | Return Value |
---|---|
IsService | Set as true for service interfaces.
Returned as a Boolean . |
Package | Fully-qualified path to the element
package. Returned as a character
vector . |
InterfaceKind | AUTOSAR communication interface. Returned
as a character vector . Valid
values are
'SenderReceiverInterface' ,
'NvDataInterface' , and
'ModeSwitchInterface' . |
For data element objects, returned properties include:
Property | Return Value |
---|---|
SwAddrMethod | Name of previously defined software address
method. Returned as a character
vector . |
SwCalibrationAccess | Calibration and measurement tool access to
a data object. Returned as a character
vector . Valid values are
'ReadOnly' ,
'ReadWrite' , and
'NotAccessible' . |
DisplayFormat | AUTOSAR display format specification.
Returned as a character
vector . |
Version History
Introduced in R2022b
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)