Motion Instructions: Difference between revisions

(Skip)
 
(29 intermediate revisions by the same user not shown)
Line 1:
[[File:Motion Instructions directExample.png|thumb|An theexample robotof to perform3 motion tasksinstructions in a program on the EDIT screen.|alt=|500x500px]]
Motion Instructions are used to direct the robot to perform motion tasks.
 
They detail where the robot should move, how it should calculate the path, where it should move, how fast, and where it should end up.
 
Within motion instructions are the variables and choices that detail where the robot should move, how it should calculate the path, how quickly it moves, and what it should do as it approaches the destination.
 
== Syntax ==
The motion instruction syntax is shown in the following table.
{| class="wikitable"
! Line#
Line 17 ⟶ 20:
| P
| [1]
| Deg/sec10%
| FineFINE
| ACC100
|-
Line 25 ⟶ 28:
| PR
| [2]
| 100%110mm/s
| CNT50
| EV
|-
| 3
|L
|P
|[34]
|250mm/s
|FINE
|
|-
| 4
| C
| P
| [3]
| sec
| Fine
| Offset
|-
| ...
|
| PR
|[6:End]
| 110mm/s2 sec
| FineFINE
| Offset,PR[]
|-
| 45
|
|
|
|
|
|
| cm/min
| CNT37
| Skip LBL[]
|-
| 56
|
|
|
| R[]
|
|
|
|-
|7
|
|
|
|
|
|
|-
|}
===Motion Type:===
[[File:Motion Type Menu.png|thumb]]
C (Circular) - Starting point, intermediate point, endpoint
L (Linear) – Move from one point to another in a straight line. This is a slow, but very precise motion type.
 
J (Joint) – Move from point to point without the requirement of maintaining a straight line. It does not need to maintain a specific path, therefore it is the quickest motion type to reach a position, and results in the lowest amount of wear on the robot's joints and gears. Programs should ideally begin with a joint move to a known starting point. Do not use joint when your path may be obstructed by objects or fixtures.
L (Linear) – Move from one point to another
 
C (Circular) - Move in a circle. The circle always begin at the robot's current position, and flows through the two positions given in the instruction. The first position in the circle instruction is the midpoint, and the second position is the endpoint. Limit the usage to 180 degrees. Always be certain the previous motion instruction's destination is the intended start point for your circle, as otherwise you will encounter the error: "Circle angle too large". Circular instructions spill over into the next line on the screen, exactly as shown on the table above.
J (Joint) – Move individual joints of robot arm, fastest way to move.
 
===Position Type: ===
A (Circular Arc) – Curved paths calculated from a large number of positions. This is not covered in any lab or assignment, and will only appear as extra credit if at all.
===Position Type ===
P – (position) direct position in space. Typically recorded by jogging to point and setting as position value. Each position is unique to the program it is in. P[1] in one program has no relation to P[1] in another.
 
PR (position register) – corresponds to predefined location where position can be found. Position registers are "global" variables that stay the same in all programs. PR[1] used in one program is the same as PR[1] in another. Modifying the contents of a position register will affect all future uses, across all programs.
 
=== Position Number ===
P[n] = (x,y,z,w,p,r,configuration) – configuration describes axis condition at destination
Position numbers are assigned in the order they are placed. They serve as places to store location information.
wrist could be N (not-flipped) or F (flipped), elbow could be U (up) or D (down), robot could be T (Front) or B (back)
 
===Speed:===
When a motion instruction is added to a program, it is automatically assigned the next available position number, and the position is recorded as where the robot currently is. This makes it convenient to first jog to the position you intend to record, then add the motion instruction, as you won't need to "touch up" at all.
 
For an understanding of the contents of the position variables, see [[Data|DATA]].
 
The @ symbol appears on motion instructions while the robot is current at (or very close to) the location which the position has been recorded. It is not part of the motion instruction syntax, merely an indicator to help you.
===Speed===
The speed units are first chosen, then the value is entered.
[[File:Speed Select.png|thumb]]
 
==== Units ====
{| class="wikitable"
|+Valid Units per Motion Type
!Units
!J
!L
!C
!A
!Description
|-
|mm/sec
|
|x
|x
|x
|
|-
|cm/min
|
|x
|x
|x
|
|-
|inch/min
|
|x
|x
|x
|
|-
|deg/sec
|
|x
|x
|x
|
|-
|sec
|x
|x
|x
|x
|
|-
|msec
|x
|x
|x
|x
|
|-
|%
|x
|
|
|
|
|}
XX% - The robot will move at a percentage of its rated speed and given payload.
 
XXmm/s - The robot will move at a speed determined by the velocity of the tool's end.
 
==== Values ====
R[X] - The robot will move at a speed determined by the contents of the register.
===Termination Type:===
 
* SPEED - By default, the value entered would be a direct speed, accepting numeric values.
* Fine – When completing a motion instruction, the robot will reach each point. If the next point is at an angle relative to the path to reach the current point, the robot will accelerate and decelerate as necessary to ensure the point is actually reached. FINE instructions may take additional time.
* REGISTER - The softkey REGISTER will allow you to insert a register as the speed variable.
** DIRECT - The contents of the register at the start of the instruction will be used as the speed value.
** INDIRECT - The contents of the inner register will determine which outer register's contents will be used as the speed value.
 
===Termination Type===
This determines what to do when approaching the destination point given in the motion instruction.
 
