LabVIEW Control Design and Simulation Module

EMI_CB_ModelInterface (EMI Function)

  • Updated2023-03-14
  • 1 minute(s) read

EMI_CB_ModelInterface (EMI Function)

Owning Class: Callbacks

Requires: Control Design and Simulation Module

Prototype

void EMI_CB_ModelInterface(emiRef model);

Description

Defines and allocates the parts of an external model, such as the model name, inputs, outputs, and parameters. You must define and export this function for each model you create.

Details

Examples

Inputs

Name Description
model Specifies a reference to the external model. Use this reference as an input to other EMI functions. Do not modify model directly.

Details

Call any of the functions in the Related Topics list from within the EMI_CB_ModelInterface function to specify the parts of the model you want to define and allocate. Call the EMI_GetConfigurationParams function if the user must specify one or more model configuration parameters to define the model.

Examples

void EMI_CB_ModelInterface(emiRef model) {
   EMI_SetModelName(model, "My Example");
   EMI_AddScalarInput(model, "First Input");
   EMI_AddVectorInput(model, "Second Input", 3);
   EMI_AddScalarOutput(model, "First Output", EMI_Feedthrough_Direct);
}

Related Topics

EMI_AddMenuItem
EMI_AddScalarInput
EMI_AddScalarOutput
EMI_AddScalarParam
EMI_AddVectorInput
EMI_AddVectorOutput
EMI_AddVectorParam
EMI_GetConfigurationParams
EMI_SetModelName

Log in to get a better experience