Documentation Center

  • Trials
  • Product Updates

seupdate

Update models from previous releases

Syntax

seupdate('sys')
seupdate('sys', 0)

Description

seupdate('sys') updates a SimEvents® model that was created in a previous release to the current release.

This function replaces blocks in your model from previous versions of the SimEvents library with their latest version, without changing configured parameter values. If the model has associated custom libraries, the function also updates blocks in those custom libraries. The function inserts gateway blocks where a time-based signal feeds an event-based block, or where an event-based signal feeds a time-based block. If the model is not already open when you run this function, the software opens it to perform the update.

The function overwrites the model it is updating. Before beginning the update, the function completely backs up the model and associated custom libraries. The software stores this backup in a new folder, in the same directory as the model. The new folder uses the naming convention seupdate_for_sys.

When you run the seupdate function, the software provides a summary of the model and libraries it is preparing to update. The software then prompts if you are ready to proceed with the update. Enter one of the following responses:

  • y

    Overwrite the model and associated libraries.

  • n

    Cancel the operation. No changes are made to the model and associated libraries.

  • help

    In the SimEvents documentation, learn how the seupdate function changes your model.

seupdate('sys', 0) updates the model and referenced library components without prompting you.

Input Arguments

sys

Specify the name of the model to update.

Default: None

Examples

expand all

Model Migration Using seupdate

Use the seupdate function to migrate all blocks in a model to the latest version in the SimEvents library.

Run the seupdate function for the model that you want to migrate.

seupdate('ex_signalbasedevents_plots')

Review the items under the heading Before you udpate your model: and enter a value at the prompt.

Update model 'ex_signalbasedevents_plots'? ([y]/n/help):y

The first update step checks your model file format. If either the model or any associated library files are not in the newer SLX file format (that is, they are in the older MDL format), the software prompts you to ask if you want to save the updated model in the newer format. If your model is already in the SLX format, you do not see this prompt.

When you answer the file format prompt, the update process continues.

Review the report that the migration utility generates.

In this example, the model updates successfully.

Migration of Model Containing Queue Blocks Using seupdate

Run the seupdate function for the model that you want to migrate.

seupdate('ex_queue_system')

If your model contains any legacy queue blocks that have the #n output enabled, the seupdate function displays the additional output that is highlighted in the graphic.

Review the information under the heading This model contains SimEvents queue blocks. To check for potential results changes in queue blocks before you migrate your model, first exit the migration process.

Update model 'ex_queue_system'? ([y]/n/help):n

In the command window, enter:

[A] = seupdateutil('ex_queue_system','detectQueueBlockChanges')

The seupdateutil function identifies any legacy queue blocks in your model that have the #n output enabled.

The software analyzes your model and determines which of the listed queue blocks will produce different results when you migrate the model.

When you have assessed the simulation impact of any results changes from queue blocks, rerun seupdate.

Update model 'ex_queue_system'? ([y]/n/help):y

Review the report that the migration utility generates.

In this example, the model updates successfully.

Was this topic helpful?