diff --git a/.github/workflows/clang_format.yml b/.github/workflows/clang_format.yml index d288de1..5f74608 100644 --- a/.github/workflows/clang_format.yml +++ b/.github/workflows/clang_format.yml @@ -5,10 +5,6 @@ on: branches: - master pull_request: - paths: - - 'snp**' - - '.github/workflows/clang_format.yml' - - '**clang-format' schedule: - cron: '0 5 * * *' diff --git a/.github/workflows/cmake_format.yml b/.github/workflows/cmake_format.yml index 3269c97..e96d526 100644 --- a/.github/workflows/cmake_format.yml +++ b/.github/workflows/cmake_format.yml @@ -5,10 +5,6 @@ on: branches: - master pull_request: - paths: - - 'snp**' - - '.github/workflows/cmake_format.yml' - - '**cmake-format' schedule: - cron: '0 5 * * *' diff --git a/CMakeLists.txt b/CMakeLists.txt index 47367d7..3eeab69 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -53,5 +53,5 @@ install( RUNTIME DESTINATION ${CATKIN_GLOBAL_BIN_DESTINATION}) install(DIRECTORY include/${PROJECT_NAME}/ DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}) - +install(DIRECTORY launch DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}) install(FILES plugin_description.xml DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}) diff --git a/README.md b/README.md new file mode 100644 index 0000000..d778cd6 --- /dev/null +++ b/README.md @@ -0,0 +1,24 @@ +# Trajectory Preview + +ROS-enabled Qt widget and Rviz panel for interactively previewing robot trajectories + +![Trajectory preview panel](docs/panel.png) + +## Usage +The widget subscribes to a `trajectory_msgs/JointTrajectory` definition of a robot trajectory and +publishes a `sensor_msgs/JointState` message corresponding to the state in the trajectory at which the slider is set. + +An Rviz `RobotModel` display can then be used to visualize the preview using the following pipeline: + - The trajectory preview widget publishes joint states (`/trajectory/joint_states`) + - A `JointStatePublisher` node integrates the trajectory preview widget joint states topic (`/trajectory/joint_states`) into a constantly published joint states topic (`/preview/joint_states`) + - A `RobotStatePublisher` node subscribes to the high-level preview joint states topic (`/preview/joint_states`) and creates a TF tree with the prefix `preview` + - The Rviz `RobotModel` display animates the robot model using the `preview`-prefixed TF tree + +This pipeline is provided in the `robot_model_preview_pipeline.launch.xml` file + +## Build +```commandLine +cd +rosdep install --from-paths src -iry +colcon build +``` diff --git a/docs/panel.png b/docs/panel.png new file mode 100644 index 0000000..69dcc55 Binary files /dev/null and b/docs/panel.png differ diff --git a/launch/robot_model_preview_pipeline.launch.xml b/launch/robot_model_preview_pipeline.launch.xml new file mode 100644 index 0000000..b84475b --- /dev/null +++ b/launch/robot_model_preview_pipeline.launch.xml @@ -0,0 +1,18 @@ + + + + + + + + [trajectory/joint_states] + + + + + + + + + + diff --git a/package.xml b/package.xml index d9f340f..4bb67dd 100644 --- a/package.xml +++ b/package.xml @@ -15,6 +15,9 @@ trajectory_msgs libqt5-widgets qtbase5-dev + joint_state_publisher + robot_state_publisher + tf2_ros