blockOverwrite
Extends from Modelica.Blocks.Interfaces.SISO (Single Input Single Output continuous control block).
Information
This block enables the overwriting of a control signal by an external program, as well as reading of its meta-data, without the need to explicitly propogate the external input or activation switch to a top-level model.
Typical use and important parameters
This block is typically used by the BOPTEST framework (see BOPTEST) to identify and activate control signals that can be overwritten by test controllers. It is used in combination with a dedicated parser to perform this task (see Parser Code).
The input u is the signal to be overwritten. The output
y will be equal to the input signal if the activate
flag is false and will be equal to the external input signal uExt
if the flag is true.
It is important to add a brief description of the signal using the
description parameter and assign a min,
max, and unit to the input variable u
by modifying its attributes.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| String | description | Description of the signal being overwritten | |
| Boolean | boptestOverwrite | true | Parameter that is used by tools to search for overwrite block in models |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| RealInput | u (from SISO) | Connector of Real input signal | |
| RealOutput | y (from SISO) | Connector of Real output signal |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| Modelica.Blocks.Logical.Switch | swi | Switch between external signal and direct feedthrough signal | |
| Modelica.Blocks.Sources.RealExpression | uExt | External input signal | |
| Modelica.Blocks.Sources.BooleanExpression | activate | Block to activate use of external signal |