FB_HVACTempChangeFunction

FB_HVACTempChangeFunction 1:

Function block for the input of the interpolation points of the pre-start function.

In order to keep the function blocks FB_HVACOptimizedOn and FB_HVACOptimizedOff well-arranged, they contain no entry of the individual value pairs for the temperature change function. The function blocks access the structure variable of the temperature change function (ST_HVACTempChangeFunction) via an IN-OUT variable. The function block FB_HVACTempChangeFunction enables the writing of the structure variable in a clear form and also makes sure that the value pairs, as required, are entered in ascending order of the outside temperature and that there are no two points with the same outside temperature. Mathematically speaking, there would be no unambiguous functional correlation in this case. The value pairs are to be entered at the corresponding inputs rOutsideTemperature_1 .. rOutsideTemperature_10 (outside temperature) and rRoomTempChange_1 .. rRoomTempChange_10 (room temperature change). The function block continuously checks whether the described requirement for ascending order of the outside temperature is fulfilled and whether two value pairs exist with the same outside temperature.

Note: The writing of the temperature change functions should take place once in order to give the pre-start/pre-stop function blocks basic values, which are then continually improved by these function blocks over the course of time.

VAR_INPUT

bWrite             : BOOL;
rOutsideTemp_1     : REAL;
rRoomTempChange_1  : REAL;
rOutsideTemp_2     : REAL;
rRoomTempChange_2  : REAL;
rOutsideTemp_3     : REAL;
rRoomTempChange_3  : REAL;
rOutsideTemp_4     : REAL;
rRoomTempChange_4  : REAL;
rOutsideTemp_5     : REAL;
rRoomTempChange_5  : REAL;
rOutsideTemp_6     : REAL;
rRoomTempChange_6  : REAL;
rOutsideTemp_7     : REAL;
rRoomTempChange_7  : REAL;
rOutsideTemp_8     : REAL;
rRoomTempChange_8  : REAL;
rOutsideTemp_9     : REAL;
rRoomTempChange_9  : REAL;
rOutsideTemp_10    : REAL;
rRoomTempChange_10 : REAL;

bWrite: A rising edge at this input copies the values entered at the inputs to the pre-start function.

(rOutsideTemp_1 - rRoomTempChange1) ... (rOutsideTemp_10 - rRoomTempChange10): Value pairs of the pre-start function: Room temperature change (rRoomTempChange) in degrees Kelvin per minute at outside temperature (rOutsideTemp) in degrees Celsius.

VAR_OUTPUT

bValid          : BOOL;
udiErrorID      : UDINT;

bValid: This output is switched to TRUE if the parameters entered are not erroneous.

udiErrorId: Contains the error code if the values entered should be erroneous. See Error codes.

VAR_IN_OUT

stTempChangeFunction  : ST_HVACTempChangeFunction;

stTempChangeFunction : structure variable of type ST_HVACTempChangeFunction, which contains the 10 pairs of values (outdoor temperature, room temperature change). These pairs of values, which have to be - sorted by rising outdoor temperature - entered in the field variable, define the 9 fragment lines of the temperature change function.

Requirements

Development environment

required library

required function

TwinCAT 3.1 build 4022.16 or higher

Tc2_HVAC V3.3.1.0

TF8000 | TC3 HVAC V1.0.0.0