Skip to content

Commit

Permalink
Update the base models in the package building control emulator
Browse files Browse the repository at this point in the history
  • Loading branch information
terrancelu92 committed Jun 16, 2023
1 parent 1eb6958 commit f3fcdae
Show file tree
Hide file tree
Showing 20 changed files with 22,291 additions and 194 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ model DryCoil
dp2_nominal=PreDroAir,
eps=eps)
annotation (Placement(transformation(extent={{-14,-10},{6,10}})));
Modelica.Fluid.Sensors.TemperatureTwoPort temEntWat(redeclare package Medium
= MediumWat)
Modelica.Fluid.Sensors.TemperatureTwoPort temEntWat(redeclare package Medium =
MediumWat)
annotation (Placement(transformation(extent={{-74,-4},{-54,16}})));
Modelica.Fluid.Sensors.TemperatureTwoPort temLeaWat(redeclare package Medium
= MediumWat)
Modelica.Fluid.Sensors.TemperatureTwoPort temLeaWat(redeclare package Medium =
MediumWat)
annotation (Placement(transformation(extent={{62,-4},{82,16}})));
Modelica.Fluid.Sensors.TemperatureTwoPort temEntAir(redeclare package Medium
= MediumAir)
Modelica.Fluid.Sensors.TemperatureTwoPort temEntAir(redeclare package Medium =
MediumAir)
annotation (Placement(transformation(extent={{50,-70},{30,-50}})));
Modelica.Fluid.Sensors.MassFlowRate masFloWat(redeclare package Medium =
MediumWat)
Expand All @@ -43,8 +43,8 @@ model DryCoil
Modelica.Fluid.Sensors.MassFlowRate masFloAir(redeclare package Medium =
MediumAir)
annotation (Placement(transformation(extent={{-40,-70},{-60,-50}})));
Modelica.Fluid.Sensors.TemperatureTwoPort temLeaAir(redeclare package Medium
= MediumAir)
Modelica.Fluid.Sensors.TemperatureTwoPort temLeaAir(redeclare package Medium =
MediumAir)
annotation (Placement(transformation(extent={{-68,-70},{-88,-50}})));
Modelica.Fluid.Sensors.Pressure preAirLea(redeclare package Medium =
MediumAir)
Expand Down Expand Up @@ -102,32 +102,32 @@ equation
thickness=1));
connect(temEntAir.port_b, coi.port_a2) annotation (Line(
points={{30,-60},{20,-60},{20,-6},{6,-6}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(temEntAir.port_a,port_a_Air) annotation (Line(
points={{50,-60},{100,-60}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(masFloAir.port_a, coi.port_b2) annotation (Line(
points={{-40,-60},{-20,-60},{-20,-6},{-14,-6}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(temLeaAir.port_a, masFloAir.port_b) annotation (Line(
points={{-68,-60},{-60,-60}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(temLeaAir.port_b,port_b_Air) annotation (Line(
points={{-88,-60},{-100,-60}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(preAirLea.port, coi.port_b2) annotation (Line(
points={{-40,-46},{-20,-46},{-20,-6},{-14,-6}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(preAirEnt.port, coi.port_a2) annotation (Line(
points={{40,-44},{40,-46},{20,-46},{20,-6},{6,-6}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(temLeaAir.T,TAirLea) annotation (Line(
points={{-78,-49},{-78,-20},{110,-20}},
color={0,0,127},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,22 +49,22 @@ model MixingBox
equation
connect(mixBox.port_Exh, port_Exh) annotation (Line(
points={{-19,30},{-19,60},{-60,60},{-60,100}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(mixBox.port_Fre, port_Fre) annotation (Line(
points={{20,30},{20,62},{60,62},{60,100}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(mixBox.port_Ret, port_Ret)
annotation (Line(
points={{-19,-28},{-19,-58},{-58,-58},{-58,-100}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(mixBox.port_Sup, port_Sup)
annotation (Line(
points={{20,-28},{20,-28},{20,-58},{60,-58},{60,-102}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(mixBox.T, ecoCon.Mea)
annotation (Line(
points={{35,-11.18},{64,-11.18},{64,20},{-88,20},{-88,32},{-72,32}},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,30 +89,30 @@ model VAV_advance_temp_sensor
equation
connect(temEnt.port_a,port_a) annotation (Line(
points={{-88,0},{-88,0},{-100,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(Dam.port_b, temLea.port_a)
annotation (Line(
points={{8,0},{30,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(temLea.port_b,masFloRat. port_a) annotation (Line(
points={{50,0},{60,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(masFloRat.port_b,port_b) annotation (Line(
points={{80,0},{100,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(preLea.port,temLea. port_a) annotation (Line(
points={{20,-20},{20,0},{30,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(preEnt.port, Dam.port_a)
annotation (Line(
points={{-26,-20},{-26,0},{-12,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(masFloRat.m_flow, gain.u) annotation (Line(
points={{70,11},{70,23.2}},
color={0,0,127},
Expand All @@ -131,10 +131,12 @@ equation
color={255,0,0},
thickness=1));
connect(heaCoil.port_a_Air, temEnt.port_b)
annotation (Line(points={{-60,0},{-64,0},{-68,0}}, color={0,127,255}));
annotation (Line(points={{-60,0},{-64,0},{-68,0}}, color={0,140,72},
thickness=0.5));
connect(heaCoil.port_b_Air, Dam.port_a)
annotation (Line(points={{-40,0},{-26,0},{-12,0}},
color={0,127,255}));
color={0,140,72},
thickness=0.5));
connect(ReheaVal.port_a, heaCoil.port_b_Wat) annotation (Line(
points={{-20,40},{-22,40},{-22,28},{-60,28},{-60,12}},
color={255,0,0},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,12 @@ model ZonCon
annotation (Placement(transformation(extent={{-140,-80},{-100,-40}})));
Modelica.Blocks.Interfaces.RealOutput yAirFlowSetPoi
"Connector of actuator output signal"
annotation (Placement(transformation(extent={{100,50},{120,70}})));
annotation (Placement(transformation(extent={{100,50},{122,72}}),
iconTransformation(extent={{100,50},{122,72}})));
Modelica.Blocks.Interfaces.RealOutput yValPos
"Connector of actuator output signal"
annotation (Placement(transformation(extent={{100,-70},{120,-50}})));
annotation (Placement(transformation(extent={{100,-70},{122,-48}}),
iconTransformation(extent={{100,-70},{122,-48}})));
Modelica.Blocks.Logical.Switch swi
"Switch between external signal and direct feedthrough signal"
annotation (Placement(transformation(extent={{48,10},{68,30}})));
Expand Down Expand Up @@ -109,19 +111,23 @@ equation
points={{-71.6,-60},{-62,-60},{-62,14},{-58,14}},
color={0,0,127},
pattern=LinePattern.Dash));
connect(oveAirFlowSetPoi.y, yAirFlowSetPoi) annotation (Line(points={{84.8,60},
{110,60}}, color={0,0,127}));
connect(oveAirFlowSetPoi.y, yAirFlowSetPoi) annotation (Line(points={{82.7,61},
{111,61}}, color={0,0,127}));
connect(heaCon.y, oveyValPos.u) annotation (Line(points={{63,-60},{70,-60},{
70,-59},{70.6,-59}}, color={0,0,127}));
connect(oveyValPos.y, yValPos) annotation (Line(points={{86.7,-59},{94,-59},{
94,-60},{110,-60}}, color={0,0,127}));
connect(oveyValPos.y, yValPos) annotation (Line(points={{86.7,-59},{111,-59}},
color={0,0,127}));
connect(swi.y, oveAirFlowSetPoi.u) annotation (Line(points={{69,20},{86,20},{
86,46},{48,46},{48,60},{66.4,60}}, color={0,0,127}));
86,46},{48,46},{48,61},{66.6,61}}, color={0,0,127}));
annotation (Icon(coordinateSystem(preserveAspectRatio=false), graphics={
Rectangle(
extent={{-100,100},{100,-100}},
lineColor={0,0,127},
fillColor={255,255,255},
fillPattern=FillPattern.Solid)}), Diagram(coordinateSystem(
fillPattern=FillPattern.Solid),
Text(
extent={{-154,112},{146,152}},
textString="%name",
textColor={0,0,255})}), Diagram(coordinateSystem(
preserveAspectRatio=false)));
end ZonCon;
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,13 @@ equation
connect(VarSpeFloMov.port_a, port_a)
annotation (Line(
points={{-10,0},{-10,0},{-100,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(VarSpeFloMov.port_b, port_b)
annotation (Line(
points={{10,0},{56,0},{100,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(VarSpeFloMov.y, u)
annotation (Line(
points={{0,12},{0,60},{-110,60}},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,32 +37,32 @@ model VAVSupplyFan
equation
connect(withoutMotor.port_a, temEnt.port_b) annotation (Line(
points={{-18,0},{-60,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(temEnt.port_a, port_a) annotation (Line(
points={{-80,0},{-100,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(withoutMotor.port_b, temLea.port_a) annotation (Line(
points={{2,0},{30,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(temLea.port_b, masFloRat.port_a) annotation (Line(
points={{50,0},{60,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(masFloRat.port_b, port_b) annotation (Line(
points={{80,0},{100,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(preEnt.port, temEnt.port_b) annotation (Line(
points={{-42,-20},{-42,0},{-60,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(preLea.port, temLea.port_a) annotation (Line(
points={{20,-20},{20,0},{30,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(withoutMotor.P, P) annotation (Line(
points={{3,6},{12,6},{20,6},{20,40},{110,40}},
color={0,0,127},
Expand All @@ -80,7 +80,7 @@ equation
color={0,0,127},
pattern=LinePattern.Dash));
connect(variableSpeed.ySup, withoutMotor.u) annotation (Line(
points={{-41,54},{-26,54},{-26,6},{-19,6}},
points={{-41,53.8},{-26,53.8},{-26,6},{-19,6}},
color={0,0,127},
pattern=LinePattern.Dash));
connect(variableSpeed.yRet, yRet) annotation (Line(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,12 +138,12 @@ model DuaFanAirHanUnit
equation
connect(cooCoil.port_a_Air, mixingBox.port_Sup) annotation (Line(
points={{-20,0},{-49.8,0},{-49.8,6}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(cooCoil.port_b_Air, supFan.port_a) annotation (Line(
points={{-1.82,0},{28,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(cooCoil.port_a_Wat, port_a_Wat) annotation (Line(
points={{-2,16},{-2,16},{20,16},{20,100}},
color={0,127,255},
Expand All @@ -154,12 +154,12 @@ equation
thickness=1));
connect(mixingBox.port_Fre, port_Fre_Air) annotation (Line(
points={{-70,6},{-70,60},{-100,60}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(retFan.port_a, port_a_Air) annotation (Line(
points={{-10,-80},{46,-80},{100,-80}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(supFan.yRet, retFan.u) annotation (Line(
points={{49,-8.2},{60,-8.2},{60,-74},{-9,-74}},
color={0,0,127},
Expand All @@ -181,21 +181,21 @@ equation
color={0,0,127},
pattern=LinePattern.Dash));
connect(port_Exh_Air, mixingBox.port_Exh) annotation (Line(
points={{-102,0},{-80,0},{-80,-6},{-70,-6}},
color={0,127,255},
thickness=1));
points={{-102,0},{-82,0},{-82,-6},{-70,-6}},
color={0,140,72},
thickness=0.5));
connect(mixingBox.port_Ret, retFan.port_b) annotation (Line(
points={{-50,-5.8},{-40,-5.8},{-40,-80},{-30,-80}},
color={0,127,255},
thickness=1));
points={{-50,-5.8},{-42,-5.8},{-42,-80},{-30,-80}},
color={0,140,72},
thickness=0.5));
connect(port_b_Air, senTemDisAir.port_b) annotation (Line(
points={{100,0},{92,0}},
color={0,127,255},
thickness=1));
connect(senTemDisAir.port_a, supFan.port_b) annotation (Line(
points={{72,0},{48,0}},
color={0,127,255},
thickness=1));
color={0,140,72},
thickness=0.5));
connect(PreMea, add.u1) annotation (Line(
points={{110,60},{86,60},{86,56},{62,56}},
color={0,0,127},
Expand Down Expand Up @@ -259,6 +259,10 @@ equation
Line(points={{20,20},{-40,20}}, color={0,0,255},
thickness=1),
Line(points={{-60,0},{100,0}}, color={0,255,255},
thickness=0.5)}), Diagram(
thickness=0.5),
Text(
extent={{-156,-148},{144,-108}},
textString="%name",
textColor={0,0,255})}), Diagram(
coordinateSystem(preserveAspectRatio=false)));
end DuaFanAirHanUnit;
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ equation
lineColor={0,0,0},
fillColor={255,255,255},
fillPattern=FillPattern.None,
textString="SetPo")}),
textString="SetPo"),
Text(
extent={{-142,122},{158,162}},
textString="%name",
textColor={0,0,255})}),
Diagram(coordinateSystem(preserveAspectRatio=false)));
end SetPoi;
Loading

0 comments on commit f3fcdae

Please sign in to comment.