Python:
Robotic Arm Motion Parameter ConfigurationArmTipVelocityParameters
It is used to set and get the motion parameters of the robotic arm. The following is a detailed description of the member functions of the robotic arm motion parameter ArmTipVelocityParameters
, including the method prototype, parameter description, return value, and usage demo.
Set the maximum linear speed of the end effectorrm_set_arm_max_line_speed()
- Method prototype:
python
rm_set_arm_max_line_speed(self, speed: float) -> int:
- Parameter description:
Parameter | Type | Description |
---|---|---|
speed | float | Maximum linear speed of the end effector, in m/s. |
- Return value: State codes executed by functions:
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_set_arm_max_line_speed(0.25))
arm.rm_delete_robot_arm()
Set the maximum linear acceleration of the end effectorrm_set_arm_max_line_acc()
- Method prototype:
python
rm_set_arm_max_line_acc(self, acc: float) -> int:
- Parameter description:
Parameter | Type | Description |
---|---|---|
acc | float | Maximum linear acceleration of the end effector, in m/s^2. |
- Return value: State codes executed by functions:
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_set_arm_max_line_acc(1.6))
arm.rm_delete_robot_arm()
Set the maximum angular speed of the end effectorrm_set_arm_max_angular_speed()
- Method prototype:
python
rm_set_arm_max_angular_speed(self, speed: float) -> int:
- Parameter description:
Parameter | Type | Description |
---|---|---|
speed | float | Maximum angular speed of the end effector, in rad/s. |
- Return value: State codes executed by functions:
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_set_arm_max_angular_speed(0.6))
arm.rm_delete_robot_arm()
Set the maximum angular speed of the end effectorrm_set_arm_max_angular_acc()
- Method prototype:
python
rm_set_arm_max_angular_acc(self, acc: float) -> int:
- Parameter description:
Parameter | Type | Description |
---|---|---|
acc | float | Maximum angular acceleration of the end effector, in rad/s^2 |
- Return value: State codes executed by functions:
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_set_arm_max_angular_acc(4))
arm.rm_delete_robot_arm()
Set the end effector parameters to defaultsrm_set_arm_tcp_init()
- Method prototype:
python
rm_set_arm_tcp_init(self) -> int:
- Return value: State codes executed by functions:
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
# Initialize the parameters of the robotic arm, and the end effector parameters will be restored to defaults. The defaults of the end effector are:
# Linear speed: 0.1 m/s; linear acceleration: 0.5 m/s²
# Angular speed: 0.2 rad/s; angular acceleration: 1 rad/s²
print(arm.rm_set_arm_tcp_init())
arm.rm_delete_robot_arm()
Set the dynamic collision stage of the robotic armrm_set_collision_state()
- Method prototype:
python
rm_set_collision_state(self, stage: int) -> int:
- Parameter description:
Parameter | Type | Description |
---|---|---|
stage | int | Stage: 0-8, 0: no collision detection, 8: most sensitive collision detection. |
- Return value: State codes executed by functions:
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
# Set the collision stage of the robotic arm to 1
print(arm.rm_set_collision_state(1))
arm.rm_delete_robot_arm()
Get the collision stage rm_get_collision_stage()
- Method prototype:
python
rm_get_collision_stage(self) -> tuple[int, int]:
- Return value:
tuple[int,int]
: a tuple containing two elements.
- State codes executed by functions
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Collision stage
Parameter | Type | Description |
---|---|---|
0~8 | int | Stage: 0-8, 0: no collision detection, 8: most sensitive collision detection. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_get_collision_stage())
arm.rm_delete_robot_arm()
Get the maximum linear speed of the end effectorrm_get_arm_max_line_speed()
- Method prototype:
python
rm_get_arm_max_line_speed(self) -> tuple[int, float]:
- Return value:
tuple[int,int]
: a tuple containing two elements.
- State codes executed by functions
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Maximum linear speed of the end effector
Parameter | Type | Description |
---|---|---|
- | float | Maximum linear speed of the end effector, in m/s. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_get_arm_max_line_speed())
arm.rm_delete_robot_arm()
Get the maximum linear acceleration of the end effectorrm_get_arm_max_line_acc()
- Method prototype:
python
rm_get_arm_max_line_acc(self) -> tuple[int, float]:
- Return value:
tuple[int,float]
: a tuple containing two elements.
- State codes executed by functions
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
1 | int | The controller returns false, indicating that the parameters are sent incorrectly or the robotic arm state is wrong. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Maximum linear acceleration of the end effector
Parameter | Type | Description |
---|---|---|
- | float | Maximum linear acceleration of the end effector, in m/s^2. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_get_arm_max_line_acc())
arm.rm_delete_robot_arm()
Get the maximum angular speed of the end effectorrm_get_arm_max_angular_speed()
- Method prototype:
python
rm_get_arm_max_angular_speed(self) -> tuple[int, float]:
- Return value:
tuple[int,float]
: a tuple containing two elements.
- State codes executed by functions
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Maximum angular speed of the end effector
Parameter | Type | Description |
---|---|---|
- | float | Maximum angular speed of the end effector, in rad/s. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_get_arm_max_angular_speed())
arm.rm_delete_robot_arm()
Get the maximum angular acceleration of the end effectorrm_get_arm_max_angular_acc()
- Method prototype:
python
rm_get_arm_max_angular_speed(self) -> tuple[int, float]:
- Return value:
tuple[int,float]
: a tuple containing two elements.
- State codes executed by functions
Parameter | Type | Description |
---|---|---|
0 | int | Success. |
-1 | int | The data transmission fails, indicating that a problem occurs during the communication. |
-2 | int | The data reception fails, indicating that a problem occurs during the communication, or the controller has a return timeout. |
-3 | int | The return value parse fails, indicating that the received data format is incorrect or incomplete. |
- Maximum angular acceleration of the end effector
Parameter | Type | Description |
---|---|---|
- | float | Maximum angular acceleration of the end effector, in rad/s^2. |
- Usage demo
python
from Robotic_Arm.rm_robot_interface import *
# Instantiate the RoboticArm class
arm = RoboticArm(rm_thread_mode_e.RM_TRIPLE_MODE_E)
# Create the robotic arm connection and print the connection ID
handle = arm.rm_create_robot_arm("192.168.1.18", 8080)
print(handle.id)
print(arm.rm_get_arm_max_angular_acc())
arm.rm_delete_robot_arm()