﻿<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<RSLogix5000Content SchemaRevision="1.0" SoftwareRevision="16.03" TargetType="AddOnInstructionDefinition" ContainsContext="true" Owner="Mettler-Toledo Inc., Mettler-Toledo Inc." ExportDate="Thu Jul 29 11:08:29 2010" ExportOptions="Context">
<Controller Use="Context" Name="General_Testing">
<AddOnInstructionDefinitions Use="Context">
<AddOnInstructionDefinition Use="Target" Name="IND131_331_IntDiv_Input_Data" Revision="1.0" ExecutePrescan="false" ExecutePostscan="false" ExecuteEnableInFalse="false" CreatedDate="2008-04-02T15:41:18.953Z" CreatedBy="Not Available" EditedDate="2010-07-29T13:50:37.226Z" EditedBy="AM\findley-1" SoftwareRevision="v16.03"
>
<Description>
<![CDATA[Integer/Divisions input data parsing]]>
</Description>
<AdditionalHelpText>
<![CDATA[Slot_Input_1st_INT is data type INT; must point to the first Integer of the input message
Slot_Input_2nd_INT is data type INT; must point to the second Integer of the input message.
Increment_Size is data type REAL; must match scale calibration increment size; default is one (1).
Use_Divisions is a data Type BOOL set to ON (1) if Divisions Data Type is used; default is Integer Data Type.]]>
</AdditionalHelpText>
<Parameters>
<Parameter Name="Input_1st_INT" DataType="INT" Usage="InOut" Radix="Decimal" Required="true" Visible="true">
<Description>
<![CDATA[1st Word of Input Data]]>
</Description>
<Comments>
<Comment Operand="[0]" Unused="true">
<![CDATA[Weight input data]]>
</Comment>
<Comment Operand="[1]" Unused="true">
<![CDATA[Status Input Data]]>
</Comment>
</Comments>
</Parameter>
<Parameter Name="Input_2nd_INT" DataType="INT" Usage="InOut" Radix="Decimal" Required="true" Visible="true">
<Description>
<![CDATA[2nd Word of Input Data]]>
</Description>
</Parameter>
<Parameter Name="Increment_Size" DataType="REAL" Usage="Input" Radix="Float" Required="false" Visible="true">
<Description>
<![CDATA[Scale Calibration Increment Size]]>
</Description>
<DefaultData>00 00 00 00</DefaultData>
</Parameter>
<Parameter Name="Use_Divisions" DataType="BOOL" Usage="Input" Radix="Decimal" Required="false" Visible="true">
<Description>
<![CDATA[Perform Divisions convertion]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Weight" DataType="REAL" Usage="Output" Radix="Float" Required="false" Visible="false">
<Description>
<![CDATA[Weight Data in a Real]]>
</Description>
<DefaultData>00 00 00 00</DefaultData>
</Parameter>
<Parameter Name="Feed_Under" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Target Feed bit or Over/Under logic OK bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="FastFeed_OK" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Target Fast Feed bit or Over/Under logic OK bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="TolOK_Over" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Target Tolerance OK bit or Over/Under Logic Over bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Compar_3" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Comparator 3 Status bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Compar_2" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Comparator 2 Status bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Compar_1" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Comparator 1 Status bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Discrete_In_1" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Input 1 (0.0.1) status bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Discrete_In_2" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Input 2 (0.0.2) status bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Motion" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Motion Status bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Net_Mode" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Net Mode Status bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="UpDate_InProcess" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Update in Process bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
<Parameter Name="Data_OK" DataType="BOOL" Usage="Output" Radix="Decimal" Required="false" Visible="false">
<Description>
<![CDATA[Data OK bit]]>
</Description>
<DefaultData>00</DefaultData>
</Parameter>
</Parameters>
<LocalTags>
<LocalTag Name="Inc_Mulitiplier" DataType="REAL" Radix="Float">
<DefaultData>00 00 00 00</DefaultData>
</LocalTag>
<LocalTag Name="Inc_Divider" DataType="REAL" Radix="Float">
<DefaultData>00 00 00 00</DefaultData>
</LocalTag>
</LocalTags>
<Routines>
<Routine Name="Logic" Type="RLL">
<RLLContent>
<Rung Number="0" Type="N">
<Comment>
<![CDATA[Calulation of the math component needed to convert the weight data to a REAL using the Increment size.
Increment size is 1, 2 or 5.]]>
</Comment>
<Text>
<![CDATA[LIM(1,Increment_Size,5)[EQU(Increment_Size,5) MOV(0.2,Inc_Divider) ,EQU(Increment_Size,2) MOV(0.5,Inc_Divider) ,EQU(Increment_Size,1) MOV(1,Inc_Divider) ,MOV(1,Inc_Mulitiplier) ];]]>
</Text>
</Rung>
<Rung Number="1" Type="N">
<Comment>
<![CDATA[Calulation of the math component needed to convert the weight data to a REAL using the Increment size.
Increment size is 10, 20 or 50.]]>
</Comment>
<Text>
<![CDATA[LIM(10,Increment_Size,50)[EQU(Increment_Size,50) MOV(0.02,Inc_Divider) ,EQU(Increment_Size,20) MOV(0.05,Inc_Divider) ,EQU(Increment_Size,10) MOV(0.01,Inc_Divider) ,MOV(10,Inc_Mulitiplier) ];]]>
</Text>
</Rung>
<Rung Number="2" Type="N">
<Comment>
<![CDATA[Calulation of the math component needed to convert the weight data to a REAL using the Increment size.
Increment size is 100, 200 or 500.]]>
</Comment>
<Text>
<![CDATA[LIM(100,Increment_Size,500)[EQU(Increment_Size,500) MOV(0.002,Inc_Divider) ,EQU(Increment_Size,200) MOV(0.005,Inc_Divider) ,EQU(Increment_Size,100) MOV(0.001,Inc_Divider) ,MOV(100,Inc_Mulitiplier) ];]]>
</Text>
</Rung>
<Rung Number="3" Type="N">
<Comment>
<![CDATA[Calulation of the math component needed to convert the weight data to a REAL using the Increment size.
Increment size is 0.1, 0.2 or 0.5.]]>
</Comment>
<Text>
<![CDATA[LIM(0.1,Increment_Size,0.5)[EQU(Increment_Size,0.5) MOV(2,Inc_Divider) ,EQU(Increment_Size,0.2) MOV(5,Inc_Divider) ,EQU(Increment_Size,0.1) MOV(10,Inc_Divider) ,MOV(0.1,Inc_Mulitiplier) ];]]>
</Text>
</Rung>
<Rung Number="4" Type="N">
<Comment>
<![CDATA[Calulation of the math component needed to convert the weight data to a REAL using the Increment size.
Increment size is 0.01, 0.02 or 0.05.]]>
</Comment>
<Text>
<![CDATA[LIM(0.01,Increment_Size,0.05)[EQU(Increment_Size,0.05) MOV(20,Inc_Divider) ,EQU(Increment_Size,0.02) MOV(50,Inc_Divider) ,EQU(Increment_Size,0.01) MOV(100,Inc_Divider) ,MOV(0.01,Inc_Mulitiplier) ];]]>
</Text>
</Rung>
<Rung Number="5" Type="N">
<Comment>
<![CDATA[Calulation of the math component needed to convert the weight data to a REAL using the Increment size.
Increment size is 0.001, 0.002 or 0.005.]]>
</Comment>
<Text>
<![CDATA[LIM(0.001,Increment_Size,0.005)[EQU(Increment_Size,0.005) MOV(200,Inc_Divider) ,EQU(Increment_Size,0.002) MOV(500,Inc_Divider) ,EQU(Increment_Size,0.001) MOV(1000,Inc_Divider) ,MOV(0.001,Inc_Mulitiplier) ];]]>
</Text>
</Rung>
<Rung Number="6" Type="N">
<Comment>
<![CDATA[If no increment size entered then default is 1.]]>
</Comment>
<Text>
<![CDATA[EQU(Increment_Size,0)[MOV(1,Inc_Divider) ,MOV(1,Inc_Mulitiplier) ];]]>
</Text>
</Rung>
<Rung Number="7" Type="N">
<Comment>
<![CDATA[If NOT doing Divisions calulation then Weight is converted to a REAL from an integer.
]]>
</Comment>
<Text>
<![CDATA[XIO(Use_Divisions)MUL(Input_1st_INT,Inc_Mulitiplier,Weight);]]>
</Text>
</Rung>
<Rung Number="8" Type="N">
<Comment>
<![CDATA[If doing Divisions calulation then Weight is converted to a REAL from the number of scale increment counts.
]]>
</Comment>
<Text>
<![CDATA[XIC(Use_Divisions)DIV(Input_1st_INT,Inc_Divider,Weight);]]>
</Text>
</Rung>
<Rung Number="9" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.0)OTE(Feed_Under);]]>
</Text>
</Rung>
<Rung Number="10" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.1)OTE(FastFeed_OK);]]>
</Text>
</Rung>
<Rung Number="11" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.2)OTE(TolOK_Over);]]>
</Text>
</Rung>
<Rung Number="12" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.5)OTE(Compar_3);]]>
</Text>
</Rung>
<Rung Number="13" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.6)OTE(Compar_2);]]>
</Text>
</Rung>
<Rung Number="14" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.7)OTE(Compar_1);]]>
</Text>
</Rung>
<Rung Number="15" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.9)OTE(Discrete_In_1);]]>
</Text>
</Rung>
<Rung Number="16" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.10)OTE(Discrete_In_2);]]>
</Text>
</Rung>
<Rung Number="17" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.12)OTE(Motion);]]>
</Text>
</Rung>
<Rung Number="18" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.13)OTE(Net_Mode);]]>
</Text>
</Rung>
<Rung Number="19" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.14)OTE(UpDate_InProcess);]]>
</Text>
</Rung>
<Rung Number="20" Type="N">
<Comment>
<![CDATA[Scale Status bit set into seperate BOOL bits.]]>
</Comment>
<Text>
<![CDATA[XIC(Input_2nd_INT.15)OTE(Data_OK);]]>
</Text>
</Rung>
</RLLContent>
</Routine>
</Routines>
</AddOnInstructionDefinition>
</AddOnInstructionDefinitions>
</Controller>
</RSLogix5000Content>
