PRGM – Setpoint programmer

Block SymbolLicensing group: STANDARD
Qt SVG Document Exported by REXYGEN Studio RUN DEF spv HLD CON ind trt RPT sp isc tsc tt rt CNF E PRGM

Function Description
The PRGM block generates functions of time (programs) composed of n linear parts defined by (n + 1)-dimensional vectors of time (tm = [t0,,tn]) and output values (y = [y0,,yn]). 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 RUN = on. In the case of RUN = off the programmer is set back to the initial state. The input DEF = on sets the output sp to the value spv. It follows a ramp to the nearest future node of the time function when DEF = off. The internal time of the generator is not affected by this input. The input HLD = on 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 HLD = off unless the input CON = on at the moment when the signal HLD on off. 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 on off). If RPT = on, the program is generated repeatedly.

image/svg+xml isc 1 2 n t 1 y 0 y 1 y 2 y n-1 y n t 0 t 2 t n-1 t n tsc tt rt currentinstant

This block does not propagate the signal quality. More information can be found in the 1.4 section.

Input

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

Double (F64)

RPT

Repeating sequence

Bool

Parameter

nmax

Allocated size of array   4  10000000 10

Long (I32)

tmunits

Time units  1

Long (I32)

1 ....

seconds

2 ....

minutes

3 ....

hours

tm

Vector of ascending node times  [0 1 2]

Double (F64)

y

Vector of node values  [0 1 0]

Double (F64)

Output

sp

Setpoint variable

Double (F64)

isc

Current function sector

Long (I32)

tsc

Time elapsed since the start of current sector

Double (F64)

tt

Total elapsed time

Double (F64)

rt

Remaining time

Double (F64)

CNF

Configured curve is being followed

Bool

E

Error flag, nodes not ascending

Bool

2024 © REX Controls s.r.o., www.rexygen.com