User Specific Transformation - How to...
WARNING | |
Avoid Online Change When doing an Online Change in combination with user specific kinematics there might occur discontinuities on C++ side. Therefore, an online change should generally be avoided. Note the chapter “Quickstart with Online Change”. |
ITcNcTrafo
Step by Step Manual for how to Integrate own Kinematics with TF511x
- Start with an empty TwinCAT Project.
- 1. Add a
C++
Object. - 2. Select a TwinCAT Driver Project or a TwinCAT Versioned C++ project.
- 3. Select a TwinCAT Module Class.
- 4. Select the
TMC
Editor.
Versioned C++ Project A Versioned C++ Project can be used from TwinCAT V3.1.4024.10 for user specific kinematics. |
- 5. Add the
ITcNcTrafo
interface.
- 6. Add kinematic specific parameters (arm length, displacements, etc.).
- 7. Run the
TMC
Code Generator.
- 8. Add a header.
<ProjectName>Interfaces.h
requires an include statement, additionally. Also addTcNcKinematicsInterfaces.h
.
- 9. Implement the methods
Forward
,Backward
,TrafoSupported
andGetDimensions
. These methods have to have a valid implementation and are automatically placed atSource Files\<TrafoName>.cpp
. - 10. Build and publish the modules.
E_NOTIMPL The default return value |
- 11. Configure axes in the
MOTION
subtree and add PTP axes.
- 12. Add user specific modules (Channel).
- 13. Reload the
TcCom
objects by pressing theReload
button. - 14. Select your transformation object and confirm your choice by pressing the
OK
button. - 15. The transformation group has to know which root module is to be called. This is why the object ID of the kinematics (in this case
MyFirstTrafo
) has to be selected. The kinematic object defines the number of ACS axes and MCS axes to be used in the PLC (see ST_KinAxes). - 16. Parameterize the object parameters according to the kinematics used. Once this is done, the XAE configuration is complete.
- The transformation can now be activated via the PLC (see PLC Library). To actuate the transformation define a cyclic channel interface in the PLC and link it with the IO of the kinematic channel.
in_stKinToPlc AT %I* : NCTOPLC_NCICHANNEL_REF;
out_stPlcToKin AT %Q* : PLCTONC_NCICHANNEL_REF;
Customer Specific Kinematic The function block |