Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
slref.pdf
Скачиваний:
39
Добавлен:
26.03.2015
Размер:
16.01 Mб
Скачать

Common Block Parameters

Common Block Parameters (Continued)

 

Parameter

Description

Values

 

 

StatePerturbation-

State perturbation size to

string

 

 

ForJacobian

use during linearization.

 

 

 

 

See “Perturbation Level of

 

 

 

 

Blocks Perturbed During

 

 

 

 

Linearization” in the Simulink

 

 

 

 

Control Design documentation

 

 

 

 

for details.

 

 

 

StaticLinkStatus

Link status of block. Does not

{'none'} | 'resolved' |

 

 

 

update out-of-date reference

'unresolved' | 'implicit'

 

 

 

blocks when queried using

| 'inactive' | 'restore'

 

 

 

get_param.

| 'propagate'

 

 

StopFcn

Function called at the

MATLAB expression

 

 

 

termination of a simulation.

 

 

 

Tag

Text that appears in the block

string {''}

 

 

 

label that Simulink software

 

 

 

 

generates. Set by the Tag field

 

 

 

 

on the General pane of the

 

 

 

 

Block Properties dialog box.

 

 

 

Type

Simulink object type (read

'block'

 

 

 

only).

 

 

 

UndoDeleteFcn

Function called when block

MATLAB expression

 

 

 

deletion is undone.

 

 

 

UserData

User-specified data that can

{'[]'}

 

 

 

have any MATLAB data type.

 

 

 

UserDataPersistent

Status of whether or not

'on' | {'off'}

 

 

 

UserData will be saved in the

 

 

 

 

model file.

 

 

Examples of Setting Block Parameters

These examples illustrate how to change common block parameters.

8-107

8 Model and Block Parameters

This command changes the orientation of the Gain block in the mymodel system so it faces the opposite direction (right to left).

set_param('mymodel/Gain','Orientation','left')

This command associates an OpenFcn callback with the Gain block in the mymodel system.

set_param('mymodel/Gain','OpenFcn','my_open_cb')

This command sets the Position parameter of the Gain block in the mymodel system. The block is 75 pixels wide by 25 pixels high. The position vector

is not enclosed in quotation marks.

set_param('mymodel/Gain','Position', [50 250 125 275])

8-108

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]