Control sequences for terminal units
Information
This package contains control sequences for terminal units.
Package Content
Name |
Description |
Controller
|
Controller for room VAV box |
ModeAndSetPoints
|
Output zone setpoint with operation mode selection |
Reheat
|
Sequences for VAV reheat terminal unit |
SetPoints
|
Generic sequences of generating setpoints for terminal units control |
Validation
|
Collection of validation models |
Controller for room VAV box
Information
Controller for terminal box of VAV system with reheat according to ASHRAE
Guideline 36, Part 5.E. It outputs damper position yDam
,
hot water valve position yVal
, AHU cooling supply temperature
setpoint reset request yZonTemResReq
, and static pressure setpoint
reset request yZonPreResReq
.
The sequence consists of four subsequences.
a. Heating and cooling control loop
The subsequence is implementd according to Part 5.B.5. The measured zone
temperature TZon
, zone setpoints temperatures TZonHeaSet
and
TZonCooSet
are inputs to the block conHeaLoo
and
conCooLoo
to generate the control loop signal.
b. Active airflow setpoint calculation
This sequence sets the active maximum and minimum airflow according to
Part 5.E.3-5. Depending on operation modes uOpeMod
, it sets the
airflow rate limits for cooling and heating supply. See
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Reheat.SetPoints.ActiveAirFlow.
c. Damper and valve control
This sequence sets the damper and valve position for VAV reheat terminal unit.
The implementation is according to Part 5.E.6. According to heating and cooling
control loop signal, it calculates the discharge air temperature setpoint
TDisHeaSet
. Along with the defined maximum and minimum airflow, measured
zone temperature, the sequence outputs yDam
, yVal
,
TDisHeaSet
and discharge airflow rate setpoint VDisSet_flow
.
See
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Reheat.DamperValves.
d. System reset requests generation
According to Part 5.E.9, this sequence outputs the system reset requests, i.e.
cooling supply air temperature reset requests yZonTemResReq
,
static pressure reset requests yZonPreResReq
, hot water reset
requests yHeaValResReq
, and the boiler plant reset requests
yHeaPlaReq
. See
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Reheat.SystemRequests.
Parameters
Type | Name | Default | Description |
Real | samplePeriod | samplePeriod(final unit="s",... | Sample period of component, set to the same value as the trim and respond that process yPreSetReq [s] |
Real | V_flow_nominal | V_flow_nominal(final unit="m... | Volume flow rate of this thermal zone [m3/s] |
Real | AFlo | AFlo(final unit="m2", final ... | Area of the zone [m2] |
Cooling loop signal |
SimpleController | controllerTypeCoo | Buildings.Controls.OBC.CDL.T... | Type of controller |
Real | kCoo | 0.1 | Gain for cooling control loop signal [1/K] |
Real | TiCoo | 900 | Time constant of integrator block for cooling control loop signal [s] |
Real | TdCoo | 0.1 | Time constant of derivative block for cooling control loop signal [s] |
Heating loop signal |
SimpleController | controllerTypeHea | Buildings.Controls.OBC.CDL.T... | Type of controller |
Real | kHea | 0.1 | Gain for heating control loop signal [1/K] |
Real | TiHea | 900 | Time constant of integrator block for heating control loop signal [s] |
Real | TdHea | 0.1 | Time constant of derivative block for heating control loop signal [s] |
Valve |
SimpleController | controllerTypeVal | Buildings.Controls.OBC.CDL.T... | Type of controller |
Real | kVal | 0.5 | Gain of controller for valve control |
Real | TiVal | 300 | Time constant of integrator block for valve control [s] |
Real | TdVal | 0.1 | Time constant of derivative block for valve control [s] |
Damper |
SimpleController | controllerTypeDam | Buildings.Controls.OBC.CDL.T... | Type of controller |
Real | kDam | 0.5 | Gain of controller for damper control [1] |
Real | TiDam | 300 | Time constant of integrator block for damper control [s] |
Real | TdDam | 0.1 | Time constant of derivative block for damper control [s] |
Airflow setpoint |
Zone sensors |
Boolean | have_occSen | false | Set to true if the zone has occupancy sensor |
Boolean | have_winSen | false | Set to true if the zone has window status sensor |
Boolean | have_CO2Sen | false | Set to true if the zone has CO2 sensor |
Nominal conditions |
Real | VDisCooSetMax_flow | V_flow_nominal | Zone maximum cooling airflow setpoint [m3/s] |
Real | VDisSetMin_flow | 0.15*V_flow_nominal | Zone minimum airflow setpoint [m3/s] |
Real | VDisHeaSetMax_flow | V_flow_nominal | Zone maximum heating airflow setpoint [m3/s] |
Real | VDisConMin_flow | 0.1*V_flow_nominal | VAV box controllable minimum [m3/s] |
Real | VOutPerAre_flow | 3e-4 | Outdoor air rate per unit area [m3/(s.m2)] |
Real | VOutPerPer_flow | 2.5e-3 | Outdoor air rate per person [m3/s] |
Real | CO2Set | 894 | CO2 setpoint in ppm |
Damper and valve |
Parameters |
Real | dTDisZonSetMax | 11 | Zone maximum discharge air temperature above heating setpoint [K] |
Real | TDisMin | 283.15 | Lowest discharge air temperature [K] |
System requests |
Parameters |
Boolean | have_heaWatCoi | true | Flag, true if there is a hot water coil |
Boolean | have_heaPla | false | Flag, true if there is a boiler plant |
Real | errTZonCoo_1 | 2.8 | Limit value of difference between zone temperature and cooling setpoint
for generating 3 cooling SAT reset requests [K] |
Real | errTZonCoo_2 | 1.7 | Limit value of difference between zone temperature and cooling setpoint
for generating 2 cooling SAT reset requests [K] |
Real | errTDis_1 | 17 | Limit value of difference between discharge air temperature and its setpoint
for generating 3 hot water reset requests [K] |
Real | errTDis_2 | 8.3 | Limit value of difference between discharge air temperature and its setpoint
for generating 2 hot water reset requests [K] |
Duration times |
Real | durTimTem | 120 | Duration time of zone temperature exceeds setpoint [s] |
Real | durTimFlo | 60 | Duration time of airflow rate less than setpoint [s] |
Real | durTimDisAir | 300 | Duration time of discharge air temperature is less than setpoint [s] |
Connectors
Type | Name | Description |
input RealInput | TZonHeaSet | Setpoint temperature for room for heating [K] |
input RealInput | TZonCooSet | Setpoint temperature for room for cooling [K] |
input RealInput | TZon | Measured room temperature [K] |
input RealInput | TDis | Measured supply air temperature after heating coil [K] |
input RealInput | VDis_flow | Measured discharge airflow rate [m3/s] |
input RealInput | TSupAHU | AHU supply air temperature [K] |
input RealInput | ppmCO2 | Measured CO2 concentration |
input RealInput | nOcc | Number of occupants |
input BooleanInput | uWin | Window status, true if open, false if closed |
input IntegerInput | uOpeMod | Zone operation mode |
input RealInput | yDam_actual | Actual VAV damper position |
output RealOutput | yVal | Signal for heating coil valve [1] |
output RealOutput | yDam | Signal for VAV damper [1] |
output IntegerOutput | yZonTemResReq | Zone cooling supply air temperature reset request |
output IntegerOutput | yZonPreResReq | Zone static pressure reset requests |
Modelica definition
block Controller
parameter Real samplePeriod(
final unit="s",
final quantity="Time")
;
parameter Real V_flow_nominal(
final unit="m3/s",
final quantity="VolumeFlowRate")
;
parameter Real AFlo(
final unit="m2",
final quantity="Area") ;
parameter Buildings.Controls.OBC.CDL.Types.SimpleController controllerTypeCoo=
Buildings.Controls.OBC.CDL.Types.SimpleController.PI ;
parameter Real kCoo(
final unit="1/K") = 0.1
;
parameter Real TiCoo(
final unit="s",
final quantity="Time")=900
;
parameter Real TdCoo(
final unit="s",
final quantity="Time")=0.1
;
parameter Buildings.Controls.OBC.CDL.Types.SimpleController controllerTypeHea=
Buildings.Controls.OBC.CDL.Types.SimpleController.PI
;
parameter Real kHea(
final unit="1/K")=0.1
;
parameter Real TiHea(
final unit="s",
final quantity="Time")=900
;
parameter Real TdHea(
final unit="s",
final quantity="Time")=0.1
;
parameter Buildings.Controls.OBC.CDL.Types.SimpleController controllerTypeVal=
Buildings.Controls.OBC.CDL.Types.SimpleController.PI
;
parameter Real kVal=0.5
;
parameter Real TiVal(
final unit="s",
final quantity="Time")=300
;
parameter Real TdVal(
final unit="s",
final quantity="Time")=0.1
;
parameter Buildings.Controls.OBC.CDL.Types.SimpleController controllerTypeDam=
Buildings.Controls.OBC.CDL.Types.SimpleController.PI
;
parameter Real kDam(
final unit="1")=0.5
;
parameter Real TiDam(
final unit="s",
final quantity="Time")=300
;
parameter Real TdDam(
final unit="s",
final quantity="Time")=0.1
;
parameter Boolean have_occSen=false
;
parameter Boolean have_winSen=false
;
parameter Boolean have_CO2Sen=false
;
parameter Real VDisCooSetMax_flow(
final unit="m3/s",
final quantity="VolumeFlowRate")=V_flow_nominal
;
parameter Real VDisSetMin_flow(
final unit="m3/s",
final quantity="VolumeFlowRate")=0.15*V_flow_nominal
;
parameter Real VDisHeaSetMax_flow(
final unit="m3/s",
final quantity="VolumeFlowRate")=V_flow_nominal
;
parameter Real VDisConMin_flow(
final unit="m3/s",
final quantity="VolumeFlowRate")=0.1*V_flow_nominal
;
parameter Real VOutPerAre_flow(
final unit = "m3/(s.m2)")=3e-4
;
parameter Real VOutPerPer_flow(
final unit="m3/s",
final quantity="VolumeFlowRate")=2.5e-3
;
parameter Real CO2Set=894 ;
parameter Real dTDisZonSetMax(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=11
;
parameter Real TDisMin(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=283.15
;
parameter Boolean have_heaWatCoi=true
;
parameter Boolean have_heaPla=false
;
parameter Real errTZonCoo_1(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=2.8
;
parameter Real errTZonCoo_2(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=1.7
;
parameter Real errTDis_1(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=17
;
parameter Real errTDis_2(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=8.3
;
parameter Real durTimTem(
final unit="s",
final quantity="Time")=120
;
parameter Real durTimFlo(
final unit="s",
final quantity="Time")=60
;
parameter Real durTimDisAir(
final unit="s",
final quantity="Time")=300
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput TZonHeaSet(
final quantity="ThermodynamicTemperature",
final unit = "K",
final displayUnit = "degC")
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput TZonCooSet(
final quantity="ThermodynamicTemperature",
final unit = "K",
final displayUnit = "degC")
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput TZon(
final quantity="ThermodynamicTemperature",
final unit = "K",
final displayUnit = "degC")
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput TDis(
final quantity="ThermodynamicTemperature",
final unit = "K",
final displayUnit = "degC")
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput VDis_flow(
final unit="m3/s",
final quantity="VolumeFlowRate")
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput TSupAHU(
final quantity="ThermodynamicTemperature",
final unit = "K",
final displayUnit = "degC")
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput ppmCO2
if have_CO2Sen
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput nOcc
if have_occSen
;
Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uWin
if have_winSen
;
Buildings.Controls.OBC.CDL.Interfaces.IntegerInput uOpeMod
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput yDam_actual
;
Buildings.Controls.OBC.CDL.Interfaces.RealOutput yVal(
final min=0,
final max=1,
final unit="1")
;
Buildings.Controls.OBC.CDL.Interfaces.RealOutput yDam(
final min=0,
final max=1,
final unit="1")
;
Buildings.Controls.OBC.CDL.Interfaces.IntegerOutput yZonTemResReq
;
Buildings.Controls.OBC.CDL.Interfaces.IntegerOutput yZonPreResReq
;
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Reheat.SetPoints.ActiveAirFlow
actAirSet(
final AFlo=AFlo,
final have_occSen=have_occSen,
final have_winSen=have_winSen,
final have_CO2Sen=have_CO2Sen,
final VDisCooSetMax_flow=VDisCooSetMax_flow,
final VDisSetMin_flow=VDisSetMin_flow,
final VDisHeaSetMax_flow=VDisHeaSetMax_flow,
final VDisConMin_flow=VDisConMin_flow,
final VOutPerAre_flow=VOutPerAre_flow,
final VOutPerPer_flow=VOutPerPer_flow,
final CO2Set=CO2Set)
;
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Reheat.DamperValves damVal(
final controllerTypeVal=controllerTypeVal,
final kVal=kVal,
final TiVal=TiVal,
final TdVal=TdVal,
final controllerTypeDam=controllerTypeDam,
final kDam=kDam,
final TiDam=TiDam,
final TdDam=TdDam,
final dTDisZonSetMax=dTDisZonSetMax,
final TDisMin=TDisMin,
V_flow_nominal=
max(VDisCooSetMax_flow, VDisHeaSetMax_flow))
;
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.Reheat.SystemRequests sysReq(
final samplePeriod=samplePeriod,
final have_heaWatCoi=have_heaWatCoi,
final have_heaPla=have_heaPla,
final errTZonCoo_1=errTZonCoo_1,
final errTZonCoo_2=errTZonCoo_2,
final errTDis_1=errTDis_1,
final errTDis_2=errTDis_2,
final durTimTem=durTimTem,
final durTimFlo=durTimFlo,
final durTimDisAir=durTimDisAir)
;
Buildings.Controls.OBC.CDL.Continuous.LimPID conHeaLoo(
final controllerType=controllerTypeHea,
final k=kHea,
final Ti=TiHea,
final Td=TdHea,
final yMax=1,
final yMin=0,
reset=Buildings.Controls.OBC.CDL.Types.Reset.Parameter) ;
Buildings.Controls.OBC.CDL.Continuous.LimPID conCooLoo(
final controllerType=controllerTypeCoo,
final k=kCoo,
final Ti=TiCoo,
final Td=TdCoo,
final yMax=1,
final yMin=0,
reverseAction=true,
reset=Buildings.Controls.OBC.CDL.Types.Reset.Parameter) ;
protected
Buildings.Controls.OBC.CDL.Integers.Equal isUnOcc
;
Buildings.Controls.OBC.CDL.Integers.Sources.Constant conIntUn(
final k=Buildings.Controls.OBC.ASHRAE.G36_PR1.Types.OperationModes.unoccupied)
;
Buildings.Controls.OBC.CDL.Logical.Not isNotUn
;
equation
connect(sysReq.TZonCooSet, TZonCooSet);
connect(sysReq.TZon, TZon);
connect(sysReq.VDisSet_flow, damVal.VDisSet_flow);
connect(sysReq.VDis_flow, VDis_flow);
connect(sysReq.TDisHeaSet, damVal.TDisHeaSet);
connect(damVal.yDam, yDam);
connect(damVal.yHeaVal, yVal);
connect(damVal.VDis_flow, VDis_flow);
connect(damVal.TDis, TDis);
connect(sysReq.TDis, TDis);
connect(damVal.yHeaVal, sysReq.uHeaVal);
connect(TZon, damVal.TZon);
connect(damVal.TSup, TSupAHU);
connect(actAirSet.VActCooMax_flow, damVal.VActCooMax_flow);
connect(actAirSet.VActCooMin_flow, damVal.VActCooMin_flow);
connect(actAirSet.VActMin_flow, damVal.VActMin_flow);
connect(actAirSet.VActHeaMin_flow, damVal.VActHeaMin_flow);
connect(actAirSet.VActHeaMax_flow, damVal.VActHeaMax_flow);
connect(damVal.THeaSet, TZonHeaSet);
connect(actAirSet.VActCooMax_flow, damVal.VActCooMax_flow);
connect(actAirSet.VActCooMin_flow, damVal.VActCooMin_flow);
connect(actAirSet.VActMin_flow, damVal.VActMin_flow);
connect(actAirSet.VActHeaMin_flow, damVal.VActHeaMin_flow);
connect(actAirSet.VActHeaMax_flow, damVal.VActHeaMax_flow);
connect(actAirSet.uOpeMod, uOpeMod);
connect(sysReq.yZonTemResReq, yZonTemResReq);
connect(sysReq.yZonPreResReq, yZonPreResReq);
connect(actAirSet.ppmCO2, ppmCO2);
connect(actAirSet.nOcc, nOcc);
connect(actAirSet.uWin, uWin);
connect(TZonHeaSet, conHeaLoo.u_s);
connect(TZonCooSet, conCooLoo.u_s);
connect(TZon, conHeaLoo.u_m);
connect(TZon, conCooLoo.u_m);
connect(conCooLoo.y, damVal.uCoo);
connect(conHeaLoo.y, damVal.uHea);
connect(conCooLoo.y, sysReq.uCoo);
connect(damVal.uOpeMod, uOpeMod);
connect(conIntUn.y, isUnOcc.u1);
connect(uOpeMod, isUnOcc.u2);
connect(isUnOcc.y, isNotUn.u);
connect(isNotUn.y, conCooLoo.trigger);
connect(isNotUn.y, conHeaLoo.trigger);
connect(sysReq.yDam_actual,yDam_actual);
end Controller;
Output zone setpoint with operation mode selection
Information
Block that outputs the zone setpoint temperature (TZonCooSet
, TZonHeaSet
)
and system operation mode (yOpeMod
). When operation mode is in freeze
protection setback mode, it also outputs a level 3 freeze protection alarm
yFreProSta
. The sequences are implemented according to ASHRAE
Guideline 36, Part 5.B.3 and 5.C.6.
The sequence consists of the following two subsequences.
Operation mode selector
The subsequence outputs one of seven types of system operation mode (occupied, warmup,
cool-down, setback, freeze protection setback, setup, unoccupied) according
to current time, the time to next occupied hours tNexOcc
and
current zone temperature TZon
.
See
Buildings.Controls.OBC.ASHRAE.G36_PR1.Generic.SetPoints.OperationMode.
Zone setpoint temperature reset
This sequence is implemented according to Part 5.B.3. It sets the zone temperature setpoint
according to the globally specified setpoints, the local setpoint adjustments, the demand
limits adjustment, the window status and the occupancy status.
See
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.SetPoints.ZoneTemperatures.
Usage
This version is for a single zone only to be used in the Single Zone VAV sequence.
For multizone systems, use
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.ModeAndSetPoints.
Parameters
Type | Name | Default | Description |
Real | TZonHeaOn | 293.15 | Heating setpoint during on [K] |
Real | TZonHeaOff | 285.15 | Heating setpoint during off [K] |
Real | TZonCooOn | 297.15 | Cooling setpoint during on [K] |
Real | TZonCooOff | 303.15 | Cooling setpoint during off [K] |
Operation mode |
Parameters |
Real | preWarCooTim | 10800 | Maximum cool-down/warm-up time [s] |
Real | bouLim | 1.1 | Value limit to indicate the end of setback/setup mode [K] |
Real | TZonFreProOn | 277.55 | Threshold zone temperature value to activate freeze protection mode [K] |
Real | TZonFreProOff | 280.35 | Threshold zone temperature value to finish the freeze protection mode [K] |
Test setting |
Real | warCooTim | 1800 | Defined cool-down/warm-up time [s] |
Setpoint adjust |
Sensors |
Boolean | have_occSen | false | Check if the zone has occupancy sensor |
Boolean | have_winSen | false | Check if the zone has window status sensor |
Adjustable settings |
Boolean | cooAdj | false | Flag, set to true if both cooling and heating setpoint are adjustable separately |
Boolean | heaAdj | false | Flag, set to true if heating setpoint is adjustable |
Boolean | sinAdj | false | Flag, set to true if both cooling and heating setpoint are adjustable through a single common knob |
Boolean | ignDemLim | true | Flag, set to true to exempt individual zone from demand limit setpoint adjustment |
Limits |
Real | TZonCooOnMax | 300.15 | Maximum cooling setpoint during on [K] |
Real | TZonCooOnMin | 295.15 | Minimum cooling setpoint during on [K] |
Real | TZonHeaOnMax | 295.15 | Maximum heating setpoint during on [K] |
Real | TZonHeaOnMin | 291.15 | Minimum heating setpoint during on [K] |
Real | TZonCooSetWinOpe | 322.15 | Cooling setpoint when window is open [K] |
Real | TZonHeaSetWinOpe | 277.15 | Heating setpoint when window is open [K] |
Demands settings |
Real | incTSetDem_1 | 0.56 | Cooling setpoint increase value when cooling demand limit level 1 is imposed [K] |
Real | incTSetDem_2 | 1.1 | Cooling setpoint increase value when cooling demand limit level 2 is imposed [K] |
Real | incTSetDem_3 | 2.2 | Cooling setpoint increase value when cooling demand limit level 3 is imposed [K] |
Real | decTSetDem_1 | 0.56 | Heating setpoint decrease value when heating demand limit level 1 is imposed [K] |
Real | decTSetDem_2 | 1.1 | Heating setpoint decrease value when heating demand limit level 2 is imposed [K] |
Real | decTSetDem_3 | 2.2 | Heating setpoint decrease value when heating demand limit level 3 is imposed [K] |
Integer | cooDemLimLevCon | Buildings.Controls.OBC.ASHRA... | Cooling demand limit level |
Integer | heaDemLimLevCon | Buildings.Controls.OBC.ASHRA... | Heating demand limit level |
Boolean | winStaCon | false | Window status, set to true if window is open |
Connectors
Type | Name | Description |
input RealInput | tNexOcc | Time to next occupied period [s] |
input BooleanInput | uOcc | Current occupancy period, true if it is in occupant period |
input RealInput | TZon | Measured zone temperatures [K] |
input RealInput | setAdj | Setpoint adjustment value [K] |
input RealInput | heaSetAdj | Heating setpoint adjustment value [K] |
input BooleanInput | uOccSen | Occupancy sensor (occupied=true, unoccupied=false) |
input BooleanInput | uWinSta | Window status (open=true, close=false) |
output RealOutput | TZonCooSet | Cooling setpoint temperature [K] |
output RealOutput | TZonHeaSet | Heating setpoint temperature [K] |
output IntegerOutput | yOpeMod | Operation mode |
Modelica definition
block ModeAndSetPoints
parameter Real TZonHeaOn(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=293.15
;
parameter Real TZonHeaOff(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=285.15
;
parameter Real TZonCooOn(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=297.15
;
parameter Real TZonCooOff(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=303.15
;
parameter Real preWarCooTim(
final unit="s",
final quantity="Time")=10800
;
parameter Real bouLim(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=1.1
;
parameter Real TZonFreProOn(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=277.55
;
parameter Real TZonFreProOff(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=280.35
;
parameter Real warCooTim(
final unit="s",
final quantity="Time")=1800
;
parameter Boolean have_occSen=false
;
parameter Boolean have_winSen=false
;
parameter Boolean cooAdj=false
;
parameter Boolean heaAdj=false
;
parameter Boolean sinAdj=false
;
parameter Boolean ignDemLim=true
;
parameter Real TZonCooOnMax(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=300.15
;
parameter Real TZonCooOnMin(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=295.15
;
parameter Real TZonHeaOnMax(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=295.15
;
parameter Real TZonHeaOnMin(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=291.15
;
parameter Real TZonCooSetWinOpe(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=322.15
;
parameter Real TZonHeaSetWinOpe(
final unit="K",
final displayUnit="degC",
final quantity="ThermodynamicTemperature")=277.15
;
parameter Real incTSetDem_1(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=0.56
;
parameter Real incTSetDem_2(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=1.1
;
parameter Real incTSetDem_3(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=2.2
;
parameter Real decTSetDem_1(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=0.56
;
parameter Real decTSetDem_2(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=1.1
;
parameter Real decTSetDem_3(
final unit="K",
final displayUnit="K",
final quantity="TemperatureDifference")=2.2
;
parameter Integer cooDemLimLevCon=Buildings.Controls.OBC.ASHRAE.G36_PR1.Types.DemandLimitLevels.cooling0
;
parameter Integer heaDemLimLevCon=Buildings.Controls.OBC.ASHRAE.G36_PR1.Types.DemandLimitLevels.heating0
;
parameter Boolean winStaCon=false
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput tNexOcc(
final unit="s",
quantity="Time")
;
Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uOcc
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput TZon(
final unit="K",
quantity="ThermodynamicTemperature")
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput setAdj(
final unit="K",
quantity="ThermodynamicTemperature")
if (cooAdj
or sinAdj)
;
Buildings.Controls.OBC.CDL.Interfaces.RealInput heaSetAdj(
final unit="K",
quantity="ThermodynamicTemperature")
if heaAdj
;
Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uOccSen
if have_occSen
;
Buildings.Controls.OBC.CDL.Interfaces.BooleanInput uWinSta
if have_winSen
;
Buildings.Controls.OBC.CDL.Interfaces.RealOutput TZonCooSet(
final unit="K",
quantity="ThermodynamicTemperature") ;
Buildings.Controls.OBC.CDL.Interfaces.RealOutput TZonHeaSet(
final unit="K",
quantity="ThermodynamicTemperature") ;
Buildings.Controls.OBC.CDL.Interfaces.IntegerOutput yOpeMod
;
protected
Buildings.Controls.OBC.ASHRAE.G36_PR1.TerminalUnits.SetPoints.ZoneTemperatures
TZonSet(
final have_occSen=have_occSen,
final have_winSen=have_winSen,
final cooAdj=cooAdj,
final heaAdj=heaAdj,
final sinAdj=sinAdj,
final ignDemLim=ignDemLim,
final TZonCooOnMax=TZonCooOnMax,
final TZonCooOnMin=TZonCooOnMin,
final TZonHeaOnMax=TZonHeaOnMax,
final TZonHeaOnMin=TZonHeaOnMin,
final TZonCooSetWinOpe=TZonCooSetWinOpe,
final TZonHeaSetWinOpe=TZonHeaSetWinOpe,
final incTSetDem_1=incTSetDem_1,
final incTSetDem_2=incTSetDem_2,
final incTSetDem_3=incTSetDem_3,
final decTSetDem_1=decTSetDem_1,
final decTSetDem_2=decTSetDem_2,
final decTSetDem_3=decTSetDem_3) ;
Buildings.Controls.OBC.CDL.Integers.Sources.Constant cooDemLimLev(
final k=cooDemLimLevCon)
;
Buildings.Controls.OBC.CDL.Integers.Sources.Constant heaDemLimLev(
final k=heaDemLimLevCon) ;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TSetRooHeaOn(
final k=TZonHeaOn)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TSetRooHeaOff(
final k=TZonHeaOff)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TSetRooCooOn(
final k=TZonCooOn)
;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant TSetRooCooOff(
final k=TZonCooOff)
;
Buildings.Controls.OBC.ASHRAE.G36_PR1.Generic.SetPoints.OperationMode
opeModSel(
final have_winSen=have_winSen,
final numZon=1,
final preWarCooTim=preWarCooTim,
final TZonFreProOn=TZonFreProOn,
final TZonFreProOff=TZonFreProOff) ;
Buildings.Controls.OBC.CDL.Continuous.Sources.Constant tCooDowHeaUp(
final k=warCooTim) ;
Buildings.Controls.OBC.ASHRAE.G36_PR1.Generic.SetPoints.ZoneStatus zonSta(
final have_winSen=have_winSen) ;
Buildings.Controls.OBC.CDL.Conversions.BooleanToInteger colZon
;
Buildings.Controls.OBC.CDL.Conversions.BooleanToInteger hotZon
;
equation
connect(TZonSet.uCooDemLimLev,cooDemLimLev. y);
connect(heaDemLimLev.y,TZonSet. uHeaDemLimLev);
connect(TZonSet.TZonCooSet, TZonCooSet);
connect(TZonSet.TZonHeaSet, TZonHeaSet);
connect(setAdj, TZonSet.setAdj);
connect(heaSetAdj, TZonSet.heaSetAdj);
connect(TZonSet.uOccSen, uOccSen);
connect(TZonSet.uWinSta, uWinSta);
connect(tCooDowHeaUp.y, zonSta.cooDowTim);
connect(tCooDowHeaUp.y, zonSta.warUpTim);
connect(uWinSta, zonSta.uWinSta);
connect(TSetRooHeaOn.y, zonSta.TZonHeaSetOcc);
connect(TSetRooCooOn.y, zonSta.TZonCooSetOcc);
connect(TZon, zonSta.TZonMax);
connect(TZon, zonSta.TZon);
connect(TZon, zonSta.TZonMin);
connect(TSetRooHeaOff.y, zonSta.TZonHeaSetUno);
connect(TSetRooCooOff.y, zonSta.TZonCooSetUno);
connect(uOcc, opeModSel.uOcc);
connect(tNexOcc, opeModSel.tNexOcc);
connect(zonSta.yCooTim, opeModSel.maxCooDowTim);
connect(zonSta.yWarTim, opeModSel.maxWarUpTim);
connect(zonSta.yOccHeaHigMin, opeModSel.occHeaHigMin);
connect(zonSta.yMaxHigOccCoo, opeModSel.maxHigOccCoo);
connect(zonSta.yUnoHeaHigMin, opeModSel.unoHeaHigMin);
connect(TZon, opeModSel.TZonMax);
connect(TZon, opeModSel.TZonMin);
connect(zonSta.yMaxHigUnoCoo, opeModSel.maxHigUnoCoo);
connect(zonSta.yLowUnoHea, colZon.u);
connect(zonSta.yHigUnoCoo, hotZon.u);
connect(colZon.y, opeModSel.totColZon);
connect(hotZon.y, opeModSel.totHotZon);
connect(opeModSel.yOpeMod, TZonSet.uOpeMod);
connect(opeModSel.yOpeMod, yOpeMod);
connect(TSetRooCooOn.y, TZonSet.TZonCooSetOcc);
connect(TSetRooCooOff.y, TZonSet.TZonCooSetUno);
connect(TSetRooHeaOn.y, TZonSet.TZonHeaSetOcc);
connect(TSetRooHeaOff.y, TZonSet.TZonHeaSetUno);
connect(uWinSta, opeModSel.uWinSta);
end ModeAndSetPoints;