getPlatformProperties
説明
[
は、指定されたディクショナリ要素について、AUTOSAR Classic Platform 固有のプロパティとその値を返します。データ インターフェイス オブジェクトまたはデータ要素オブジェクトをディクショナリ要素として指定できます。propNames
,propVals
] = getPlatformProperties(platformMapping
,dictElementObj
)
例
AUTOSAR データ インターフェイスのプロパティの取得
指定したデータ インターフェイスに対して定義されている AUTOSAR 通信インターフェイスの種類や要素パッケージのパスなど、データ インターフェイスについてのプラットフォーム固有のプロパティを取得するには、関数 getPlatformProperties
を使用します。関連する関数のワークフローを示す詳細な例については、データ ディクショナリでの AUTOSAR Classic のデータ インターフェイスとプロパティの構成を参照してください。
archDataObj = Simulink.dictionary.archdata.open("MyInterfaces.sldd"); platformMapping = getPlatformMapping(archDataObj,"AUTOSARClassic"); interfaceObj = getInterface(archDataObj,"DataInterface"); [propNames,propValues] = ... getPlatformProperties(platformMapping,interfaceObj)
propNames = 1×3 cell array {'IsService'} {'Package'} {'InterfaceKind'} propValues = 1×3 cell array {[0]} {'/Interfaces'} {'SenderReceiverInterface'}
AUTOSAR データ要素のプロパティの取得
指定したデータ要素に対する SwAddrMethod の情報など、データ インターフェイス内のデータ要素についてのプラットフォーム固有のプロパティを取得するには、関数 getPlatformProperties
を使用します。関連する関数のワークフローを示す詳細な例については、データ ディクショナリでの AUTOSAR Classic のデータ インターフェイスとプロパティの構成を参照してください。
archDataObj = Simulink.dictionary.archdata.open("MyInterfaces.sldd"); platformMapping = getPlatformMapping(archDataObj,"AUTOSARClassic"); interfaceObj = getInterface(archDataObj,"DataInterface"); dataElementObj = getElement(interfaceObj,"DE1"); [propNames,propValues] = ... getPlatformProperties(platformMapping,dataElementObj)
propNames = 1×3 cell array {'SwAddrMethod'} {'SwCalibrationAccess'} {'DisplayFormat'} propValues = 1×3 cell array {'VAR1'} {'ReadWrite'} {'%.3f'}
入力引数
platformMapping
— プラットフォーム マッピング オブジェクト
autosar.dictionary.ARClassicPlatformMapping
オブジェクト
プラットフォーム マッピング オブジェクト。autosar.dictionary.ARClassicPlatformMapping
オブジェクトとして指定します。
dictElementObj
— ディクショナリ オブジェクト内の要素
Simulink.dictionary.archdata.DataInterface
オブジェクト | Simulink.dictionary.archdata.DataElement
オブジェクト
AUTOSAR プラットフォーム固有のプロパティと値にアクセスするディクショナリ オブジェクト内の要素。Simulink.dictionary.archdata.DataInterface
オブジェクトまたは Simulink.dictionary.archdata.DataElement
オブジェクトとして指定します。
この引数は、addDataInterface
または getInterface
の以前の呼び出しで返されたデータ インターフェイス オブジェクト、あるいは addElement
または getElement
の以前の呼び出しで返されたデータ要素オブジェクトにすることができます。
出力引数
propNames
— プロパティの名前
文字ベクトルの cell 配列 | string 配列
選択したディクショナリ要素およびプラットフォーム マッピングのプロパティの名前。文字ベクトルの cell 配列または string 配列として指定します。
データ インターフェイス オブジェクトの場合、AUTOSAR のプロパティには 'IsService'
、'Package'
、'InterfaceKind'
が含まれます。
データ要素オブジェクトの場合、AUTOSAR のプロパティには 'SwAddrMethod'
、'SwCalibrationAccess'
、'DisplayFormat'
が含まれます。
propVals
— プロパティの値
文字ベクトルの cell 配列 | string 配列
選択したディクショナリ要素およびプラットフォーム マッピングのプロパティの値。文字ベクトルの cell 配列または string 配列として指定します。
データ インターフェイス オブジェクトの場合、返されるプロパティには以下が含まれます。
プロパティ | 戻り値 |
---|---|
IsService | サービス インターフェイスの場合に true に設定。Boolean として返されます。 |
Package | 要素パッケージの完全修飾パス。character vector として返されます。 |
InterfaceKind | AUTOSAR 通信インターフェイス。character vector として返されます。有効な値は "SenderReceiverInterface" 、"NvDataInterface" 、"ModeSwitchInterface" です。 |
データ要素オブジェクトの場合、返されるプロパティには以下が含まれます。
プロパティ | 戻り値 |
---|---|
SwAddrMethod | 以前に定義されたソフトウェア アドレス メソッドの名前。character vector として返されます。 |
SwCalibrationAccess | データ オブジェクトに対するキャリブレーション ツールおよび測定ツールのアクセス。character vector として返されます。有効な値は "ReadOnly" 、"ReadWrite" 、"NotAccessible" です。 |
DisplayFormat | AUTOSAR の表示形式仕様。character vector として返されます。 |
バージョン履歴
R2022b で導入
MATLAB コマンド
次の MATLAB コマンドに対応するリンクがクリックされました。
コマンドを MATLAB コマンド ウィンドウに入力して実行してください。Web ブラウザーは MATLAB コマンドをサポートしていません。
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)