Vector Mode – Related TML Instructions and Data |
Parameters
RESRATIOX, RESRATIOY, RESRATIONZ Defines the position feedback resolution ratio for each axis. The motion controller will use the best resolution for splitting the segments in PVT points. The fines encoder resolution will be used to compute the scaling factors for the other axes. NLINESTAN Encoder resolution for tangent axis VSPD – vector speed for current segment. Measured in speed units VACC – vector acceleration for current segment. Measured in acceleration units
Variables SEGBUFSTS Contains the segment buffer status. SEGBUFSTS bit description
Instructions SETMODE value Set Vector Mode operation as specified by value: Vector Mode operation mode (a copy of value is saved in the TML variable MACOMMAND) VPLANE(X_axis, Y_axis, Z_axis) Set the coordinate system for 2D/3D move. MODE VM Set Vector motion mode. VSEG1 (X_inc, Y_inc) VSEG2 (X_inc, Y_inc) Describes a linear segment. CIRCLE1 (Radius, Theta_inc) CIRCLE2 (Radius, Theta_start) Describes a circular segment. UPD Update motion parameters and start new motion mode STOP Stop the motion Remarks:
Programming Example // Vector Mode sequence executed from non-volatile // memory of the drive. X and Y axis have identical feedback // resolution identical (2000 counts/rev) SETMODE 0xCF00; //Clear buffer VPLANE (A, B, D);// Axes A and B define the coordinate system. //D axis is the tangent axis. RESRATIOX=0u; RESRATIOY=0u; NLINESTAN=2000; // Tangent axis resolution MODE VM; // Set Vector Mode VACC = 0.0006; // Vector Acceleration = 2[m/s^2] VSPD = 0.3183; // Vector Speed = 1[m/s] // Increment position with (X, Y) = (100[IU], 100[IU]) VSEG1 100L, 100L; VSEG2 100L, 100L; UPD; //Execute immediate // Increment position with (X, Y) = (101[IU], 101[IU]) VSEG1 101L, 101L; VSEG2 101L, 101L; VACC = 0.0064; // Vector Acceleration = 20[m/s^2] // Circular segment of radius 9.42478[mm], with initial angle 20[deg] and angle increment 50[deg]) CIRCLE1 3L, 50.; CIRCLE2 3L, 20.; VACC = 0.0006; // Vector Acceleration = 2[m/s^2] VSPD = 0.3183; // Vector Speed = 1[m/s] // Increment position with (X, Y) = (102[IU], 102[IU]) VSEG1 102L, 102L; VSEG2 102L, 102L; VSPD = 0.9549; // Vector Speed = 3[m/s] // Circular segment of radius 1e+001[mm], with initial angle 21[deg] and angle increment 51[deg]) CIRCLE1 4L, 51.; CIRCLE2 4L, 21.; // Insert End Segment VSEG1 0L, 0L; VSEG2 0L, 0L; See also: |