PRGM – Setpoint programmer
Block SymbolLicensing group: STANDARD
Function Description
The PRGM block generates functions of time (programs) composed of n linear parts defined by
-dimensional vectors
of time () and
output values ().
The generated time-course is continuous piecewise linear, see figure below. This block is most
commonly used as a setpoint generator for a controller. The program generation starts when
. In the
case of
the programmer is set back to the initial state. The input
sets the
output sp to the value spv. It follows a ramp to the nearest future node of the time function
when .
The internal time of the generator is not affected by this input. The input
freezes the output sp and the internal time, thus also the outputs tsc,
tt and rt. The program follows from freezing point as planned when
unless the input
at the moment when
the signal HLD onoff.
In that case the program follows a ramp to reach the node with index ind in time trt. The node
index ind must be equal to or higher than the index of current sector isc (at the moment when
HLD onoff).
If , the
program is generated repeatedly.
Inputs
RUN | Enable execution | Bool |
DEF | Initialize sp to the value of spv | Bool |
spv | Initializing constant | Double (F64) |
HLD | Output and timer freezing | Bool |
CON | Continue from defined node | Bool |
ind | Index of the node to continue from | Long (I32) |
trt | Time to reach the defined node with index ind | Double (F64) |
RPT | Repetition flag | Bool |
Outputs
sp | Setpoint variable (function value of the time function at given time) | Double (F64) |
isc | Current function sector | Long (I32) |
tsc | Time elapsed since the start of current sector | Double (F64) |
tt | Time elapsed since the start of program generation | Double (F64) |
rt | Remaining time till the end of program | Double (F64) |
CNF | Flag indicating that the configured curve is being followed | Bool |
E | Error flag – the node times are not ascending | Bool |
Parameters
nmax | Reserved (allocated) size of the tm, y vectors 4 10000000 10 | Long (I32) |
tmunits | Time units 1 | Long (I32) |
|
|
|
tm | -dimensional vector of ascending node times [0 1 2] | Double (F64) |
y | -dimensional vector of node values (values of the time function) [0 1 0] | Double (F64) |
[Previous] [Back to top] [Up] [Next]
2023 © REX Controls s.r.o., www.rexygen.com