Difference between revisions of "AXY:path-PLS"

From SoftMC-Wiki
Jump to: navigation, search
m (Introduction)
m (Introduction)
Line 10: Line 10:
  
 
<br/>{{Note|}}
 
<br/>{{Note|}}
::All properties and behaviors of the path-PLS are identical to the regular PLS except when it is explicitly noted.
+
::*All properties and behaviors of the path-PLS are identical to the regular PLS except when it is explicitly noted.
  
::Contrary to the one-dimensional PLS, the path-PLS can be triggered using command values only. There are no feedback path-PLS sources.
+
::*Contrary to the one-dimensional PLS, the path-PLS can be triggered using command values only. There are no feedback path-PLS sources.
  
::Due to the complex nature of advanced interpolation path forms, the path-PLS is not applicable to these interpolation types.
+
::*Due to the complex nature of advanced interpolation path forms, the path-PLS is not applicable to these interpolation types.
  
::The user must set the PLS output to the initial state. From then on, when the PLS is enabled, it will toggle the output. Disabling PLS does not affect the state of the digital output in any way.
+
::*The user must set the PLS output to the initial state. From then on, when the PLS is enabled, it will toggle the output. Disabling PLS does not affect the state of the digital output in any way.
  
 
= Implementation =
 
= Implementation =

Revision as of 09:41, 20 May 2014

Introduction

The path-PLS is associated with the motion nodally. Thus, instead of enabling/disabling using the command PLSEnable, the PLS will be automatically enabled at motion start and disabled at motion end. The motion path distance from the motion start, along the motion path, is the PLSsource variable of the PLS. Depending on the various interpolation modes, different PLSsource variables can be used:

  • Path length in position user units (e.g., mm) In case of straight line (MOVES) motion it is just a distance for the starting position. In case of joint interpolated motion (MOVE) there is no physical meaning of such a distance and in circular interpolation, we can choose between arc length and the angle from the starting point.
  • Percentage of the motion path from the start. This variable has the advantage that it is universal , means that it can be used in all motion types. However it has no physical meaning. Percentage can be very useful in motions having dominant orientation part.
  • Time elapsed from the motion start. This can be useful in certain application but can be applicable in time-based profiles only (PrfType = 2).
  • X,Y,Z coordinate. This is somehow a combination of path length and the percentage of the path, it has an advantage that it is a comfortable way of implementing application constrains. Also it can be applied to any type of motion interpolation. However, using it can cause multiple triggering of a same PLS position during one movement.

NOTE-Info.svgNOTE
  • All properties and behaviors of the path-PLS are identical to the regular PLS except when it is explicitly noted.
  • Contrary to the one-dimensional PLS, the path-PLS can be triggered using command values only. There are no feedback path-PLS sources.
  • Due to the complex nature of advanced interpolation path forms, the path-PLS is not applicable to these interpolation types.
  • The user must set the PLS output to the initial state. From then on, when the PLS is enabled, it will toggle the output. Disabling PLS does not affect the state of the digital output in any way.

Implementation

Path-PLSs can be defined in the same way as one-dimensional PLS. Contrary to the one-dimensional PLSs the path-PLS can be activated only when explicitly given in a movement statement. Some of Axis.PLSSource are especially to the path-PLS.

PLS Properties and Commands:

Common Shared <pls> as PLS {<element>} <io> {Hwassistance = on/off}

Command for PLS language object definition. Can get an element as robots or groups. Joint-based or non-robot based PLSs are not allowed. So, path-PLSs are PLSs defined on elements that are robots and not axes.

PLSENABLE

Enabling of path-PLS will be done through nodal assignment only. So, setting of this variable will return an error except when PLSsource = XCOO/YCOO/ZCOO. Querying this value will return the current state of a path-PLS depending on the movement being executed.

PLSREPEAT

Behaves in the same way as regular PLS. Just in this case it works on the selected PLSsource instead of axis position.

PLSRELATEDO

