isLookupTableDataInterface
オブジェクトが coder.descriptor.LookupTableDataInterface オブジェクトかどうか確認する
構文
lookupTableDataInterface = isLookupTableDataInterface(parameterObj)
説明
は、オブジェクトが lookupTableDataInterface = isLookupTableDataInterface(parameterObj)coder.descriptor.LookupTableDataInterface オブジェクトかどうかを示す logical 値を返します。
入力引数
モデルのルックアップ テーブル ブロックを表す coder.descriptor.LookupTableDataInterface オブジェクト。
データ型: string
出力引数
オブジェクトが coder.descriptor.LookupTableDataInterface かどうかを示す logical 値。
データ型: logical
例
この例では、オブジェクトが coder.descriptor.LookupTableDataInterface オブジェクトであるかどうかを判別する方法を説明します。
モデルの作成
ルックアップ テーブル ブロックを含むモデルを開いて、ビルドします。
open_system('ASAP2Demo'); slbuild('ASAP2Demo');
### Searching for referenced models in model 'ASAP2Demo'. ### Total of 2 models to build. ### Starting serial code generation build. ### Successfully updated the model reference code generation target for: ASAP2DemoModelRef ### Starting build procedure for: ASAP2Demo codeInterfacePackaging: Nonreusable function codeInterfacePackaging: NonReusable ### Successful completion of build procedure for: ASAP2Demo Build Summary Model reference code generation targets: Model Build Reason Status Build Duration ============================================================================================================ ASAP2DemoModelRef Target (ASAP2DemoModelRef.c) did not exist. Code generated and compiled. 0h 0m 8.3657s Top model targets: Model Build Reason Status Build Duration ============================================================================================================ ASAP2Demo Information cache folder or artifacts were missing. Code generated and compiled. 0h 0m 18.218s 2 of 2 models built (0 models already up to date) Build duration: 0h 0m 27.924s
ルックアップ テーブルのパラメーターのプロパティを返す
モデルのコード記述子オブジェクトを作成します。
codeDescObj = coder.getCodeDescriptor('ASAP2Demo');ルックアップ テーブルのパラメーターのプロパティを返します。
params = getDataInterfaces(codeDescObj,'Parameters');変数 params は、coder.descriptor.DataInterface オブジェクトと coder.descriptor.LookupTableDataInterface オブジェクトからなる配列です。モデル ASAP2Demo には 3 つのルックアップ テーブル ブロックが含まれています。調整可能なブレークポイント セット データがあるのはそれらのうち 2 つだけです。コード ジェネレーターは、対応する 2 つの coder.descriptor.LookupTableDataInterface オブジェクトのみを作成します。
配列内の 6 番目の位置にアクセスして Standard_Axis ブロックの詳細を取得します。
parameterObj = params(6);
変数 parameterObj に保存されているオブジェクトが coder.descriptor.LookupTableDataInterface オブジェクトかどうかを確認します。
lookupTableDataInterface = isLookupTableDataInterface(parameterObj)
lookupTableDataInterface = logical
1
コード ジェネレーターは、parameterObj が coder.descriptor.LookupTableDataInterface オブジェクトである場合、logical 値 1 を返します。それ以外の場合は、logical 値 0 を返します。
バージョン履歴
R2020a で導入
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.
Web サイトの選択
Web サイトを選択すると、翻訳されたコンテンツにアクセスし、地域のイベントやサービスを確認できます。現在の位置情報に基づき、次のサイトの選択を推奨します:
また、以下のリストから Web サイトを選択することもできます。
最適なサイトパフォーマンスの取得方法
中国のサイト (中国語または英語) を選択することで、最適なサイトパフォーマンスが得られます。その他の国の MathWorks のサイトは、お客様の地域からのアクセスが最適化されていません。
南北アメリカ
- América Latina (Español)
- Canada (English)
- United States (English)
ヨーロッパ
- 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)