Skip to content

Commit

Permalink
Issue2465 remove and3 (#3490)
Browse files Browse the repository at this point in the history
* moved Add3 and validation to Obsolete, updated revision log, added obsolete markings
  • Loading branch information
hcasperfu authored Aug 31, 2023
1 parent c34386a commit 1ad1579
Show file tree
Hide file tree
Showing 28 changed files with 698 additions and 355 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -201,8 +201,11 @@ protected
Buildings.Controls.OBC.CDL.Integers.Equal intEqu
"Check if operation mode is occupied"
annotation (Placement(transformation(extent={{-160,20},{-140,40}})));
Buildings.Controls.OBC.CDL.Logical.And3 enaMinDam
"Check if the minimum outdoor air damper should be enabled"
Buildings.Controls.OBC.CDL.Logical.And enaMinDam1
"Check if the minimum outdoor air damper should be enabled, one of two stacked And blocks"
annotation (Placement(transformation(extent={{-100,60},{-80,80}})));
Buildings.Controls.OBC.CDL.Logical.And enaMinDam2
"Check if the minimum outdoor air damper should be enabled, one of two stacked And blocks"
annotation (Placement(transformation(extent={{-40,60},{-20,80}})));
Buildings.Controls.OBC.CDL.Reals.Sources.Constant one(
final k=1) "Constant"
Expand Down Expand Up @@ -315,24 +318,20 @@ equation
{-42,-98}}, color={0,0,127}));
connect(moaP.y, gai.u) annotation (Line(points={{-98,-90},{-90,-90},{-90,-120},
{-82,-120}}, color={0,0,127}));
connect(enaMinDam.y, enaRetDamMin.u1) annotation (Line(points={{-18,70},{-10,70},
{-10,10},{38,10}}, color={255,0,255}));
connect(enaMinDam2.y, enaRetDamMin.u1) annotation (Line(points={{-18,70},{-10,
70},{-10,10},{38,10}}, color={255,0,255}));
connect(les.y, enaRetDamMin.u2) annotation (Line(points={{-18,-30},{10,-30},{10,
2},{38,2}}, color={255,0,255}));
connect(enaRetDamMin.y, enaDis.u)
annotation (Line(points={{62,10},{78,10}}, color={255,0,255}));
connect(enaMinDam.y, disMinDam.u) annotation (Line(points={{-18,70},{-10,70},{
-10,-60},{-2,-60}}, color={255,0,255}));
connect(enaMinDam2.y, disMinDam.u) annotation (Line(points={{-18,70},{-10,70},
{-10,-60},{-2,-60}}, color={255,0,255}));
connect(disMinDam.y, disRetDamMin.u1)
annotation (Line(points={{22,-60},{38,-60}}, color={255,0,255}));
connect(gre.y, disRetDamMin.u2) annotation (Line(points={{-18,-90},{30,-90},{30,
-68},{38,-68}},color={255,0,255}));
connect(disRetDamMin.y, enaDis.clr) annotation (Line(points={{62,-60},{70,-60},
{70,4},{78,4}}, color={255,0,255}));
connect(greThr.y, enaMinDam.u1) annotation (Line(points={{-58,150},{-50,150},{
-50,78},{-42,78}}, color={255,0,255}));
connect(intEqu.y, enaMinDam.u3) annotation (Line(points={{-138,30},{-60,30},{-60,
62},{-42,62}}, color={255,0,255}));
connect(minDp.y, maxRetDam.u_s) annotation (Line(points={{-98,170},{118,170}},
color={0,0,127}));
connect(dpMinOutDam, maxRetDam.u_m)
Expand Down Expand Up @@ -361,10 +360,8 @@ equation
annotation (Line(points={{-178,-170},{240,-170}}, color={0,0,127}));
connect(outDamPhyPosMaxSig.y, yOutDam_max)
annotation (Line(points={{-178,-210},{240,-210}}, color={0,0,127}));
connect(enaMinDam.y, y1MinOutDam)
connect(enaMinDam2.y, y1MinOutDam)
annotation (Line(points={{-18,70},{240,70}}, color={255,0,255}));
connect(u1SupFan, enaMinDam.u2)
annotation (Line(points={{-240,70},{-42,70}}, color={255,0,255}));
connect(effAbsOutAir_normalized, pro1.u1) annotation (Line(points={{-240,300},
{-200,300},{-200,306},{-182,306}}, color={0,0,127}));
connect(effAbsOutAir_normalized, pro1.u2) annotation (Line(points={{-240,300},
Expand Down Expand Up @@ -401,6 +398,14 @@ equation
170},{-90,170},{-90,150},{-82,150}}, color={0,0,127}));
connect(one2.y, minDp1.u) annotation (Line(points={{-98,250},{-80,250},{-80,270},
{18,270}}, color={0,0,127}));
connect(intEqu.y, enaMinDam1.u2) annotation (Line(points={{-138,30},{-112,30},
{-112,62},{-102,62}}, color={255,0,255}));
connect(u1SupFan, enaMinDam1.u1)
annotation (Line(points={{-240,70},{-102,70}}, color={255,0,255}));
connect(greThr.y, enaMinDam2.u1) annotation (Line(points={{-58,150},{-52,150},
{-52,70},{-42,70}}, color={255,0,255}));
connect(enaMinDam1.y, enaMinDam2.u2) annotation (Line(points={{-78,70},{-60,70},
{-60,62},{-42,62}}, color={255,0,255}));
annotation (
defaultComponentName="ecoLim",
Icon(coordinateSystem(preserveAspectRatio=false, extent={{-100,-100},{100,100}}),
Expand Down Expand Up @@ -552,6 +557,13 @@ point.
revisions="<html>
<ul>
<li>
August 29, 2023, by Hongxiang Fu:<br/>
Because of the removal of <code>Logical.And3</code> based on ASHRAE 231P,
replaced it with a stack of two <code>Logical.And</code> blocks.
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/2465\">#2465</a>.
</li>
<li>
August 1, 2020, by Jianjun Hu:<br/>
First implementation.
</li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,12 @@ block Enable
annotation (Placement(transformation(extent={{180,-260},{220,-220}}),
iconTransformation(extent={{100,-80},{140,-40}})));

Buildings.Controls.OBC.CDL.Logical.And3 andEnaDis
Buildings.Controls.OBC.CDL.Logical.And andFrePro
"Logical and that checks freeze protection stage"
annotation (Placement(transformation(extent={{-10,30},{10,50}})));
Buildings.Controls.OBC.CDL.Logical.And andEnaDis
"Logical and that checks freeze protection stage and zone state"
annotation (Placement(transformation(extent={{40,30},{60,50}})));
annotation (Placement(transformation(extent={{40,30},{60,50}})));
Buildings.Controls.OBC.CDL.Logical.TrueFalseHold truFalHol(
trueHoldDuration=600) "10 min on/off delay"
annotation (Placement(transformation(extent={{120,210},{140,230}})));
Expand Down Expand Up @@ -209,16 +212,13 @@ equation
{-60,-132},{38,-132}}, color={0,0,127}));
connect(uOutDam_max, maxOutDam.u3) annotation (Line(points={{-200,-130},{-80,-130},
{-80,-148},{38,-148}}, color={0,0,127}));
connect(andEnaDis.y, not2.u)
annotation (Line(points={{62,40},{72,40},{72,-20},{-20,-20},{-20,-60},{-12,-60}},
color={255,0,255}));
connect(andEnaDis.y, not2.u) annotation (Line(points={{62,40},{72,40},{72,-20},
{-20,-20},{-20,-60},{-12,-60}}, color={255,0,255}));
connect(minRetDam.y, yRetDam_min)
annotation (Line(points={{62,-240},{200,-240}}, color={0,0,127}));
connect(truFalHol.y, and1.u1)
annotation (Line(points={{142,220},{164,220},{164,130},{-26,130},{-26,110},{2,110}},
color={255,0,255}));
connect(and1.y, andEnaDis.u1)
annotation (Line(points={{26,110},{30,110},{30,48},{38,48}}, color={255,0,255}));
connect(u1SupFan, and1.u2) annotation (Line(points={{-200,110},{-102,110},{-102,
102},{2,102}}, color={255,0,255}));
connect(retDamPhyMax.y, minRetDam.u1) annotation (Line(points={{-118,-210},
Expand All @@ -241,10 +241,6 @@ equation
annotation (Line(points={{-200,0},{-82,0}}, color={255,127,0}));
connect(uFreProSta, intEqu.u1)
annotation (Line(points={{-200,60},{-82,60}}, color={255,127,0}));
connect(intEqu.y, andEnaDis.u2)
annotation (Line(points={{-58,60},{-10,60},{-10,40},{38,40}}, color={255,0,255}));
connect(not3.y, andEnaDis.u3)
annotation (Line(points={{-22,0},{8,0},{8,32},{38,32}}, color={255,0,255}));
connect(hysOutTem.y, or2.u1)
annotation (Line(points={{-78,250},{-20,250},{-20,220},{38,220}},
color={255,0,255}));
Expand All @@ -254,6 +250,14 @@ equation
{38,212}}, color={255,0,255}));
connect(or2.y, truFalHol.u) annotation (Line(points={{62,220},{118,220}},
color={255,0,255}));
connect(not3.y, andFrePro.u2) annotation (Line(points={{-22,0},{-16,0},{-16,
32},{-12,32}}, color={255,0,255}));
connect(andFrePro.u1, intEqu.y) annotation (Line(points={{-12,40},{-48,40},{-48,
60},{-58,60}}, color={255,0,255}));
connect(and1.y, andEnaDis.u1) annotation (Line(points={{26,110},{32,110},{32,
40},{38,40}}, color={255,0,255}));
connect(andEnaDis.u2, andFrePro.y) annotation (Line(points={{38,32},{20,32},{
20,40},{12,40}}, color={255,0,255}));
annotation (
defaultComponentName = "enaDis",
Icon(graphics={
Expand Down Expand Up @@ -381,6 +385,13 @@ src=\"modelica://Buildings/Resources/Images/Controls/OBC/ASHRAE/G36/AHUs/SingleZ
</html>", revisions="<html>
<ul>
<li>
August 29, 2023, by Hongxiang Fu:<br/>
Because of the removal of <code>Logical.And3</code> based on ASHRAE 231P,
replaced it with a stack of two <code>Logical.And</code> blocks.
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/2465\">#2465</a>.
</li>
<li>
August 1, 2020, by Jianjun Hu:<br/>
Updated according to ASHRAE G36, May 2020.
</li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,9 @@ protected
annotation (Placement(transformation(extent={{-140,-160},{-120,-140}})));
Buildings.Controls.OBC.CDL.Integers.Equal intEqu1 "Check if operation mode is occupied"
annotation (Placement(transformation(extent={{-100,-140},{-80,-120}})));
Buildings.Controls.OBC.CDL.Logical.And3 and3 "Logical and"
Buildings.Controls.OBC.CDL.Logical.And and1 "Logical and"
annotation (Placement(transformation(extent={{-70,-120},{-50,-100}})));
Buildings.Controls.OBC.CDL.Logical.And and2 "Logical and"
annotation (Placement(transformation(extent={{-60,-80},{-40,-60}})));
Buildings.Controls.OBC.CDL.Reals.Switch enaDis2
"Zero minimum damper position when the min OA is near zero"
Expand Down Expand Up @@ -253,13 +255,7 @@ equation
annotation (Line(points={{-102,-98},{-110,-98},{-110,-110},{-118,-110}}, color={255,127,0}));
connect(uFreProSta, intLesEqu.u1)
annotation (Line(points={{-180,-90},{-102,-90}}, color={255,127,0}));
connect(u1SupFan, and3.u1) annotation (Line(points={{-180,-40},{-80,-40},{-80,
-62},{-62,-62}}, color={255,0,255}));
connect(intLesEqu.y, and3.u2) annotation (Line(points={{-78,-90},{-74,-90},{-74,
-70},{-62,-70}}, color={255,0,255}));
connect(intEqu1.y, and3.u3) annotation (Line(points={{-78,-130},{-68,-130},{-68,
-78},{-62,-78}}, color={255,0,255}));
connect(and3.y, not1.u)
connect(and2.y, not1.u)
annotation (Line(points={{-38,-70},{-22,-70}}, color={255,0,255}));
connect(VOutMinSet_flow, noZerMin.u) annotation (Line(points={{-180,180},{-30,
180},{-30,-160},{18,-160}}, color={0,0,127}));
Expand All @@ -272,6 +268,14 @@ equation
connect(zer.y, enaDis2.u3) annotation (Line(points={{102,-190},{110,-190},{110,
-168},{118,-168}}, color={0,0,127}));

connect(intLesEqu.y, and1.u1) annotation (Line(points={{-78,-90},{-74,-90},{-74,
-110},{-72,-110}}, color={255,0,255}));
connect(and1.u2, intEqu1.y) annotation (Line(points={{-72,-118},{-74,-118},{-74,
-130},{-78,-130}}, color={255,0,255}));
connect(and1.y, and2.u2) annotation (Line(points={{-48,-110},{-40,-110},{-40,-86},
{-66,-86},{-66,-78},{-62,-78}}, color={255,0,255}));
connect(u1SupFan, and2.u1) annotation (Line(points={{-180,-40},{-66,-40},{-66,
-70},{-62,-70}}, color={255,0,255}));
annotation (
defaultComponentName = "damLim",
Icon(graphics={
Expand Down Expand Up @@ -444,6 +448,13 @@ src=\"modelica://Buildings/Resources/Images/Controls/OBC/ASHRAE/G36/AHUs/SingleZ
</html>", revisions="<html>
<ul>
<li>
August 29, 2023, by Hongxiang Fu:<br/>
Because of the removal of <code>Logical.And3</code> based on ASHRAE 231P,
replaced it with a stack of two <code>Logical.And</code> blocks.
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/2465\">#2465</a>.
</li>
<li>
August 1, 2020, by Jianjun Hu:<br/>
Updated according to ASHRAE G36, May 2020.
</li>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,11 @@ block Alarms "Generate alarms of cooling only terminal unit"
final h=0.5*damPosHys)
"Check if damper position is near zero"
annotation (Placement(transformation(extent={{-200,-220},{-180,-200}})));
Buildings.Controls.OBC.CDL.Logical.And3 leaDamAla
"Check if generating leak damper alarms"
Buildings.Controls.OBC.CDL.Logical.And leaDamAla1
"Check if generating leak damper alarms, one of two stacked And blocks"
annotation (Placement(transformation(extent={{-100,-180},{-80,-160}})));
Buildings.Controls.OBC.CDL.Logical.And leaDamAla2
"Check if generating leak damper alarms, one of two stacked And blocks"
annotation (Placement(transformation(extent={{-40,-180},{-20,-160}})));
Buildings.Controls.OBC.CDL.Logical.Not not5 "Logical not"
annotation (Placement(transformation(extent={{100,-220},{120,-200}})));
Expand Down Expand Up @@ -276,10 +279,6 @@ equation
annotation (Line(points={{222,150},{260,150}}, color={255,127,0}));
connect(uDam, cloDam.u)
annotation (Line(points={{-260,-210},{-202,-210}}, color={0,0,127}));
connect(u1Fan, leaDamAla.u2) annotation (Line(points={{-260,-100},{-220,-100},
{-220,-170},{-42,-170}},color={255,0,255}));
connect(cloDam.y, leaDamAla.u3) annotation (Line(points={{-178,-210},{-100,-210},
{-100,-178},{-42,-178}}, color={255,0,255}));
connect(not5.y, assMes3.u)
annotation (Line(points={{122,-210},{138,-210}}, color={255,0,255}));
connect(booToInt3.y, yLeaDamAla)
Expand All @@ -300,14 +299,20 @@ equation
annotation (Line(points={{-78,-40},{-42,-40}}, color={255,0,255}));
connect(not3.y, and5.u2) annotation (Line(points={{-178,-100},{-60,-100},{-60,
-48},{-42,-48}}, color={255,0,255}));
connect(gre1.y, leaDamAla.u1) annotation (Line(points={{-78,-40},{-70,-40},{-70,
-162},{-42,-162}}, color={255,0,255}));
connect(leaDamAla.y, truDel3.u)
annotation (Line(points={{-18,-170},{18,-170}}, color={255,0,255}));
connect(truDel3.y, booToInt3.u)
annotation (Line(points={{42,-170},{138,-170}}, color={255,0,255}));
connect(truDel3.y, not5.u) annotation (Line(points={{42,-170},{80,-170},{80,-210},
{98,-210}}, color={255,0,255}));
connect(leaDamAla2.y, truDel3.u)
annotation (Line(points={{-18,-170},{18,-170}}, color={255,0,255}));
connect(gre1.y, leaDamAla2.u1) annotation (Line(points={{-78,-40},{-50,-40},{-50,
-170},{-42,-170}}, color={255,0,255}));
connect(leaDamAla2.u2, leaDamAla1.y) annotation (Line(points={{-42,-178},{-68,
-178},{-68,-170},{-78,-170}}, color={255,0,255}));
connect(leaDamAla1.u1, u1Fan) annotation (Line(points={{-102,-170},{-230,-170},
{-230,-100},{-260,-100}}, color={255,0,255}));
connect(cloDam.y, leaDamAla1.u2) annotation (Line(points={{-178,-210},{-110,-210},
{-110,-178},{-102,-178}}, color={255,0,255}));
annotation (defaultComponentName="ala",
Icon(coordinateSystem(preserveAspectRatio=false, extent={{-100,-100},{100,100}}),
graphics={
Expand Down Expand Up @@ -397,6 +402,13 @@ fan serving the zone is proven on (<code>uFan=true</code>), generate a Level
</html>",revisions="<html>
<ul>
<li>
August 29, 2023, by Hongxiang Fu:<br/>
Because of the removal of <code>Logical.And3</code> based on ASHRAE 231P,
replaced it with a stack of two <code>Logical.And</code> blocks.
This is for
<a href=\"https://github.com/lbl-srg/modelica-buildings/issues/2465\">#2465</a>.
</li>
<li>
August 1, 2020, by Jianjun Hu:<br/>
First implementation.
</li>
Expand Down
Loading

0 comments on commit 1ad1579

Please sign in to comment.