blockBooleanToInteger
Convert Boolean to Integer signal
Extends from Interfaces.partialBooleanSI (Partial block with 1 input Boolean signal).
Information
This block computes the output y as Integer equivalent of the Boolean input u:
y = if u then integerTrue else integerFalse;
where u is of Boolean and y of Integer type, and integerTrue and integerFalse are parameters.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Integer | integerTrue | 1 | Output signal for true Boolean input |
| Integer | integerFalse | 0 | Output signal for false Boolean input |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| Blocks.Interfaces.BooleanInput | u (from partialBooleanSI) | Connector of Boolean input signal | |
| Blocks.Interfaces.IntegerOutput | y | Connector of Integer output signal |