Engee documentation

Constant

Constant value.

blockType: Constant

Path in the library:

/Basic/Sources/Constant

Description

Block Constant generates a valid or complex signal of constant value.

The block generates an output signal in the form of a scalar, vector, matrix or bus depending on the dimension of the parameter. Constant value.

Read more about the types of tires. Custom tire types.

The output signal of the block has the same dimensions and elements as the parameter Constant value.

Ports

Output

# OUT_1 — constant value
scalar | vector | matrix | bus

Details

A constant value in the form of a real or complex scalar, vector, matrix or bus. By default, block Constant outputs a signal whose dimension and data type are the same as the parameters Constant value.

Data types

Float16, Float32, Float64, Int8, Int16, Int32, Int64, Int128, UInt8, UInt16, UInt32, UInt64, UInt128, Bool, Fixed point, BusSignal

Complex numbers support

Yes

Parameters

Main

# Constant value — the value of the constant

Details

Set the output to a constant value of the block.

You can enter any value, including logical keywords. true and false.

Default value

1.0

Program usage name

Value

Tunable

Yes

Evaluatable

Yes

# Sample time — the interval between the calculation steps
SampleTime (real number / vector of two real numbers)

Details

Sets the time interval during which the block output signal is Constant it may change during simulation (for example, due to parameter settings Constant value).

Default value inf indicates that the block output can never change. This value speeds up the simulation and the generated code, avoiding the need to recalculate the block output.

Default value

Inf

Program usage name

SampleTime

Tunable

No

Evaluatable

Yes

Signal Attributes

# Output data type — type of output data
Inherit: auto | Float64 | Float32 | Float16 | Int8 | UInt8 | Int16 | UInt16 | Int32 | UInt32 | Int64 | UInt64 | Int128 | UInt128 | Bool | Fixed-point | BusSignal

Details

Specify the type of output data. The type can be inherited or specified directly.

Values

Inherit: auto | Float64 | Float32 | Float16 | Int8 | UInt8 | Int16 | UInt16 | Int32 | UInt32 | Int64 | UInt64 | Int128 | UInt128 | Bool | Fixed-point | BusSignal

Default value

Inherit: auto

Program usage name

OutDataTypeStr

Tunable

No

Evaluatable

No

Additional options

C code generation: Yes

Verilog code generation: Yes