Some Homing sequences implmentation

Limit switch and direct homing are implemneted, the same with homing to a home snesor
Missing referencing to encoder index or external signal.
This commit is contained in:
Federico Rojas
2019-03-27 11:57:24 +01:00
parent 6dbf29a0c4
commit c1930b89fd
4 changed files with 30 additions and 63 deletions

View File

@@ -1330,7 +1330,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-002000000004}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..3] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-002000000004}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..3] OF BIT</Name>
<BitSize>4</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1339,7 +1339,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-002000000006}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..5] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-002000000006}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..5] OF BIT</Name>
<BitSize>6</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1357,7 +1357,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-002000000002}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..1] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-002000000002}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..1] OF BIT</Name>
<BitSize>2</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1366,7 +1366,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-002000000001}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..0] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-002000000001}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..0] OF BIT</Name>
<BitSize>1</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1375,7 +1375,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-002000000003}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..2] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-002000000003}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..2] OF BIT</Name>
<BitSize>3</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1384,7 +1384,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-002000000009}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..8] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-002000000009}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..8] OF BIT</Name>
<BitSize>9</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1393,7 +1393,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-00200000000C}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..11] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-00200000000C}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..11] OF BIT</Name>
<BitSize>12</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1402,7 +1402,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-00200000000E}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..13] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-00200000000E}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..13] OF BIT</Name>
<BitSize>14</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1411,7 +1411,7 @@ External Setpoint Generation:
</ArrayInfo>
</DataType>
<DataType>
<Name GUID="{18071995-0000-0000-0000-00200000000D}" IecBaseType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..12] OF BIT</Name>
<Name GUID="{18071995-0000-0000-0000-00200000000D}" IecBaseType="true" BitType="true" AutoDeleteType="true" HideSubItems="true">ARRAY [0..12] OF BIT</Name>
<BitSize>13</BitSize>
<BaseType GUID="{18071995-0000-0000-0000-000000000010}">BIT</BaseType>
<ArrayInfo>
@@ -1464,7 +1464,7 @@ External Setpoint Generation:
<Axis CreateSymbols="true" AxisType="1" Id="1">
<Name>Axis 1</Name>
<AxisPara>
<Dynamic AccelerationMaximum="1500" DecelerationMaximum="1500" Acceleration="984.001" Deceleration="984.001" Jerk="5043"/>
<Dynamic AccelerationMaximum="1500" DecelerationMaximum="1500" Acceleration="567.693" Deceleration="567.693" Jerk="5371.25"/>
<Velo RefSearch="10" RefSync="10" SlowManual="20" FastManual="100" Maximum="120"/>
<PositionAreaControl Range="0.05"/>
<TargetPosControl Range="0.1" Time="0.5"/>
@@ -1472,9 +1472,9 @@ External Setpoint Generation:
</AxisPara>
<Encoder Name="Enc" EncType="4">
<EncPara ScaleFactorNumerator="60" ScaleFactorDenominator="2000" Inverse="true" MaxCount="#x0000ffff">
<SoftEndMinControl Range="5"/>
<SoftEndMaxControl Range="175"/>
<Inc RefMode="4" RefSoftSyncMask="#x0000ffff"/>
<SoftEndMinControl Enable="true" Range="5"/>
<SoftEndMaxControl Enable="true" Range="175"/>
<Inc RefSoftSyncMask="#x0000ffff"/>
</EncPara>
<Vars VarGrpType="1">
<Name>Inputs</Name>
@@ -1488,6 +1488,9 @@ External Setpoint Generation:
<SubVar TypeFormatIndex="2">
<Name>nDataIn2</Name>
</SubVar>
<SubVar TypeFormatIndex="2">
<Name>nState1</Name>
</SubVar>
<SubVar>
<Name>nState4</Name>
<Comment>
@@ -2052,10 +2055,10 @@ bHomeSensor8 AT %I*: BOOL;
<ExcludePdo>#x1a00</ExcludePdo>
<ExcludePdo>#x1a01</ExcludePdo>
<ExcludePdo>#x1a02</ExcludePdo>
<Entry Name="Status__Latch C valid" Index="#x6010" Sub="#x01">
<Entry Name="Status__Latch C valid" Index="#x6010" Sub="#x01" Flags="#x00008020">
<Type>BIT</Type>
</Entry>
<Entry Name="Status__Latch extern valid" Index="#x6010" Sub="#x02">
<Entry Name="Status__Latch extern valid" Index="#x6010" Sub="#x02" Flags="#x00008020">
<Type>BIT</Type>
</Entry>
<Entry Name="Status__Set counter done" Index="#x6010" Sub="#x03">
@@ -2082,13 +2085,13 @@ bHomeSensor8 AT %I*: BOOL;
<Entry Name="Status__Status of input B" Index="#x6010" Sub="#x0a">
<Type>BIT</Type>
</Entry>
<Entry Name="Status__Status of input C" Index="#x6010" Sub="#x0b">
<Entry Name="Status__Status of input C" Index="#x6010" Sub="#x0b" Flags="#x00008020">
<Type>BIT</Type>
</Entry>
<Entry Name="Status__Status of input gate" Index="#x6010" Sub="#x0c">
<Type>BIT</Type>
</Entry>
<Entry Name="Status__Status of extern latch" Index="#x6010" Sub="#x0d">
<Entry Name="Status__Status of extern latch" Index="#x6010" Sub="#x0d" Flags="#x00008020">
<Type>BIT</Type>
</Entry>
<Entry Name="Status__Sync error" Index="#x6010" Sub="#x0e">
@@ -2232,10 +2235,10 @@ bHomeSensor8 AT %I*: BOOL;
<ExcludePdo>#x1603</ExcludePdo>
<ExcludePdo>#x1600</ExcludePdo>
<ExcludePdo>#x1601</ExcludePdo>
<Entry Name="Control__Enable latch C" Index="#x7010" Sub="#x01">
<Entry Name="Control__Enable latch C" Index="#x7010" Sub="#x01" Flags="#x00008020">
<Type>BIT</Type>
</Entry>
<Entry Name="Control__Enable latch extern on positive edge" Index="#x7010" Sub="#x02">
<Entry Name="Control__Enable latch extern on positive edge" Index="#x7010" Sub="#x02" Flags="#x00008020">
<Type>BIT</Type>
</Entry>
<Entry Name="Control__Set counter" Index="#x7010" Sub="#x03">