<?xml version="1.0" encoding="UTF-8"?>
<Operator xmlns="http://www.esterel-technologies.com/ns/scade/6" xmlns:ed="http://www.esterel-technologies.com/ns/scade/pragmas/editor/5" xmlns:kcg="http://www.esterel-technologies.com/ns/scade/pragmas/codegen/3" kind="node" visibility="private" name="manage_payload_boarding">
	<inputs>
		<Variable name="bay_switch_open">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/28ff/6F08/E3C/594773672af8"/>
				<kcg:Pragma>
					doc &quot;Unit_2&quot; {Unit = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Comment_1&quot; {Comment = &quot;bay switch status true = OPEN false = CLOSED&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Range_3&quot; {Range = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Resolution_4&quot; {Resolution = &quot;TBD&quot;}
				</kcg:Pragma>
			</pragmas>
		</Variable>
		<Variable name="payload_mass_in">
			<type>
				<NamedType>
					<type>
						<TypeRef name="types_mm::mass_t"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/2a68/6F08/E3C/594776292186"/>
				<kcg:Pragma>
					doc &quot;Unit_2&quot; {Unit = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Comment_1&quot; {Comment = &quot;&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Range_3&quot; {Range = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Resolution_4&quot; {Resolution = &quot;TBD&quot;}
				</kcg:Pragma>
			</pragmas>
		</Variable>
	</inputs>
	<outputs>
		<Variable name="payload_mass">
			<type>
				<NamedType>
					<type>
						<TypeRef name="types_mm::mass_t"/>
					</type>
				</NamedType>
			</type>
			<default>
				<ConstValue value="0.0"/>
			</default>
			<pragmas>
				<ed:Variable oid="!ed/2833/1042/DCC/594cb91134b"/>
				<kcg:Pragma>
					doc &quot;Unit_2&quot; {Unit = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Comment_1&quot; {Comment = &quot;&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Range_3&quot; {Range = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Resolution_4&quot; {Resolution = &quot;TBD&quot;}
				</kcg:Pragma>
			</pragmas>
		</Variable>
		<Variable name="boarding_ended">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<default>
				<ConstValue value="false"/>
			</default>
			<pragmas>
				<ed:Variable oid="!ed/2842/1042/DCC/594cb9789bc"/>
				<kcg:Pragma>
					doc &quot;Unit_2&quot; {Unit = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Comment_1&quot; {Comment = &quot;&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Range_3&quot; {Range = &quot;TBD&quot;}
				</kcg:Pragma>
				<kcg:Pragma>
					doc &quot;Resolution_4&quot; {Resolution = &quot;TBD&quot;}
				</kcg:Pragma>
			</pragmas>
		</Variable>
	</outputs>
	<locals>
		<Variable name="LL_valve_opening">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/299c/6F08/E3C/59477478729f"/>
			</pragmas>
		</Variable>
		<Variable name="LL_valve_closing">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/29f4/6F08/E3C/59477550136e"/>
			</pragmas>
		</Variable>
		<Variable name="_L2">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/299b/6F08/E3C/594774725267"/>
			</pragmas>
		</Variable>
		<Variable name="_L1">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/2999/6F08/E3C/594774727453"/>
			</pragmas>
		</Variable>
		<Variable name="_L3">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/29e6/6F08/E3C/5947751476aa"/>
			</pragmas>
		</Variable>
		<Variable name="_L4">
			<type>
				<NamedType>
					<type>
						<TypeRef name="bool"/>
					</type>
				</NamedType>
			</type>
			<pragmas>
				<ed:Variable oid="!ed/29f3/6F08/E3C/59477548228f"/>
			</pragmas>
		</Variable>
	</locals>
	<data>
		<StateMachine name="board_payload">
			<states>
				<State initial="true" name="Init_Boarding">
					<unless>
						<Transition kind="restart">
							<target>
								<StateRef name="Board_Payload"/>
							</target>
							<condition>
								<IdExpression>
									<path>
										<ConstVarRef name="LL_valve_opening"/>
									</path>
								</IdExpression>
							</condition>
							<pragmas>
								<ed:Transition oid="!ed/2a18/6F08/E3C/59477598407f"/>
							</pragmas>
						</Transition>
					</unless>
					<pragmas>
						<ed:State oid="!ed/2900/6F08/E3C/594773a23967"/>
					</pragmas>
				</State>
				<State name="Board_Payload">
					<unless>
						<Transition kind="restart">
							<target>
								<StateRef name="End_Boarding"/>
							</target>
							<condition>
								<IdExpression>
									<path>
										<ConstVarRef name="LL_valve_closing"/>
									</path>
								</IdExpression>
							</condition>
							<pragmas>
								<ed:Transition oid="!ed/2a35/6F08/E3C/594775ae6931"/>
							</pragmas>
						</Transition>
					</unless>
					<pragmas>
						<ed:State oid="!ed/29fa/6F08/E3C/5947756d4081"/>
					</pragmas>
				</State>
				<State name="End_Boarding">
					<locals>
						<Variable name="_L1">
							<type>
								<NamedType>
									<type>
										<TypeRef name="types_mm::mass_t"/>
									</type>
								</NamedType>
							</type>
							<pragmas>
								<ed:Variable oid="!ed/2aa2/6F08/E3C/5947767e5cab"/>
							</pragmas>
						</Variable>
						<Variable name="_L2">
							<type>
								<NamedType>
									<type>
										<TypeRef name="bool"/>
									</type>
								</NamedType>
							</type>
							<pragmas>
								<ed:Variable oid="!ed/2aa9/6F08/E3C/594776891122"/>
							</pragmas>
						</Variable>
					</locals>
					<data>
						<!-- _L1 = payload_mass_in; -->
						<Equation>
							<lefts>
								<VariableRef name="_L1"/>
							</lefts>
							<right>
								<IdExpression>
									<path>
										<ConstVarRef name="payload_mass_in"/>
									</path>
								</IdExpression>
							</right>
							<pragmas>
								<ed:Equation oid="!ed/2aa1/6F08/E3C/5947767e6e24"/>
							</pragmas>
						</Equation>
						<!-- _L2 = true; -->
						<Equation>
							<lefts>
								<VariableRef name="_L2"/>
							</lefts>
							<right>
								<ConstValue value="true"/>
							</right>
							<pragmas>
								<ed:Equation oid="!ed/2aa8/6F08/E3C/594776893566"/>
							</pragmas>
						</Equation>
						<!-- payload_mass = _L1; -->
						<Equation>
							<lefts>
								<VariableRef name="payload_mass"/>
							</lefts>
							<right>
								<IdExpression>
									<path>
										<ConstVarRef name="_L1"/>
									</path>
								</IdExpression>
							</right>
							<pragmas>
								<ed:Equation oid="!ed/2834/1042/DCC/594cb929663d"/>
							</pragmas>
						</Equation>
						<!-- boarding_ended = _L2; -->
						<Equation>
							<lefts>
								<VariableRef name="boarding_ended"/>
							</lefts>
							<right>
								<IdExpression>
									<path>
										<ConstVarRef name="_L2"/>
									</path>
								</IdExpression>
							</right>
							<pragmas>
								<ed:Equation oid="!ed/2843/1042/DCC/594cb97f7675"/>
							</pragmas>
						</Equation>
					</data>
					<pragmas>
						<ed:State oid="!ed/2a02/6F08/E3C/5947757c44cd"/>
					</pragmas>
				</State>
			</states>
			<pragmas>
				<ed:StateMachine oid="!ed/28f7/6F08/E3C/594773426495"/>
			</pragmas>
		</StateMachine>
		<!-- _L1 = utl_mm::RisingEdge(_L2); -->
		<Equation>
			<lefts>
				<VariableRef name="_L1"/>
			</lefts>
			<right>
				<!-- utl_mm::RisingEdge(_L2) -->
				<CallExpression>
					<operator>
						<OpCall name="1">
							<operator>
								<OperatorRef name="utl_mm::RisingEdge"/>
							</operator>
						</OpCall>
					</operator>
					<callParameters>
						<IdExpression>
							<path>
								<ConstVarRef name="_L2"/>
							</path>
						</IdExpression>
					</callParameters>
				</CallExpression>
			</right>
			<pragmas>
				<ed:Equation oid="!ed/2998/6F08/E3C/594774724eb4"/>
			</pragmas>
		</Equation>
		<!-- _L2 = bay_switch_open; -->
		<Equation>
			<lefts>
				<VariableRef name="_L2"/>
			</lefts>
			<right>
				<IdExpression>
					<path>
						<ConstVarRef name="bay_switch_open"/>
					</path>
				</IdExpression>
			</right>
			<pragmas>
				<ed:Equation oid="!ed/299a/6F08/E3C/594774723921"/>
			</pragmas>
		</Equation>
		<!-- LL_valve_opening = _L1; -->
		<Equation>
			<lefts>
				<VariableRef name="LL_valve_opening"/>
			</lefts>
			<right>
				<IdExpression>
					<path>
						<ConstVarRef name="_L1"/>
					</path>
				</IdExpression>
			</right>
			<pragmas>
				<ed:Equation oid="!ed/299d/6F08/E3C/5947748a2049"/>
			</pragmas>
		</Equation>
		<!-- _L3 = utl_mm::FallingEdge(_L4); -->
		<Equation>
			<lefts>
				<VariableRef name="_L3"/>
			</lefts>
			<right>
				<!-- utl_mm::FallingEdge(_L4) -->
				<CallExpression>
					<operator>
						<OpCall name="1">
							<operator>
								<OperatorRef name="utl_mm::FallingEdge"/>
							</operator>
						</OpCall>
					</operator>
					<callParameters>
						<IdExpression>
							<path>
								<ConstVarRef name="_L4"/>
							</path>
						</IdExpression>
					</callParameters>
				</CallExpression>
			</right>
			<pragmas>
				<ed:Equation oid="!ed/29e5/6F08/E3C/594775147072"/>
			</pragmas>
		</Equation>
		<!-- _L4 = bay_switch_open; -->
		<Equation>
			<lefts>
				<VariableRef name="_L4"/>
			</lefts>
			<right>
				<IdExpression>
					<path>
						<ConstVarRef name="bay_switch_open"/>
					</path>
				</IdExpression>
			</right>
			<pragmas>
				<ed:Equation oid="!ed/29f2/6F08/E3C/594775485fba"/>
			</pragmas>
		</Equation>
		<!-- LL_valve_closing = _L3; -->
		<Equation>
			<lefts>
				<VariableRef name="LL_valve_closing"/>
			</lefts>
			<right>
				<IdExpression>
					<path>
						<ConstVarRef name="_L3"/>
					</path>
				</IdExpression>
			</right>
			<pragmas>
				<ed:Equation oid="!ed/29f5/6F08/E3C/5947755a6862"/>
			</pragmas>
		</Equation>
	</data>
	<pragmas>
		<ed:Operator oid="!ed/2917/623E/DF0/594380793291" xmlns="http://www.esterel-technologies.com/ns/scade/pragmas/editor/5">
			<diagrams>
				<NetDiagram name="manage_payload_boarding_1" landscape="true" format="A4 (210 297)" oid="!ed/2918/623E/DF0/594380796a8">
					<presentationElements>
						<StateMachineGE presentable="!ed/28f7/6F08/E3C/594773426495">
							<position>
								<Point x="5948" y="6181"/>
							</position>
							<size>
								<Size width="12912" height="5228"/>
							</size>
						</StateMachineGE>
						<StateGE presentable="!ed/2900/6F08/E3C/594773a23967">
							<position>
								<Point x="6392" y="6562"/>
							</position>
							<size>
								<Size width="2964" height="1016"/>
							</size>
						</StateGE>
						<EquationGE presentable="!ed/2998/6F08/E3C/594774724eb4">
							<position>
								<Point x="3294" y="4098"/>
							</position>
							<size>
								<Size width="3360" height="715"/>
							</size>
						</EquationGE>
						<EquationGE presentable="!ed/299a/6F08/E3C/594774723921">
							<position>
								<Point x="2582" y="4191"/>
							</position>
							<size>
								<Size width="254" height="508"/>
							</size>
						</EquationGE>
						<EquationGE presentable="!ed/299d/6F08/E3C/5947748a2049">
							<position>
								<Point x="7345" y="4191"/>
							</position>
							<size>
								<Size width="360" height="508"/>
							</size>
						</EquationGE>
						<EquationGE presentable="!ed/29e5/6F08/E3C/594775147072">
							<position>
								<Point x="3302" y="5165"/>
							</position>
							<size>
								<Size width="3360" height="714"/>
							</size>
						</EquationGE>
						<EquationGE presentable="!ed/29f2/6F08/E3C/594775485fba">
							<position>
								<Point x="2582" y="5249"/>
							</position>
							<size>
								<Size width="254" height="508"/>
							</size>
						</EquationGE>
						<Edge leftVarIndex="1" rightExprIndex="1" srcEquation="!ed/29f2/6F08/E3C/594775485fba" dstEquation="!ed/29e5/6F08/E3C/594775147072">
							<positions>
								<Point x="2836" y="5503"/>
								<Point x="3069" y="5503"/>
								<Point x="3069" y="5503"/>
								<Point x="3302" y="5503"/>
							</positions>
						</Edge>
						<EquationGE presentable="!ed/29f5/6F08/E3C/5947755a6862">
							<position>
								<Point x="7451" y="5271"/>
							</position>
							<size>
								<Size width="359" height="508"/>
							</size>
						</EquationGE>
						<Edge leftVarIndex="1" rightExprIndex="1" srcEquation="!ed/29e5/6F08/E3C/594775147072" dstEquation="!ed/29f5/6F08/E3C/5947755a6862">
							<positions>
								<Point x="6668" y="5525"/>
								<Point x="7049" y="5525"/>
								<Point x="7049" y="5525"/>
								<Point x="7451" y="5525"/>
							</positions>
						</Edge>
						<StateGE presentable="!ed/29fa/6F08/E3C/5947756d4081">
							<position>
								<Point x="6308" y="8911"/>
							</position>
							<size>
								<Size width="3027" height="1651"/>
							</size>
						</StateGE>
						<StateGE presentable="!ed/2a02/6F08/E3C/5947757c44cd">
							<position>
								<Point x="10922" y="6414"/>
							</position>
							<size>
								<Size width="7176" height="4340"/>
							</size>
						</StateGE>
						<TransitionGE presentable="!ed/2a18/6F08/E3C/59477598407f">
							<positions>
								<Point x="8043" y="7578"/>
								<Point x="8065" y="7768"/>
								<Point x="6710" y="8721"/>
								<Point x="6773" y="8911"/>
							</positions>
							<labelSize>
								<Size width="3196" height="381"/>
							</labelSize>
							<labelPos>
								<Point x="6519" y="7663"/>
							</labelPos>
							<slashPos>
								<Point x="8996" y="7662"/>
							</slashPos>
						</TransitionGE>
						<TransitionGE presentable="!ed/2a35/6F08/E3C/594775ae6931">
							<positions>
								<Point x="9335" y="9673"/>
								<Point x="9694" y="9652"/>
								<Point x="10520" y="9673"/>
								<Point x="10922" y="9652"/>
							</positions>
							<labelSize>
								<Size width="3196" height="381"/>
							</labelSize>
							<labelPos>
								<Point x="8275" y="8552"/>
							</labelPos>
							<slashPos>
								<Point x="10753" y="8551"/>
							</slashPos>
						</TransitionGE>
						<EquationGE presentable="!ed/2aa1/6F08/E3C/5947767e6e24">
							<position>
								<Point x="13526" y="8636"/>
							</position>
							<size>
								<Size width="254" height="508"/>
							</size>
						</EquationGE>
						<EquationGE kind="OBJ_LIT" presentable="!ed/2aa8/6F08/E3C/594776893566">
							<position>
								<Point x="11917" y="7747"/>
							</position>
							<size>
								<Size width="170" height="318"/>
							</size>
						</EquationGE>
						<EquationGE presentable="!ed/2834/1042/DCC/594cb929663d">
							<position>
								<Point x="14817" y="8636"/>
							</position>
							<size>
								<Size width="338" height="508"/>
							</size>
						</EquationGE>
						<Edge leftVarIndex="1" rightExprIndex="1" srcEquation="!ed/2aa1/6F08/E3C/5947767e6e24" dstEquation="!ed/2834/1042/DCC/594cb929663d">
							<positions>
								<Point x="13780" y="8890"/>
								<Point x="14309" y="8890"/>
								<Point x="14309" y="8890"/>
								<Point x="14859" y="8890"/>
							</positions>
						</Edge>
						<EquationGE presentable="!ed/2843/1042/DCC/594cb97f7675">
							<position>
								<Point x="14817" y="7662"/>
							</position>
							<size>
								<Size width="339" height="508"/>
							</size>
						</EquationGE>
						<Edge leftVarIndex="1" rightExprIndex="1" srcEquation="!ed/2aa8/6F08/E3C/594776893566" dstEquation="!ed/2843/1042/DCC/594cb97f7675">
							<positions>
								<Point x="12086" y="7916"/>
								<Point x="13653" y="7916"/>
								<Point x="13653" y="7916"/>
								<Point x="14859" y="7916"/>
							</positions>
						</Edge>
						<Edge leftVarIndex="1" rightExprIndex="1" srcEquation="!ed/2998/6F08/E3C/594774724eb4" dstEquation="!ed/299d/6F08/E3C/5947748a2049">
							<positions>
								<Point x="6646" y="4466"/>
								<Point x="6985" y="4466"/>
								<Point x="6985" y="4466"/>
								<Point x="7345" y="4466"/>
							</positions>
						</Edge>
						<Edge leftVarIndex="1" rightExprIndex="1" srcEquation="!ed/299a/6F08/E3C/594774723921" dstEquation="!ed/2998/6F08/E3C/594774724eb4">
							<positions>
								<Point x="2836" y="4445"/>
								<Point x="3069" y="4445"/>
								<Point x="3069" y="4445"/>
								<Point x="3302" y="4445"/>
							</positions>
						</Edge>
					</presentationElements>
				</NetDiagram>
			</diagrams>
		</ed:Operator>
		<kcg:Pragma>
			doc &quot;OperatorKind_1&quot; {OperatorKind = &quot;TBD&quot;}
		</kcg:Pragma>
		<kcg:Pragma>
			doc &quot;Title_1&quot; {Title = &quot;Title : manage_payload_boarding_1&quot;}
		</kcg:Pragma>
		<kcg:Pragma>
			doc &quot;Author_2&quot; {Author = &quot; Modified by: AP. PORTE&quot;}
		</kcg:Pragma>
		<kcg:Pragma>
			doc &quot;Date_3&quot; {Date = &quot;06/06/2017&quot;}
		</kcg:Pragma>
		<kcg:Pragma>
			doc &quot;CopyRight_4&quot; {CopyRight = &quot; (C) ZSSM. All rights reserved.&quot;}
		</kcg:Pragma>
		<kcg:Pragma>
			doc &quot;Description_5&quot; {Description = &quot; Description: A payload boarding sequence consists in  1.&#x9;The bay is opened using the BAY SWITCH (Bayswitch is set to OPEN) 2.&#x9;The payload is boarded in the bay 3.&#x9;The bay is closed using the BAY SWITCH (Bayswitch is set to CLOSED) &quot;}
		</kcg:Pragma>
		<kcg:Pragma>
			doc &quot;Change_6&quot; {Change = &quot; PR: First issue - No change.&quot;}
		</kcg:Pragma>
	</pragmas>
</Operator>
