<?xml version="1.0" encoding="utf-8"?>
<TcPlcObject Version="1.1.0.1" ProductVersion="3.1.4024.9">
  <POU Name="TESTFunctionBlock" Id="{a8362162-207b-4b2b-aa63-613b9540008a}" SpecialFunc="None">
    <Declaration><![CDATA[FUNCTION_BLOCK TESTFunctionBlock
VAR_INPUT
	input1FnBool  : BOOL ;
	input2FnReal  : REAL ;
END_VAR
VAR_OUTPUT
	output1FnBool  : BOOL ;
	output2FnReal  : REAL ;	
END_VAR
VAR_IN_OUT
    bInOut    : BOOL;
	rInOut    : REAL;
END_VAR
VAR
	value1LocalFnBool : BOOL;
	initDone : BOOL := FALSE;
	value2RefFnRealOneTime : REAL := -19.99;
END_VAR

VAR_INPUT PERSISTENT
	value1RefFnBool : BOOL := TRUE;
	value2RefFnReal : REAL := -9.99;
END_VAR]]></Declaration>
    <Implementation>
      <ST><![CDATA[
IF NOT initDone THEN	
	initDone:= TRUE;
	value2RefFnRealOneTime := value2RefFnReal;	
END_IF

IF value1RefFnBool THEN	
output1FnBool := NOT input1FnBool;
output2FnReal :=  input2FnReal * 3.0 ;
ELSE
output1FnBool :=  input1FnBool;
output2FnReal :=  input2FnReal * 2.0 ;	
END_IF

value2RefFnReal := 123.0;

input2FnReal := value2RefFnRealOneTime;

rInOut := value2RefFnRealOneTime;]]></ST>
    </Implementation>
    <Action Name="TestAction" Id="{bd7d8a5c-c60a-4bea-9f00-8b84b35ed4af}">
      <Implementation>
        <ST><![CDATA[]]></ST>
      </Implementation>
    </Action>
    <Method Name="TestMethod" Id="{2f806cb1-f956-46b0-8556-28c1e740afc2}">
      <Declaration><![CDATA[METHOD TestMethod : REAL
VAR_INPUT
	
  A           : REAL;
  B           : REAL;
  
END_VAR
]]></Declaration>
      <Implementation>
        <ST><![CDATA[

TestMethod := A + B;   ]]></ST>
      </Implementation>
    </Method>
    <LineIds Name="TESTFunctionBlock">
      <LineId Id="22" Count="0" />
      <LineId Id="50" Count="0" />
      <LineId Id="54" Count="1" />
      <LineId Id="52" Count="0" />
      <LineId Id="49" Count="0" />
      <LineId Id="20" Count="0" />
      <LineId Id="9" Count="0" />
      <LineId Id="21" Count="0" />
      <LineId Id="25" Count="0" />
      <LineId Id="30" Count="0" />
      <LineId Id="26" Count="1" />
      <LineId Id="57" Count="0" />
      <LineId Id="56" Count="0" />
      <LineId Id="80" Count="0" />
      <LineId Id="79" Count="0" />
      <LineId Id="83" Count="0" />
      <LineId Id="82" Count="0" />
    </LineIds>
    <LineIds Name="TESTFunctionBlock.TestAction">
      <LineId Id="1" Count="0" />
    </LineIds>
    <LineIds Name="TESTFunctionBlock.TestMethod">
      <LineId Id="10" Count="1" />
      <LineId Id="5" Count="0" />
    </LineIds>
  </POU>
</TcPlcObject>