Flag used by oriented PLS-sources defining if the PLSposition[*] is computed relative from the start(0) or to the target(1). For example in case of PathLength it means if the length is measured from the start or from the end of the motion.

It default value will be 0 so if nothing said all path-specific variables will be computed from the start.

PLSSOURCE

In addition to adding this property to groups and robots, new assignment values will be defined:

Soruce Name One-dimensional
PLS
Path-PLS Description During
Blending
Related to
Start/Target
POSITIONCOMMAND no Axis position command. coordinate No
POSITIONFEEDBACK no Axis position feedback
POSITIONEXTERNAL no External position
Setpoint1new no X axis position (SetPoint{1} value).
Setpoint2new no Y axis position (SetPoint{2} value).
Setpoint3new no Z axis position (SetPoint{3} value).
PathLengthnew Length of the path in user units. single Yes
PathPercentagenew Percentage of the path.
PathTimenew Time duration in ms.


WITHPLS

Nodal assignment of path-PLS used for enabling path-PLS during motion. The WithPLS command specifies the PLSs that will be enabled during execution of the given motion and disabled when the motion ends.

Related properties and command

Path Percentage and Path Length

PLSsources can be from type PATHPERCENTAGE and PATHLENGTH. Those are special kind of position sources, both of them are dis-continuous variables that changes their values abruptly. It happens at the point where two movements are executed one after another. In case of PATHPERCENTAGE it is:

MOVE A  PLSSOURCE 0→100
MOVE B  PLSSOURCE 0→100

so at the point A the source changes its value from 100 to 0!!

Similar is with PATHLENGTH:

MOVE A  PLSSOURCE 0 → L1
MOVE B  PLSSOURCE 0 → L2

so at the point A the source changes its value from L1 to 0!!

During joint-interpolated (MOVE) movements PathLength is not relevant as the physical dimensions of such variable are non-existent. However, the option of using PathPercentage is kept. For PathLength descriptor, if the units are not homogenous the value in aggregate units is used. In case of CIRCLE interpolation this will be the angle on the circle-arc from the starting point. Using PathPercentage all values of PlsPosition[] , PlsHysteresis and PlsRepetition are in percentage units and are in scale of 0 to 100. All values that are negative or above 100 are silently used as 0 or 100. Enabling PLS follows by checking the current position compare to the PLS position and if there is need the IO is changed to be at its right state according to PlsPolarity. As those PlsSource types are locally this checking is done at when the movement starts. The PLS polarity is set to be !PLSPolarity so at when reaching the first PLS position the IO will toggle to be as the request value of PLSPolarity. So if the PLS position is appeared at the first sample of the movement the IO will be set but without time delay value that means PlsDelayTime[0] or HWIOtime[0] return 0.

NOTE-Info.svgNOTE
In case of two movements when the first is ended with VFinal > 0. At the start of the followed movement there isn't setting to !PLSPolarity. The next toggling is done at the first PLS position of the second movement. See example 7 below.

PathTime

The time-based source is applicable in time-based profiles only prftype=2, else an error is returned.

NOTE-Info.svgNOTE
There are two categories of PLS-sources coordinate and œsingle. The only difference is observable during blending. The coordinate PLS-sources trigger the PLS output once per PLS-condition independently how many individual motions caused it. The single PLS-source trigger the PLS output as many times as the number of movements involved in the blended motion (could be maximally 2)
NOTE-Info.svgNOTE
In case of PLSsource from type length, percentage or time there is no continues in toggling no matter if the PLS was global enabled using PLSEnable or local using WithPLS.

Setpoint1 , Setpoint2 , Setpoint3

