Skip to main content
Skip table of contents

amovesj()

Features

The asynchronous movesj motion operates in the same way as movesj() except for the asynchronous processing.

Generating a new command for the motion before the amovesj() motion results in an error for safety reasons. Therefore, the termination of the amovesj() motion must be confirmed using mwait() or check_motion() between amovesj() and the following motion command.

Note

  • movesj(pos_list): The next command is executed after the robot starts from the current position and reaches (stops at) the end point of pos_list.
  • amovesj(pos_list): The next command is executed regardless of whether the robot starts from the current position and reaches (stops at) the end point of pos_list.

Parameters

Parameter Name

Data Type

Default Value

Description

pos_list

list (posj)

-

posj list

vel (v)

float

None

velocity (same to all axes) or

velocity (to an axis)


list (float[6])

acc (a)

float

None

acceleration (same to all axes) or

acceleration (acceleration to an axis)


list (float[6])

time (t)

float

None

Reach time [sec]

mod

int

DR_MV_MOD_ABS

Movement basis

  • DR_MV_MOD_ABS: Absolute
  • DR_MV_MOD_REL: Relative

Note

  • Abbreviated parameter names are supported. (v:vel, a:acc, t:time)
  • _global_velj is applied if vel is None. (The initial value of _global_velj is 0.0 and can be set by set_velj.)
  • _global_accj is applied if acc is None. (The initial value of _global_accj is 0.0 and can be set by set_accj.)
  • If the time is specified, values are processed based on time, ignoring vel and acc.
  • If the time is None, it is set to 0.
  • If the mod is DR_MV_MOD_REL, each pos in the pos_list is defined in the relative coordinate of the previous pos. (If pos_list=[q1, q2, ...,q(n-1), q(n)], q1 is the relative angle of the starting point while q(n) is the relative coordinate of q(n-1).)
  • This function does not support online blending of previous and subsequent motions.

Return

ValueDescription

0

Success

Negative value

Error

Exception

ExceptionDescription

DR_Error (DR_ERROR_TYPE)

Parameter data type error occurred

DR_Error (DR_ERROR_VALUE)

Parameter value is invalid

DR_Error (DR_ERROR_RUNTIME)

C extension module error occurred

DR_Error (DR_ERROR_STOP)

Program terminated forcefully

Example

PY
#Example 1. D-Out 3 seconds after the spline motion through q1 - q5 begins
q0 = posj(0,0,0,0,0,0)
movej(q0, vel=30, acc=60)   # Moves in joint motion to the initial position (q0).
q1 = posj(10, -10, 20, -30, 10, 20)      # Defines the posj variable (joint angle) q1.
q2 = posj(25, 0, 10, -50, 20, 40) 
q3 = posj(50, 50, 50, 50, 50, 50) 
q4 = posj(30, 10, 30, -20, 10, 60)
q5 = posj(20, 20, 40, 20, 0, 90)

qlist = [q1, q2, q3, q4, q5]            
	# Defines the list (qlist) which is a set of waypoints q1-q5.

amovesj(qlist, vel=30, acc=100)   
	# Moves the spline curve that connects the waypoints defined in the qlist.
	# with a maximum velocity of 30(mm/sec) and maximum acceleration of 100(mm/sec2). 
	# Executes the next command.
wait(3)                                  # Temporarily suspends the program execution for 3 seconds (while the motion continues).
set_digital_output(1, 1)                 # D-Out (no. 1 channel) ON
mwait(0)                                 # Temporarily suspends the program execution until the motion is terminated.

Related commands

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.