Main Content

systemcomposer.createModel

Create System Composer model

    Description

    model = systemcomposer.createModel(modelName,FileType=fileType) creates a System Composer™ model or subsystem with name modelName and returns the systemcomposer.arch.Model object.

    example

    model = systemcomposer.createModel(modelName,modelType,FileType=fileType) creates a System Composer model or subsystem with name modelName and type modelType and returns the systemcomposer.arch.Model object.

    Examples

    collapse all

    Create a model and display its properties.

    model = systemcomposer.createModel("model_name")
    model = 
    
      model with properties:
    
                       Name: 'model_name'
               Architecture: [1×1 systemcomposer.arch.Architecture]
             SimulinkHandle: 2.0005
                      Views: [0×0 systemcomposer.view.ViewArchitecture]
                   Profiles: [0×0 systemcomposer.profile.Profile]
        InterfaceDictionary: [1×1 systemcomposer.interface.Dictionary]

    Input Arguments

    collapse all

    Name of new model or subsystem, specified as a character vector or string. This name must be a valid MATLAB® identifier.

    Example: "model_name"

    Data Types: char | string

    Type of model or subsystem to create, specified as "Architecture" for an architecture, "SoftwareArchitecture" for a software architecture, or "AutosarArchitecture" for an AUTOSAR architecture.

    Data Types: char | string

    Type of file to create, specified as "Model" for an architecture model or "Subsystem" for an architecture subsystem.

    Data Types: char | string

    Output Arguments

    collapse all

    Architecture model, returned as a systemcomposer.arch.Model object.

    More About

    collapse all

    Version History

    Introduced in R2019a

    expand all