diff --git a/Bode.md b/Bode.md index 5e0a231..1af8919 100644 --- a/Bode.md +++ b/Bode.md @@ -1,59 +1,142 @@ -# How to bode with TwinCat +# How to Bode with TwinCAT -## Requierments -- PLC -- EL7XX Servodrive -- PC -- Visual Studio Code 2017 -- TwinCat3 -- eXtended Automation Runtime (XAR) -- Remote desktop Connection -- Patience +## Requirements + +- PLC +- EL7XX Servodrive +- PC +- Visual Studio Code 2017 +- TwinCAT 3 +- eXtended Automation Runtime (XAR) +- Remote Desktop Connection +- Patience + +--- ## Introduction -The goal is to get a bode plot af an **NC Axis** which is connected to the EL7XX Servodrive. This Documentation should enable you to perform a bode plot and tweek the setings for better performance. +The goal is to get a **Bode plot** of an **NC Axis** connected to the EL7XX Servodrive. This documentation should enable you to perform a Bode plot and tweak the settings for better performance. + +--- ## Steps -1. Setup a standard solution Procejt in TwinCat3: - - Your target axis is set up correctly - - You can jog the axis -2. Make your Target build version is 4026.67 ?? corect if not see [How to upgrade](UpgradePLC.md) -3. In the TwinCat project select the following options in TcComObjects -![image](Images/ImgBode/TcCom.png) -4. Add dynamic container for oversampling (not avaiable with EL7211) -- Under I/O -> Devices **right click on Device 1** (if your axis is mounted to device1) -![](Images/ImgBode/DynCont1.png) -- Select: **Append Dynamic Container** -- Agree to all pop ups -5. Decreas the PlC cycle time to $250\mu s$ -![](Images/ImgBode/RtSettings.png) -7. Set NC-Motion Task to on PLC cycle -![](Images/ImgBode/Axis_Cycle.png) -8. Disable LP Filter of encoder (for speed and or position depending on what you wnat to measure) and Download -![](Images/ImgBode/EncSettings.png) -9. Open main visu and enable the axis (as if you want to jog it) -### Open New Bode Project -10. Open TwinCat or Visual Studio Code -![](Images/ImgBode/BodeProject.png) -11. Select Bode Plot -![](Images/ImgBode/openBodeOptions.png) -12. Set Target in bode-Properties: +### 1. Setup a Standard TwinCAT Project + +- Ensure your target axis is correctly set up. +- You should be able to jog the axis. + +--- + +### 2. Verify Target Version + +Make sure your target build version is `4026.67`. If not, see [How to upgrade](UpgradePLC.md). + +--- + +### 3. Enable `TcComObjects` + +Go to your TwinCAT project and select the following options in **TcComObjects**: +TcComObjects + +--- + +### 4. Add Dynamic Container for Oversampling +*(Not available with EL7211)* + +- Navigate to **I/O → Devices** +- **Right-click** on *Device 1* (assuming your axis is mounted here) +Dynamic Container +- Select: **Append Dynamic Container** +- Agree to all pop-ups + +--- + +### 5. Decrease PLC Cycle Time to `250 µs` + +PLC Cycle Time + +--- + +### 6. Set NC Motion Task to Use PLC Cycle + +NC Motion Task + +--- + +### 7. Disable Encoder LP Filter + +Disable the low-pass filter for the encoder (speed and/or position, depending on your measurement focus). Then **Download** the settings. +Encoder Settings + +--- + +### 8. Enable the Axis in Main Visualisation + +Open the main visualisation and enable the axis as if you were going to jog it. + +--- + +## Open New Bode Project + +### 9. Open TwinCAT or Visual Studio Code + +Open Bode Project + +--- + +### 10. Select Bode Plot + +Bode Plot Options + +--- + +### 11. Set Target in Bode Properties + +- **Target ID**: Set to the TwinCAT route of your PLC +- **Axis ID**: Set to the ID of the axis in your TwinCAT project +Target Settings + +--- + +### 12. Adjust Settings for Performance + +Tune the settings to get the best performance from the EL7XX. +Bode Settings + +--- + +### 13. Start Measurement + +Start Measurement + +--- + +### 14. View Your Measurements + +Measurements will appear under **Bode Plot**. +Measurement Location + +--- + +## Display Options + +### 1. Navigate to the Bode Project + +- Click on the project to open display options +Extended View Navigation + +--- + +### 2. Enable Extended View + +- Set **Appearance / View Detail Level** to **Extended** +Extended View + +--- + +### 3. Customize Measurement Appearance + +Select individual measurements and adjust their appearance in the **Properties** panel. +Appearance Settings - - Set Target ID to the TwinCat Route for your PLC - - Axis ID to the ID in the TwinCat project of which you want to make the bode plot -![](Images/ImgBode/TargetSettings.png) -13. Adjust the settings to get the best performance out of the EL7XX -![](Images/ImgBode/BodePltSettings.png) -14. After that start your measurement -![](Images/ImgBode/StartMeasurement.png) -15. Your measurements apear under Bode Plot -![](Images/ImgBode/MeasurementsPlace.png) -### Display Options -1. Select Bode Project -2. ![](Images/ImgBode/ExtendedViewNav.png) -3. Set Aperance/View Detail Level to extended -![](Images/ImgBode/ExtendedView.png) -4. Now select the individual Measurements; Under Properties you can adjust the aperance of each measurement individualy to your liking -![](Images/ImgBode/AperanceGraph.png)