Main Content

View or Edit Parameter Values in Parameter Set on Development Computer

To view or edit parameters in a parameter set, use the ParameterSet object workflow by importing a previously saved parameter set file to the development computer.

By using the ParameterSet object workflow, you can view, edit, and re-use parameter sets.

  1. Build the model and load the real-time application.

    openExample('slrealtime/SlrtSaveCurrentSetOfRealTimeApplicatioParametersExample');
    model = 'slrt_ex_osc_outport';
    slbuild(model);
    tg = slrealtime('TargetPC1');
    load(tg,model);
  2. Save the parameter set to a file on the target computer.

    paramSetName = 'outportTypes';
    saveParamSet(tg,paramSetName);
  3. Import the parameter set into a ParameterSet object on the development computer.

    myParamSet = importParamSet(tg,paramSetName);
  4. Open the ParameterSet in the Simulink Real-Time Parameter Explorer UI. In the explorer, you can view and edit the parameter values in the object.

    explorer(myParamSet);
  5. After tuning the parameters, export the modified parameter set to the target computer and load the parameters into the real-time application.

    exportParamSet(tg,myParamSet);
    loadParamSet(tg,myParamSet.filename);

For more information, see Save and Reload Parameters by Using the MATLAB Language.