SetPoint sources are the virtual Cartesian axes, defined in the robot world frame (i.e. setpoint). Not relevant for Group without a defined kinematics. Those sources can be tracked independently at a specific movement (using PLSEnable ). During Conveyor Tracking values of Setpoint1,Setpoint2,Setpoint3 will assume values on absolute robot coordinates i.e. (setpoint, here) and not robot frame coordinates moving with the robot! During joint-interpolated (MOVE) movements, values of Setpoint1,Setpoint2,Setpoint3 will be linearly interpolated between the samples, therefore an interpolation error depending on the sample rate and velocity can occur.

Pls tracking during Proceed command

Tracking the pls in case of proceed command is not trivial. The pls can be put into two categories - absolute and relative. Absolute are pls that are not depend in the current movement and are position in space - pcmd , pfb, xcoo, ycoo and zcoo. The relative pls are those how depend on the current movement - length, percentage and time. Another two categories of pls are global and local. Local refers to those how are enable just at a specific movement using the WithPls command otherwise it is a global pls. Tracking the pls during proceed command depends on the pls type. Global pls from type absolute will continue to be followed. A global relative pls will be also followed but the proceed is consider to be a new movement. For example if the source pls is from type percentage and the movement was stopped after 50% of its length so it passed the first 5 pls that are in the buffer. In this case when executing a proceed command the tracking will be started from the first pls in the buffer , the percentage is now according to the length of the proceed command. In case of local pls , again the behavior is changed according to the type. In case of an absolute pls the tracking will continued during proceed command. In case of relative pls - as the path length in proceed command is not the original one and a local pls is specific to the original movement those pls won't be tracked.

Global Notes

NOTE-Info.svgNOTE
Path-PLS feature is not applicable for JOG, DELAY , PASS and DOPASS commands. An error will be returned.
NOTE-Info.svgNOTE
Stop command disables all PLSs given in the currently executing motion.

Useful link: Axystems:PLS Timing Issues

Examples

Example 1

Using length of the path (distance from starting point) for the position source. Note that default value of PLSRelateTo is zero therefore all given PLSposition values are computed from the motion start.

common shared GXY as group of axnm = A1 axnm = A2 of XY
common shared P1 as pls GXY Sys.Dout.1
common shared P2 as pls GXY Sys.Dout.2
common shared P3 as pls GXY Sys.Dout.3
CreatePLSdata P1 2 
CreatePLSdata P2 2
CreatePLSdata P3 2

P1.plsposition[1] = 10
P1.plsposition[2] = 90
P2.plsposition[1] = 10
P2.plsposition[2] = 90
P3.plsposition[1] = 10
P3.plsposition[2] = 90

GXY.PLSsource = PathLength 
GXY.en = 1
MOVES {100,0} WithPLS = P1
MOVES {0,100} WithPLS = P2
MOVES {0,0}   WithPLS = P3

Axystems;Path-pls-example1.png

example 2

Using Cartesian axis limits for position source (Setpoint1).

common shared GXY as group of axnm = A1 axnm = A2 of XY
common shared P1 as pls GXY Sys.Dout.1
CreatePLSdata P1 2 
P1.plsposition[1] = 10
P1.plsposition[2] = 100
GXY.PLSsource = Setpoint1
GXY.en = 1
MOVES {0,0} 
MOVES {200,200} WithPLS = P1

example 3

Using path-percentages to switch on/off an output during the motion. We define two PL-positions on at 0% (motion start) and one at motion end (100%). This practically means that the output will be ON during execution of the whole motion and will be switched OFF at the motion end. Again the default value of PLSRelatedTo determines that the percentage is calculated from the motion start.


common shared GXY as group of axnm = A1 axnm = A2 of XY
common shared P1 as pls GXY Sys.Dout.1
CreatePLSdata P1 2 
P1.plsposition[1] = 0
P1.plsposition[2] = 100
GXY.PLSsource = PathPercentage 
GXY.en = 1
MOVES {0,0} 
MOVES {200,200} WithPLS = P1

Axystems;Path-pls-example3.png

example 4

Switching between two movements (not blended). If two motions with same PLS are executed one after another the PLS will be switched OFF in duration of one sample where the path-percentage changes from 100% (first motion) to 0% (second motion). The PLS remains enabled all the time motion is executing.


