--- a +++ b/examples/Ladder.xml @@ -0,0 +1,735 @@ +<?xml version="1.0" encoding="utf-8"?> +<project xmlns="http://www.plcopen.org/xml/tc6_0200"> + <fileHeader companyName="" productName="CODESYS" productVersion="CODESYS V3.5 SP15" creationDateTime="2020-02-10T18:54:44.558769" /> + <contentHeader name="Ladder.project" modificationDateTime="2020-02-10T18:28:58.901885"> + <coordinateInfo> + <fbd> + <scaling x="1" y="1" /> + </fbd> + <ld> + <scaling x="1" y="1" /> + </ld> + <sfc> + <scaling x="1" y="1" /> + </sfc> + </coordinateInfo> + <addData> + <data name="http://www.3s-software.com/plcopenxml/projectinformation" handleUnknown="implementation"> + <ProjectInformation /> + </data> + </addData> + </contentHeader> + <types> + <dataTypes /> + <pous> + <pou name="PLC_PRG" pouType="program"> + <interface> + <localVars> + <variable name="Variable"> + <type> + <INT /> + </type> + </variable> + <variable name="NameEIGH"> + <type> + <BOOL /> + </type> + </variable> + <variable name="Instance"> + <type> + <derived name="FB_Name8" /> + </type> + </variable> + </localVars> + </interface> + <body> + <LD> + <leftPowerRail localId="0"> + <position x="0" y="0" /> + <connectionPointOut formalParameter="none" /> + </leftPowerRail> + <comment localId="1" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="2"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <comment localId="3" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="4"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <contact localId="6" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <inVariable localId="7"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>Variable</expression> + </inVariable> + <inVariable localId="8"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <inVariable localId="9"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>Variable</expression> + </inVariable> + <inVariable localId="10"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <block localId="5" typeName="F_Name"> + <position x="0" y="0" /> + <inputVariables> + <variable formalParameter="Input_01"> + <connectionPointIn> + <connection refLocalId="6" /> + </connectionPointIn> + </variable> + <variable formalParameter="In_out01"> + <connectionPointIn> + <connection refLocalId="7" /> + </connectionPointIn> + </variable> + <variable formalParameter="InOut2"> + <connectionPointIn> + <connection refLocalId="8" /> + </connectionPointIn> + </variable> + <variable formalParameter="Input2"> + <connectionPointIn> + <connection refLocalId="9" /> + </connectionPointIn> + </variable> + <variable formalParameter="InOut3"> + <connectionPointIn> + <connection refLocalId="10" /> + </connectionPointIn> + </variable> + </inputVariables> + <inOutVariables /> + <outputVariables> + <variable formalParameter=" "> + <connectionPointOut /> + </variable> + <variable formalParameter="Out01"> + <connectionPointOut> + <expression>Variable</expression> + </connectionPointOut> + </variable> + <variable formalParameter="Out02"> + <connectionPointOut> + <expression>Variable</expression> + </connectionPointOut> + </variable> + </outputVariables> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdcalltype" handleUnknown="implementation"> + <CallType xmlns="">function</CallType> + </data> + </addData> + </block> + <coil localId="11" negated="false" storage="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="5" formalParameter=" " /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <comment localId="12" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="13"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <contact localId="15" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="16" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="15" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <inVariable localId="17"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <inVariable localId="18"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <inVariable localId="19"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <block localId="14" typeName="FB_Name8" instanceName="Instance"> + <position x="0" y="0" /> + <inputVariables> + <variable formalParameter="EN"> + <connectionPointIn> + <connection refLocalId="16" /> + </connectionPointIn> + </variable> + <variable formalParameter="Input_01"> + <connectionPointIn> + <connection refLocalId="17" /> + </connectionPointIn> + </variable> + <variable formalParameter="In_out01"> + <connectionPointIn> + <connection refLocalId="18" /> + </connectionPointIn> + </variable> + <variable formalParameter="InOut2"> + <connectionPointIn> + <connection refLocalId="19" /> + </connectionPointIn> + </variable> + </inputVariables> + <inOutVariables /> + <outputVariables> + <variable formalParameter="ENO"> + <connectionPointOut /> + </variable> + <variable formalParameter="Out01"> + <connectionPointOut> + <expression>???</expression> + </connectionPointOut> + </variable> + </outputVariables> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdcalltype" handleUnknown="implementation"> + <CallType xmlns="">functionblock</CallType> + </data> + </addData> + </block> + <coil localId="20" negated="false" storage="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="14" formalParameter="ENO" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <comment localId="21" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="22"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <contact localId="24" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <inVariable localId="25"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>Variable</expression> + </inVariable> + <inVariable localId="26"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <inVariable localId="27"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>Variable</expression> + </inVariable> + <inVariable localId="28"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <inVariable localId="29"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>???</expression> + </inVariable> + <block localId="23" typeName="F_Name"> + <position x="0" y="0" /> + <inputVariables> + <variable formalParameter="EN"> + <connectionPointIn> + <connection refLocalId="24" /> + </connectionPointIn> + </variable> + <variable formalParameter="Input_01"> + <connectionPointIn> + <connection refLocalId="25" /> + </connectionPointIn> + </variable> + <variable formalParameter="In_out01"> + <connectionPointIn> + <connection refLocalId="26" /> + </connectionPointIn> + </variable> + <variable formalParameter="InOut2"> + <connectionPointIn> + <connection refLocalId="27" /> + </connectionPointIn> + </variable> + <variable formalParameter="Input2"> + <connectionPointIn> + <connection refLocalId="28" /> + </connectionPointIn> + </variable> + <variable formalParameter="InOut3"> + <connectionPointIn> + <connection refLocalId="29" /> + </connectionPointIn> + </variable> + </inputVariables> + <inOutVariables /> + <outputVariables> + <variable formalParameter="ENO"> + <connectionPointOut /> + </variable> + <variable formalParameter=" "> + <connectionPointOut> + <expression>Variable</expression> + </connectionPointOut> + </variable> + <variable formalParameter="Out01"> + <connectionPointOut> + <expression>Variable</expression> + </connectionPointOut> + </variable> + <variable formalParameter="Out02"> + <connectionPointOut> + <expression>???</expression> + </connectionPointOut> + </variable> + </outputVariables> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdcalltype" handleUnknown="implementation"> + <CallType xmlns="">function</CallType> + </data> + </addData> + </block> + <coil localId="30" negated="false" storage="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="23" formalParameter="ENO" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <comment localId="31" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <label localId="32" label="myLabel"> + <position x="0" y="0" /> + </label> + <vendorElement localId="33"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <contact localId="34" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="35" negated="true" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="34" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <coil localId="36" negated="false" storage="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="35" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <comment localId="37" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="38"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <contact localId="39" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="40" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="41" negated="true" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="39" /> + <connection refLocalId="40" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="42" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="39" /> + <connection refLocalId="40" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="43" negated="true" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="42" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <coil localId="44" negated="false" storage="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="41" /> + <connection refLocalId="43" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <comment localId="45" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="46"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <contact localId="47" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <coil localId="48" negated="false" storage="set"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="47" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <coil localId="49" negated="false" storage="reset"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="47" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <comment localId="50" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="51"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <contact localId="53" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="0" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="54" negated="true" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="53" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <contact localId="56" negated="false" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="53" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <inVariable localId="57"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>Variable</expression> + </inVariable> + <inVariable localId="58"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>Variable</expression> + </inVariable> + <inVariable localId="59"> + <position x="0" y="0" /> + <connectionPointOut /> + <expression>Variable</expression> + </inVariable> + <block localId="55" typeName="FB_Name8" instanceName="Instance"> + <position x="0" y="0" /> + <inputVariables> + <variable formalParameter="EN"> + <connectionPointIn> + <connection refLocalId="56" /> + </connectionPointIn> + </variable> + <variable formalParameter="Input_01"> + <connectionPointIn> + <connection refLocalId="57" /> + </connectionPointIn> + </variable> + <variable formalParameter="In_out01"> + <connectionPointIn> + <connection refLocalId="58" /> + </connectionPointIn> + </variable> + <variable formalParameter="InOut2"> + <connectionPointIn> + <connection refLocalId="59" /> + </connectionPointIn> + </variable> + </inputVariables> + <inOutVariables /> + <outputVariables> + <variable formalParameter="ENO"> + <connectionPointOut /> + </variable> + <variable formalParameter="Out01"> + <connectionPointOut> + <expression>Variable</expression> + </connectionPointOut> + </variable> + </outputVariables> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdcalltype" handleUnknown="implementation"> + <CallType xmlns="">functionblock</CallType> + </data> + </addData> + </block> + <contact localId="60" negated="true" storage="none" edge="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="55" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </contact> + <vendorElement localId="52"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml">ParallelBranch</xhtml> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/ldparallelbranch" handleUnknown="implementation"> + <ParallelBranch mode="sce" xmlns=""> + <BranchInput> + <connectionPointIn> + <connection refLocalId="53" /> + </connectionPointIn> + </BranchInput> + <BranchTrees> + <Tree> + <connectionPointIn> + <connection refLocalId="54" /> + </connectionPointIn> + </Tree> + <Tree> + <connectionPointIn> + <connection refLocalId="60" /> + </connectionPointIn> + </Tree> + </BranchTrees> + </ParallelBranch> + </data> + </addData> + </vendorElement> + <coil localId="61" negated="false" storage="none"> + <position x="0" y="0" /> + <connectionPointIn> + <connection refLocalId="54" /> + <connection refLocalId="60" /> + </connectionPointIn> + <connectionPointOut /> + <variable>NameEIGH</variable> + </coil> + <comment localId="62" height="0" width="0"> + <position x="0" y="0" /> + <content> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </content> + </comment> + <vendorElement localId="63"> + <position x="0" y="0" /> + <alternativeText> + <xhtml xmlns="http://www.w3.org/1999/xhtml" /> + </alternativeText> + <addData> + <data name="http://www.3s-software.com/plcopenxml/fbdelementtype" handleUnknown="implementation"> + <ElementType xmlns="">networktitle</ElementType> + </data> + </addData> + </vendorElement> + <rightPowerRail localId="2147483646"> + <position x="0" y="0" /> + <connectionPointIn /> + </rightPowerRail> + </LD> + </body> + <addData> + <data name="http://www.3s-software.com/plcopenxml/interfaceasplaintext" handleUnknown="implementation"> + <InterfaceAsPlainText> + <xhtml xmlns="http://www.w3.org/1999/xhtml">PROGRAM PLC_PRG +VAR + Variable: Int; + NameEIGH: BOOL; + Instance: FB_Name8; +END_VAR</xhtml> + </InterfaceAsPlainText> + </data> + <data name="http://www.3s-software.com/plcopenxml/objectid" handleUnknown="discard"> + <ObjectId>e82f40de-6e1c-41ca-914b-c14242f1c640</ObjectId> + </data> + </addData> + </pou> + </pous> + </types> + <instances> + <configurations /> + </instances> + <addData> + <data name="http://www.3s-software.com/plcopenxml/projectstructure" handleUnknown="discard"> + <ProjectStructure> + <Object Name="PLC_PRG" ObjectId="e82f40de-6e1c-41ca-914b-c14242f1c640" /> + </ProjectStructure> + </data> + </addData> +</project> \ No newline at end of file