* Fine – When completing a motion instruction, the robot will reach each point. If the next point is at an angle relative to the path to reach the current point, the robot will accelerate and decelerate as necessary to ensure the point is actually reached.
** For a very short period of time, the robot will have come to a complete stop. For this reason, most FINE instructions take additional time and are hard on the robot's components.
 
* Continuous (CNT) – When completing a motion instruction, the robot will decelerate as it approaches the point and "round off" the corner as it goes from point to point as a percentage. The number following the CNT option represents the percentage of speed it is allowed to slow to, to make a "best effort" to go toward the point. Continuous motion is healthier for the robot and the robots tools, as acceleration is more spread out.
Line 89 ⟶ 187:
** CNT50 would mean it will choose a best path given the option of reducing to 50% of its otherwise calculated speed.
** CNT0 is very similar to FINE but is computationally distinct, so it may result in a slight difference.
===Motion Modification:===
[[File:Motion Modify Menu.png|thumb|500x500px|This is the Motion Modify menu. |alt=]]
The empty space all the way to the right on a motion instruction line brings up the [CHOICE] option. Pressing this softkey will bring up a motion modification menu, letting you add additional changes and special options to your motion instruction.
 
* No option - Select this element when you wish to remove (or just not add) the selected modification.
* ACC - Acceleration. Use this to limit the acceleration of the motion instruction. Without this modifier, the robot will use normal calculations to determine acceleration and velocity (such as payload, joint limitations, speed variables)
*Wrist Joint
* COORD
*ACC - Acceleration. Use this to limit the acceleration of the motion instruction. Without this modifier, the robot will use normal calculations to determine acceleration and velocity (such as payload, joint limitations, speed variables)
* SKIP,lbl[] Simple Task: Robot has to perform a spot welding(only 1 spot) when it sees a sheet metal which might be placed anywhere between two points (say P[1] and P[2]) 1: SKIP CONDITION DI[y]=ON; -------''(if a senor mounted on robot senses the sheet metal, then DI[y] will be ON and robot has to do a spot welding at that point)'' 2:J P[1] 5% CNT100 Skip,LBL[1]; ------ (''inserting skip instruction in this line means that monitoring for DI[y] has to start from P[1] )'' 3: SPOT(SD=2, P=1, S=5, ED= 4); -------''(As per skip instruction, if skip condition is satisfied i.e. DI[y]= ON, then robot will execute the next line which is a spot in our case)'' <nowiki>4: L PR[1 : home pos] 2000 CNT 100; ----</nowiki>''(optional)'' 4:  LBL[1]; ------''(IF condition is not satisfied, execution jumps to this label directly from line2 and robot moves towards point P[2])'' 6:L P[2] 10 CNT100 ; ''-------(while moving towards P[2], if condition gets satisfied DI[y]=ON , then robot without moving further jumps to line3 immediately and performs the spot)'' <nowiki>7: L PR[1 : home pos] 2000 CNT 100 ;------</nowiki>''(optional)''<br />Note: once condition is satisfied the monitoring will be stopped but the condition specified will be available throughout the program and can be called for checking anytime by inserting a skip instruction
* SKIP,LBL[]
* Offset
**This modifier is added to a motion instruction to skip over subsequent lines if a condition is found to be true.
* Offset,PR[] - Offset by a Position Register. Whatever is in the position register for the offset will be added with the contents of the position used for the motion instruction. The result only affects that motion instruction, the position register and position variable for the instruction will be unchanged.
**The motion line it is added to will complete before evaluating the condition. It simply sets an interrupt once the motion instruction finishes, to stop wherever it happens to be, even mid-motion, to jump to another part of the program instead.
**You would initialize this condition with the line [[SKIP]] CONDITION RI[8]=ON ahead of time.
* Offset/Frames
*[[OFFSETS|Offset,PR[]]] - Offset by a Position Register. Whatever is in the position register for the offset will be added with the contents of the position used for the motion instruction. The result only affects that motion instruction, the position register and position variable for the instruction will be unchanged.
**J P[1] 100% FINE OFFSET PR[3] with 100,100,100,0,0,0 in P[1] and 10,20,30,0,0,0 in PR[3] will actually go to point 110,120,130,0,0,0
* Incremental
* Tool_Offset
* Tool_Offset,PR[
**Offset the instruction's position in the tool reference frame by whatever values are within the given position register. Useful for rotational offsets especially.
* TIME BEFORE/TIME AFTER
**Valid values for TIME AFTER are "real" data type, from 0.000 to 0.500.
**Valid values for TIME BEFORE are "real" data type, from 0.000 to 30.000.
**This modification allows an action to take place at a specified time before or after the '''completion''' of the associated instruction. The following are valid actions to be chosen as a result of the trigger:
***CALL program
***CALL program()
***DO[]=...
***RO[]=...
***GO[]=...
***POINT_LOGIC
***AO[]=...
* Skip,LBL,PR
* DISTANCE BEFORE
* VOFFSET
* VOFFSET,VR[]
* DO[]=... / RO[]=... /GO[]=... /
* AO[]=...
* PTH
 
== Adding Motion ==
[[File:Red Circle POINT.png|thumb|Highlighted in the red circle is the POINT softkey. It brings up the menu shown, listing default motion instructions you can place into your program to customize afterwards.]]
 
 
On the EDIT screen you can add a line by hitting POINT and selecting one of the options. These are pre-determined "default" motion instructions you can use to quickly place a lot of similar lines.
<br />
Once opened, hitting "ED_DEF" on the bottom left of the screen will bring up the default motion list for editing.<br />