common shared GXY as group of axnm = A1 axnm = A2 of XY
common shared P1 as pls GXY Sys.Dout.1
CreatePLSdata P1 2 
P1.plsposition[1] = 0
P1.plsposition[2] = 100
GXY.PLSsource = PathPercentage 
GXY.en = 1
MOVES {0,0} 
MOVES {200,200} WithPLS = P1
MOVES {300,300} WithPLS = P1

example 5

Switching between two blended movements. The example shows the system behavior when the PLS-Source is of single type. During actual blending (time when two motions are executed in parallel) the system considers two independent variables passing the given PLS values (in parallel).

  • path length (or a percentage of it) of the first motion is checked if passing the PLSpositions
  • path length (or a percentage of it) of the second motion is checked if passing the PLSpositions

This means that if two motions with same PLS (having pos. on 0%,100%) are belended together the PLS output will be switched OFF during the "double movement" phase (when both motions are superposed/blended).


common shared GXY as group of axnm = A1 axnm = A2 of XY


common shared P1 as pls GXY Sys.Dout.1
CreatePLSdata P1 2 
P1.plsposition[1] = 0
P1.plsposition[2] = 100
GXY.PLSsource = PathPercentage
GXY.BlendingMwthod = 2
GXY.BlendignFactor = 90
GXY.en = 1
MOVES {0,0} 
MOVES {200,200} WithPLS = P1
MOVES {300,300} WithPLS = P1


example 6

Switching the PLS on same distance from beginning and the end of the motion


common shared GXY as group of axnm = A1 axnm = A2 of XY
common shared P1 as pls GXY Sys.Dout.1
common shared P2 as pls GXY Sys.Dout.2
common shared P3 as pls GXY Sys.Dout.3
CreatePLSdata P1 2 
CreatePLSdata P2 2
CreatePLSdata P3 2

P1.plsposition[1] = 10
P1.plsposition[2] = 70
P1.plsRelatedTo   = 0

P2.plsposition[1] = 10
P2.plsposition[2] = 70
P2.plsRelatedTo   = 1

P3.plsposition[1] = 10
P3.plsposition[2] = 70
P3.plsRelatedTo   = 0

GXY.PLSsource = PathLength 
GXY.en = 1
MOVES {100,0} WithPLS = P1
MOVES {0,100} WithPLS = P2
MOVES {0,0}   WithPLS = P3


example 7

Shows the difference in serial movement once that are blend with Vfinal>0 . In both cases the PLSsourceis from type percentage.
Serial movements with VFinal > 0

 common shared pathpls as pls GXY sys.DOut.1 HWAssistance =  TRUE

 createplsdata 1 pathpls 
 pathpls.plsposition[1] = 100
 pathpls.plspropagationdelay = 0
 pathpls.plspolarity  = 0
 plssource = pathpercentage

 sys.DOut.1 = 0
 move {100,100} vcruise = 100 vfinal = 100
 move {100,0} vcruise = 100   vfinal = 100 withpls = pathpls
 circle angle = -90 circlecenter = {0,0}   vcruise = 100 withpls = pathpls

caption Shows axes pcmd , IO (X20) and PLSEnable(X40)



Serial movements with VFinal = 0

 common shared pathpls as pls GXY sys.DOut.1 HWAssistance =  TRUE

 createplsdata 1 pathpls 
 pathpls.plsposition[1] = 100
 pathpls.plspropagationdelay = 0
 pathpls.plspolarity  = 0
 plssource = pathpercentage

 sys.DOut.1 = 0
 move {100,100} vcruise = 100 
 move {100,0} vcruise = 100    withpls = pathpls
 circle angle = -90 circlecenter = {0,0}   vcruise = 100 withpls = pathpls

caption Shows axes pcmd , IO (X20) and PLSEnable(X40)

See Also: ConcatenationOfMovements