No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04.5 LTS
Release: 22.04
Codename: Jammy
ROS2: Humble
sudo apt install ros-humble-moveit*sudo pip install pyserial
sudo pip install fashionstar-uart-sdkcd ~/
git clone https://github.com/Welt-liu/star-arm-moveit2.git
cd ~/star-arm-moveit2
colcon build
echo "source ~/star-arm-moveit2/install/setup.bash" >> ~/.bashrc
source ~/.bashrcstararm.mp4
Viola
ros2 launch viola_moveit_config demo.launch.py Cello
ros2 launch cello_moveit_config demo.launch.py 终端1:启动手臂硬件驱动/Terminal 1: Start the arm hardware driver
手臂会移动到零位/The Arm Will Move to The Zero Position.
Viola
ros2 launch viola_moveit_config driver.launch.pyCello
ros2 launch cello_moveit_config driver.launch.py终端2:启动moveit2/Terminal 2:Starthe Moveit2
Viola
ros2 launch viola_moveit_config actual_robot_demo.launch.pyCello
ros2 launch cello_moveit_config actual_robot_demo.launch.py到此可实现虚拟机械臂控制真实机械臂的功能/At this point, you can control the real robotic arm with the virtual robotic arm.
终端3:启动末端位姿读写示例/Terminal 3: Start the end-effector pose read/write demo
Viola
ros2 launch viola_moveit_config moveit_write_read.launch.pyCello
ros2 launch cello_moveit_config moveit_write_read.launch.py请更新文件/update here
src/arm_moveit_write/src/topic_publisher.cpp
// viola
// dataset1_ = {
// {0.35, -0.00, 0.23}, // position
// {-0.499, 0.500, -0.500, 0.500}, // orientation
// "open" // gripper_state
// };
// dataset2_ = {
// {0.15, -0.00, 0.299}, // position
// {0.500, -0.500, 0.500, -0.499}, // orientation
// "close" // gripper_state
// };
//cello
dataset1_ = {
{0.278, 0.000, 0.438}, // position
{-0.506, 0.507, -0.496, 0.491}, // orientation
"open" // gripper_state
};
dataset2_ = {
{0.479, -0.000, 0.369}, // position
{-0.506, 0.507, -0.496, 0.491}, // orientation
"close" // gripper_state
};
终端4:启动位姿话题发送节点/Terminal 4: Start the position and orientation topic sending node
colcon build
source install/setup.sh
ros2 run arm_moveit_write topic_publisher Tip
在关闭gazebo图形界面后,建议在终端使用 pkill -9 -f gazebo 命令彻底关闭
在运行例程前,需要关闭其他所有正在运行的节点。
安装gazebo/Install gazebo
sudo apt install gazebo
sudo apt install ros-humble-moveit*终端1:启动gazebo图形界面/Terminal 1: Launch the Gazebo graphical user interface
Viola
ros2 launch viola_gazebo viola_gazebo.launch.pyCello
ros2 launch cello_gazebo cello_gazebo.launch.py终端2:启动moveit2界面/Terminal 2:Launch the MoveIt2 interface
Viola
ros2 launch viola_moveit_config gazebo_demo.launch.pyCello
ros2 launch cello_moveit_config gazebo_demo.launch.pyTip
需要重新录制轨迹,可将record-test文件夹删除or新建终端文件名record-test1/Delete the record-test folder, or create a new terminal file name record-test1
终端1:启动手臂硬件驱动(示教模式)/Terminal 1: Start the arm hardware driver (teaching mode)
ros2 run robo_driver driver --ros-args -p lock:='disable'终端2:记录手臂轨迹/Terminal 2: Record arm trajectory
按下回车开始录制,再按下回车结束录制,通过dataset参数指定保存路径/Press Enter to start recording, press Enter to end recording, and specify the save path through the dataset parameter.
ros2 run ros2_bag_recorder bag_recorder --ros-args -p dataset:=star/record-test终端3:重播运行轨迹/Terminal 3: Replay the recorded trajectory
ros2 bag play ./star/record-test如果rivz2界面出现频闪,可以尝试以下指令/ If you experience flickering in the RViz2 interface, try the following commands:
export QT_AUTO_SCREEN_SCALE_FACTOR=0
