<< Prev        Next >>

ID : 5473

Posclr

Function

Forcibly restores the current position of a joint to the designated position.

Syntax

Posclr JntNumber [, Mode[, Value]]

Guaranteed Entry

JntNumber
Designate an axis number by integer type data.
Mode
Specify a mode by integer type data.
This is optional. This sets to "0" if it is omitted.
Mode Value Robot Joint Extended-joint , MC8 Description
Rotary joints Sliding joints Rotary joints Sliding joints
0 - Not available Not available Available Available Restore the current position of a joint specified by <JntNumber> to 0°.
1 - Available Not available Available Not available

Set the current position of a joint specified by <JntNumber> to 0 < 360° or, -360 < 0°.

2 - Available Not available Available Not available Set the current position of a joint specified by <JntNumber> to 0 < 180° or, -180 < 0°.
3 Additional value Available Not available Available Not available

"Additional value" mentioned here stands for "additional angle". This mode forcibly adds an "additional value" to the current position of a joint specified by <JntNumber>.

For robot axes, set the value to a multiple of 360°


Example of rounding to 360°
-540° < N ≤ -180° : set to -360°
-180° < N < 180° : set to 0°
180° ≤ N < 540° : set to 360°
Value
If the mode is 3, specify the value by single precision real number type data. This is optional. This sets to "0" if it is omitted.

Description

Posclr forcibly restores the current position of a joint specified by <JntNumber> to the specified position.A practice to specify a position differs depending on mode. This command is applicable only to joints specified for boundless rotation.
Use this command if a joint keeps on rotating in the same direction so that any of the following happens:
The current position value becomes too large to handle.
The current position value jumps to a large negative value (due to overflow or wrap-around of a variable value).
To execute this command, you need to get an arm group including a joint whose position is to be restored to its origin.

Related Terms

-

Attention

  • If you intend to configure the robot axes, enable the Boundless rotation for Robot(J6) beforehand.
    With reference to the Configuration list, set [149:Boundless rotation for Robot(J6)] to [1:Enable] or [2:Enable(AutoPositionClear)].
    For details, see Configuration List on the FUNCTION GUIDE.
  • If you intend to configure the Extended-joint, in the [Path parameter], set [1:Boundless Rotation(J7)] to [Infinite].
    For details, see Boundless Rotation of Extended-Joints on the EXTENDED-JOINT MANUAL.
  • Posclr cannot be executed unless the target axis completely stops its motion.
    If Posclr is executed while the target axis is moving, an error [0x81201741: You cannot execute a command while an arm is moving.] occurs.
  • You cannot execute PosClr for robot joints when Force control function is enabled. Doing so, an error occurs. To execute PosClr, disable the Force control function.
  • This command overwrites the CALSET value.
    Therefore, after the CALSET value is overwritten, do not send a project that has been made a backup by WINCAPSIII to the controller. Doing so, the CALSET value will be reset to the value where the backup has been made. As a result, the angle may be changed from that of before the project sending.
  • In normal operation at MODE 1, if the angle of the current position is the multiple of +360 degrees, Posclr will reset the axis to 0 degrees. However, it may set to +360 degrees due to the internal calculation error.
    Also, the multiple of -360 degrees may set to -360 degrees.
    Therefore, the motion command that has been written in immediately after Posclr may perform unexpected behavior.
  • Also, in normal operation at MODE 2, if the current position is +180 degrees (the multiple of +360 degrees), Posclr will reset the axis to +180 degrees, but it may set to -180 degrees at times.

Example

Sub Main
    TakeArm 1
    DriveA ( 7, 100 ) 'Move 7th joint to an angle of 100 degrees. 
    PosClr 7 'Force restore the current angle of the 7th
    'joint to 0 degree.
End Sub
Sub Main
    TakeArm Keep = 0
    J1 = J( 0, 45, 90, 0, 45, 370 )
    J2 = J( 0, 45, 90, 0, 45, -10 )
    Move P, J1
    
    'Set the current angle of the 6th joint 
    'to 10 degree. (370-360=10)
    PosClr 6, 1
    
    Move P, J2
End Sub
Sub Main
    TakeArm Keep = 0
    J1 = J( 0, 45, 90, 0, 45, 380 )
    J2 = J( 0, 45, 90, 0, 45, 10 )
    Move P, J1
    
    'Set the current angle of the 6th joint 
    'to 20 degree. (380-360=20)
    PosClr 6, 2
    
    Move P, J2
End Sub
Sub Main
    TakeArm Keep = 0
    J1 = J( 0, 45, 90, 0, 45, 550 )
    J2 = J( 0, 45, 90, 0, 45, -180 )
    Move P, J1
    
    'Deduct 720 degree from the current angle of the 6th joint 
    ' then set the 6th angle to that value.
    PosClr 6, 3, -720
    
    Move P, J2
End Sub

ID : 5473

<< Prev        Next >>