Create a TwinCAT Project from Scratch : Différence entre versions

[version en cours de rédaction][version en cours de rédaction]
Ligne 58 : Ligne 58 :
 
# Click Save All
 
# Click Save All
 
{{Info|...Check the date next to the machine types - you will want the latest one}}<br /></translate>
 
{{Info|...Check the date next to the machine types - you will want the latest one}}<br /></translate>
 +
|Step_Picture_00=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_131858.jpg
 
}}
 
}}
 
{{Tuto Step
 
{{Tuto Step
Ligne 68 : Ligne 69 :
 
# If there is a request for a platform change, click Yes
 
# If there is a request for a platform change, click Yes
 
# On success, the Route dropdown will not read Error</translate>
 
# On success, the Route dropdown will not read Error</translate>
 +
|Step_Picture_00=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_132349.jpg
 +
|Step_Picture_01=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_132519.jpg
 
}}
 
}}
 
{{Tuto Step
 
{{Tuto Step
|Step_Title=<translate>Scan for Devices and Check EtherCAT validity</translate>
+
|Step_Title=<translate>Scan for Devices</translate>
 
|Step_Content=<translate>#Expand IO
 
|Step_Content=<translate>#Expand IO
 
#Right click on devices, Scan
 
#Right click on devices, Scan
 +
#Click OK on the Hint:
 
#Untick RT-Ethernet
 
#Untick RT-Ethernet
 
#Untick COM-Port
 
#Untick COM-Port
Ligne 78 : Ligne 82 :
 
#Scan for boxes - Yes
 
#Scan for boxes - Yes
 
#If there is a request for New Device Type, Click Apply to All, Click Yes
 
#If there is a request for New Device Type, Click Apply to All, Click Yes
#Check the Devices and boxes match the expected EtherCAT setup
 
  
 +
<br /></translate>
 +
|Step_Picture_00=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_132424.jpg
 +
|Step_Picture_01=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_132612.jpg
 +
|Step_Picture_02=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_132645.jpg
 +
|Step_Picture_03=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_132706.jpg
 +
|Step_Picture_04=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_132815.jpg
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Check EtherCAT validity</translate>
 +
|Step_Content=<translate>Check the Devices and boxes match the expected EtherCAT setup{{Idea|...Check the green lights on the etherCAT boxes for connection status. Flickering Green means it is OK}}Repeat steps 7 and 8 until the physical network matches the scanned network
  
Repeat this until the physical network matches the scanned network
+
You may need to Right Click->scan Boxes on the second device if the EtherCAT boxes do not appear
 +
<br />{{Idea|...If the boxes do not appear in the right order, there could be an EtherCAT In /Out crossover}}<br /></translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Name all EtherCAT devices according to network</translate>
 +
|Step_Content=<translate>Click twice on each device (not double click) to enable the device to be renamed
  
{{Idea|...Check the green lights on the etherCAT boxes for connection status. Flickering Green means it is OK}}You may need to Right Click->scan Boxes on the second device if the EtherCAT boxes do not appear
+
rename to [https://stuga.dokit.app/wiki/Naming_Conventions_for_Electrical_Components convention]</translate>
<br />{{Idea|...If the boxes do not appear in the right order, there could be an EtherCAT In /Out crossover}}
+
|Step_Picture_00=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143904.jpg
<br /></translate>
+
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Add Drive Configurator</translate>
 +
|Step_Content=<translate>{{Info|...This step needs to be done for the AX8000 drives only}}</translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Double check all IO references with someone else</translate>
 +
|Step_Content=<translate>Any mistakes made will save hours if spotted here</translate>
 
}}
 
}}
 
{{Tuto Step
 
{{Tuto Step
|Step_Title=<translate>Name all EtherCAT devices according to network</translate>
+
|Step_Title=<translate>Activate configuration</translate>
 
|Step_Content=<translate></translate>
 
|Step_Content=<translate></translate>
 +
|Step_Picture_00=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143629.jpg
 +
|Step_Picture_00_annotation={"version":"2.4.6","objects":[{"type":"image","version":"2.4.6","originX":"left","originY":"top","left":20,"top":20,"width":1057,"height":817,"fill":"rgb(0,0,0)","stroke":null,"strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":2.25,"scaleY":2.25,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"crossOrigin":"","cropX":0,"cropY":0,"src":"https://stuga.dokit.app/images/9/90/Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143629.jpg","filters":[]},{"type":"wfrect","version":"2.4.6","originX":"center","originY":"center","left":94.27,"top":225.27,"width":47.99,"height":47.99,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":2,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"rx":0,"ry":0}],"height":450,"width":600}
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Add Axis Task</translate>
 +
|Step_Content=<translate>Axis task may need to be added under the MOTION tree:
 +
 +
# Add New Item
 +
# NC/PTP Configuration
 +
# Leave the Name as default</translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Add Axes</translate>
 +
|Step_Content=<translate>If the axes do not exist under MOTION->NC Task->Axes, add them
 +
 +
# Right Click Add axis
 +
# Name to convention nn Axis
 +
 +
 +
Repeat for each axis on machine</translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Map Axes</translate>
 +
|Step_Content=<translate># Double click an axis
 +
# Settings tab
 +
# Click Link To IO
 +
# Connect to associated Drive
 +
 +
 +
Repeat for each axis
 +
 +
{{Warning|...Make sure you select the correct channel number / letter is it is a dual drive}}<br /></translate>
 
}}
 
}}
 
{{Tuto Step
 
{{Tuto Step
 
|Step_Title=<translate>Add Drive Configurator</translate>
 
|Step_Title=<translate>Add Drive Configurator</translate>
 
|Step_Content=<translate>{{Info|...This step needs to be done for the AX8000 drives only}}</translate>
 
|Step_Content=<translate>{{Info|...This step needs to be done for the AX8000 drives only}}</translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Map all IO</translate>
 +
|Step_Content=<translate>Using the circuit diagrams, link all the IO refs up to the inputs and outputs
 +
 +
# Double click on the slices and Field Bus boxes in turn
 +
# Ensure you can see the Input / output channels (may need some resizing
 +
# Double click on the relevant IO channel
 +
# Type the number in the box
 +
# For Inputs, use ibInputArray and match the number. outputs use qbOutputArray
 +
 +
 +
Repeat for all IO
 +
 +
<br />{{Warning|...Make sure you are using ibInputArray and qbOutputArray and not any others}}{{Pin|...Once you have used a reference, it disappears. if you have done this wrong, you can right click->clear the link}}<br /></translate>
 +
|Step_Picture_00=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143613.jpg
 +
|Step_Picture_00_annotation={"version":"2.4.6","objects":[{"type":"image","version":"2.4.6","originX":"left","originY":"top","left":0,"top":0,"width":1050,"height":813,"fill":"rgb(0,0,0)","stroke":null,"strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":0.57,"scaleY":0.57,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"crossOrigin":"","cropX":0,"cropY":0,"src":"https://stuga.dokit.app/images/9/97/Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143613.jpg","filters":[]},{"type":"wfrect","version":"2.4.6","originX":"center","originY":"center","left":389.54,"top":290.07,"width":372.09,"height":22.95,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":2,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"rx":0,"ry":0},{"type":"wfarrow2line","version":"2.4.6","originX":"center","originY":"center","left":305.5,"top":252.5,"width":1,"height":47,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":4,"strokeDashArray":null,"strokeLineCap":"round","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"x1":-0.5,"x2":0.5,"y1":23.5,"y2":-23.5,"x2a":8.072754210645003,"y2a":-3.334351146934093,"x2b":-7.923625470268037,"y2b":-3.6746996507833067},{"type":"wfarrow2circle","version":"2.4.6","originX":"center","originY":"center","left":305,"top":276,"width":16,"height":16,"fill":"#aaa","stroke":"#666","strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":0.5,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"radius":8,"startAngle":0,"endAngle":6.283185307179586},{"type":"wfarrow2circle","version":"2.4.6","originX":"center","originY":"center","left":306,"top":229,"width":16,"height":16,"fill":"#aaa","stroke":"#666","strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":0.5,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"radius":8,"startAngle":0,"endAngle":6.283185307179586},{"type":"wfarrow2line","version":"2.4.6","originX":"center","originY":"center","left":307,"top":361,"width":0,"height":112,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":4,"strokeDashArray":null,"strokeLineCap":"round","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"x1":0,"x2":0,"y1":-56,"y2":56,"x2a":8,"y2a":36,"x2b":-8,"y2b":36},{"type":"wfarrow2circle","version":"2.4.6","originX":"center","originY":"center","left":307,"top":305,"width":16,"height":16,"fill":"#aaa","stroke":"#666","strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":0.5,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"radius":8,"startAngle":0,"endAngle":6.283185307179586},{"type":"wfarrow2circle","version":"2.4.6","originX":"center","originY":"center","left":307,"top":417,"width":16,"height":16,"fill":"#aaa","stroke":"#666","strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":0.5,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"radius":8,"startAngle":0,"endAngle":6.283185307179586}],"height":465,"width":600}
 +
|Step_Picture_01=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143629.jpg
 +
|Step_Picture_02=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143716.jpg
 +
|Step_Picture_02_annotation={"version":"2.4.6","objects":[{"type":"image","version":"2.4.6","originX":"left","originY":"top","left":0,"top":0,"width":587,"height":469,"fill":"rgb(0,0,0)","stroke":null,"strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1.02,"scaleY":1.02,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"crossOrigin":"","cropX":0,"cropY":0,"src":"https://stuga.dokit.app/images/2/2f/Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143716.jpg","filters":[]},{"type":"wfellipse","version":"2.4.6","originX":"center","originY":"center","left":91.66,"top":51.76,"width":59.7,"height":36.46,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":2,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"rx":29.8487335084682,"ry":18.230760741782483},{"type":"wfrect","version":"2.4.6","originX":"center","originY":"center","left":252.19,"top":142.27,"width":234.63,"height":22.54,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":2,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"rx":0,"ry":0},{"type":"textbox","version":"2.4.6","originX":"center","originY":"center","left":286.34,"top":116,"width":118.71,"height":22.6,"fill":"#FF0000","stroke":"#FF0000","strokeWidth":1,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"text":"Double Click","fontSize":20,"fontWeight":"normal","fontFamily":"sans-serif","fontStyle":"normal","lineHeight":1.16,"underline":false,"overline":false,"linethrough":false,"textAlign":"left","textBackgroundColor":"","charSpacing":0,"minWidth":20,"styles":{} }],"height":479,"width":600}
 +
|Step_Picture_03=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143739.jpg
 +
|Step_Picture_03_annotation={"version":"2.4.6","objects":[{"type":"image","version":"2.4.6","originX":"left","originY":"top","left":0,"top":0,"width":584,"height":472,"fill":"rgb(0,0,0)","stroke":null,"strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1.03,"scaleY":1.03,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"crossOrigin":"","cropX":0,"cropY":0,"src":"https://stuga.dokit.app/images/b/bf/Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143739.jpg","filters":[]},{"type":"wfellipse","version":"2.4.6","originX":"center","originY":"center","left":95.21,"top":53.32,"width":64.64,"height":35.59,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":2,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"rx":32.32181383717859,"ry":17.792773690712732}],"height":485,"width":600}
 +
|Step_Picture_04=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143822.jpg
 +
|Step_Picture_04_annotation={"version":"2.4.6","objects":[{"type":"image","version":"2.4.6","originX":"left","originY":"top","left":0,"top":0,"width":371,"height":422,"fill":"rgb(0,0,0)","stroke":null,"strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1.62,"scaleY":1.62,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"crossOrigin":"","cropX":0,"cropY":0,"src":"https://stuga.dokit.app/images/8/87/Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143822.jpg","filters":[]},{"type":"wfrect","version":"2.4.6","originX":"center","originY":"center","left":215.31,"top":105.57,"width":278.47,"height":34.67,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":2,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"rx":0,"ry":0},{"type":"textbox","version":"2.4.6","originX":"center","originY":"center","left":430.05,"top":106,"width":145.91,"height":22.6,"fill":"#FF0000","stroke":"#FF0000","strokeWidth":1,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"text":"Clear a link","fontSize":20,"fontWeight":"normal","fontFamily":"sans-serif","fontStyle":"normal","lineHeight":1.16,"underline":false,"overline":false,"linethrough":false,"textAlign":"left","textBackgroundColor":"","charSpacing":0,"minWidth":20,"styles":{} }],"height":682,"width":600}
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Double check all IO references with someone else</translate>
 +
|Step_Content=<translate>Any mistakes made will save hours if spotted here</translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Activate configuration</translate>
 +
|Step_Content=<translate></translate>
 +
|Step_Picture_00=Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143629.jpg
 +
|Step_Picture_00_annotation={"version":"2.4.6","objects":[{"type":"image","version":"2.4.6","originX":"left","originY":"top","left":20,"top":20,"width":1057,"height":817,"fill":"rgb(0,0,0)","stroke":null,"strokeWidth":0,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":2.25,"scaleY":2.25,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"crossOrigin":"","cropX":0,"cropY":0,"src":"https://stuga.dokit.app/images/9/90/Create_a_TwinCAT_Project_from_Scratch_Annotation_2019-11-20_143629.jpg","filters":[]},{"type":"wfrect","version":"2.4.6","originX":"center","originY":"center","left":94.27,"top":225.27,"width":47.99,"height":47.99,"fill":"rgba(255,0,0,0)","stroke":"#FF0000","strokeWidth":2,"strokeDashArray":null,"strokeLineCap":"butt","strokeDashOffset":0,"strokeLineJoin":"miter","strokeMiterLimit":4,"scaleX":1,"scaleY":1,"angle":0,"flipX":false,"flipY":false,"opacity":1,"shadow":null,"visible":true,"clipTo":null,"backgroundColor":"","fillRule":"nonzero","paintFirst":"fill","globalCompositeOperation":"source-over","transformMatrix":null,"skewX":0,"skewY":0,"rx":0,"ry":0}],"height":450,"width":600}
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Add Axis Task</translate>
 +
|Step_Content=<translate>Axis task may need to be added under the MOTION tree:
 +
 +
# Add New Item
 +
# NC/PTP Configuration
 +
# Leave the Name as default</translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Add Axes</translate>
 +
|Step_Content=<translate>If the axes do not exist under MOTION->NC Task->Axes, add them
 +
 +
# Right Click Add axis
 +
# Name to convention nn Axis
 +
 +
 +
Repeat for each axis on machine</translate>
 +
}}
 +
{{Tuto Step
 +
|Step_Title=<translate>Map Axes</translate>
 +
|Step_Content=<translate># Double click an axis
 +
# Settings tab
 +
# Click Link To IO
 +
# Connect to associated Drive
 +
 +
 +
Repeat for each axis
 +
 +
{{Warning|...Make sure you select the correct channel number / letter is it is a dual drive}}<br /></translate>
 
}}
 
}}
 
{{Notes}}
 
{{Notes}}

Version du 20 novembre 2019 à 16:45

Auteur avatarGareth Green | Dernière modification 12/09/2023 par Gareth Green en cours de rédaction

Étape 1 - Start a new project

  1. Open Visual Studio
  2. Click on New project
  3. Choose TwinCAT projects->TwinCAT XAE Project (xml format)
  4. Name is build number (no Suffix)
  5. Location is c:\TwinCAT\Stuga\
  6. Untick "Create Directory for solution"

This creates the template


Étape 2 - Add PLC Project for Reset

  1. On PLC, right click and Add Existing Item
  2. Navigate to g:\Design\TwinCAT3\PLC_Reset_1_1
  3. Select the .Plcproj file
  4. Copy Project to solution file


Étape 3 - Add PLC Project for tcMulti

  1. Add Existing Item
  2. Navigate to g:\Design\TwinCAT3\tcMulti_6_24
  3. Select the .Plcproj file
  4. Copy Project to solution file


Étape 4 - Ensure Correct Machine Commented in tcMulti project


  1. Navigate to tcMulti_6_24 project->POUs->MAIN
  2. Scroll down to the machine types. The "comment State" can be toggled on and off by right clicking next to the step number on the left
  3. Your goal is to ensure the correct machine is highlighted and the incorrect ones are commented out (in green)
  4. Click Save All
...Check the date next to the machine types - you will want the latest one



Étape 5 - Add TwinSAFE project

...From Z071 there is no twinSAFE project as the Estop circuit is hard wired

Étape 6 - Add the route to the PLC

  1. From Dropdown box select the Build number (If it does not exist we will need to add a new route)
  2. If there is a request for a platform change, click Yes
  3. On success, the Route dropdown will not read Error


Étape 7 - Scan for Devices

  1. Expand IO
  2. Right click on devices, Scan
  3. Click OK on the Hint:
  4. Untick RT-Ethernet
  5. Untick COM-Port
  6. Just have the EtherCAT ports
  7. Scan for boxes - Yes
  8. If there is a request for New Device Type, Click Apply to All, Click Yes


Étape 8 - Check EtherCAT validity

Check the Devices and boxes match the expected EtherCAT setup
...Check the green lights on the etherCAT boxes for connection status. Flickering Green means it is OK
Repeat steps 7 and 8 until the physical network matches the scanned network

You may need to Right Click->scan Boxes on the second device if the EtherCAT boxes do not appear


...If the boxes do not appear in the right order, there could be an EtherCAT In /Out crossover

Étape 9 - Name all EtherCAT devices according to network

Click twice on each device (not double click) to enable the device to be renamed

rename to convention



Étape 10 - Add Drive Configurator

...This step needs to be done for the AX8000 drives only

Étape 11 - Double check all IO references with someone else

Any mistakes made will save hours if spotted here

Étape 12 - Activate configuration



Étape 13 - Add Axis Task

Axis task may need to be added under the MOTION tree:

  1. Add New Item
  2. NC/PTP Configuration
  3. Leave the Name as default

Étape 14 - Add Axes

If the axes do not exist under MOTION->NC Task->Axes, add them

  1. Right Click Add axis
  2. Name to convention nn Axis


Repeat for each axis on machine

Étape 15 - Map Axes

  1. Double click an axis
  2. Settings tab
  3. Click Link To IO
  4. Connect to associated Drive


Repeat for each axis

...Make sure you select the correct channel number / letter is it is a dual drive

Étape 16 - Add Drive Configurator

...This step needs to be done for the AX8000 drives only

Étape 17 - Map all IO

Using the circuit diagrams, link all the IO refs up to the inputs and outputs

  1. Double click on the slices and Field Bus boxes in turn
  2. Ensure you can see the Input / output channels (may need some resizing
  3. Double click on the relevant IO channel
  4. Type the number in the box
  5. For Inputs, use ibInputArray and match the number. outputs use qbOutputArray


Repeat for all IO


...Make sure you are using ibInputArray and qbOutputArray and not any others
...Once you have used a reference, it disappears. if you have done this wrong, you can right click->clear the link

Étape 18 - Double check all IO references with someone else

Any mistakes made will save hours if spotted here

Étape 19 - Activate configuration



Étape 20 - Add Axis Task

Axis task may need to be added under the MOTION tree:

  1. Add New Item
  2. NC/PTP Configuration
  3. Leave the Name as default

Étape 21 - Add Axes

If the axes do not exist under MOTION->NC Task->Axes, add them

  1. Right Click Add axis
  2. Name to convention nn Axis


Repeat for each axis on machine

Étape 22 - Map Axes

  1. Double click an axis
  2. Settings tab
  3. Click Link To IO
  4. Connect to associated Drive


Repeat for each axis

...Make sure you select the correct channel number / letter is it is a dual drive

Commentaires

Draft