From 13071c6e48c87934dce2d0b52122aa73145a9dbf Mon Sep 17 00:00:00 2001 From: Stefan Scherzinger Date: Wed, 17 Apr 2024 15:19:18 +0200 Subject: [PATCH] Fix CI for missing curl dependency --- .github/script/install_dependencies.sh | 3 ++ .../workflows/industrial_ci_humble_action.yml | 2 ++ .../workflows/industrial_ci_iron_action.yml | 2 ++ .../industrial_ci_rolling_action.yml | 2 ++ README.md | 28 ++++++------------- src/schunk_gripper/CMakeLists.txt | 2 -- 6 files changed, 18 insertions(+), 21 deletions(-) create mode 100755 .github/script/install_dependencies.sh diff --git a/.github/script/install_dependencies.sh b/.github/script/install_dependencies.sh new file mode 100755 index 0000000..5b7b55b --- /dev/null +++ b/.github/script/install_dependencies.sh @@ -0,0 +1,3 @@ +#/usr/bin/bash +cd $HOME +apt-get install curl libcurl4-openssl-dev diff --git a/.github/workflows/industrial_ci_humble_action.yml b/.github/workflows/industrial_ci_humble_action.yml index 9b0f95c..7c1c1d9 100644 --- a/.github/workflows/industrial_ci_humble_action.yml +++ b/.github/workflows/industrial_ci_humble_action.yml @@ -10,6 +10,8 @@ on: jobs: industrial_ci: + env: + BEFORE_BUILD_TARGET_WORKSPACE: '.github/script/install_dependencies.sh' strategy: fail-fast: false matrix: diff --git a/.github/workflows/industrial_ci_iron_action.yml b/.github/workflows/industrial_ci_iron_action.yml index 5979b4e..4e518c0 100644 --- a/.github/workflows/industrial_ci_iron_action.yml +++ b/.github/workflows/industrial_ci_iron_action.yml @@ -10,6 +10,8 @@ on: jobs: industrial_ci: + env: + BEFORE_BUILD_TARGET_WORKSPACE: '.github/script/install_dependencies.sh' strategy: fail-fast: false matrix: diff --git a/.github/workflows/industrial_ci_rolling_action.yml b/.github/workflows/industrial_ci_rolling_action.yml index 37e8a26..9bc91ab 100644 --- a/.github/workflows/industrial_ci_rolling_action.yml +++ b/.github/workflows/industrial_ci_rolling_action.yml @@ -10,6 +10,8 @@ on: jobs: industrial_ci: + env: + BEFORE_BUILD_TARGET_WORKSPACE: '.github/script/install_dependencies.sh' strategy: fail-fast: false matrix: diff --git a/README.md b/README.md index 96328eb..e54ce60 100644 --- a/README.md +++ b/README.md @@ -4,28 +4,18 @@ # Schunk EGU/EGK Gripper +This is the ROS2 driver for controlling the SCHUNK EGU/EGK grippers. It is compatible with +grippers featuring PROFINET, Ethernet/IP, or EtherCAT and communicates with the AnybusCom 40 interface. +The driver supports most gripper functionalities, except for the jog mode. -## Description +## System dependencies -ROS2 driver for controlling Schunk EGU/EGK grippers. It is compatible with grippers featuring PROFINET, Ethernet/IP, or EtherCAT communication interfaces. The ROS driver encapsulates all gripper functionalities, excluding the jog mode. - - -### Background - -The driver communicates with the AnybusCom 40 interface, enabling its use with PROFINET, Ethernet/IP, and EtherCAT grippers over HTTP. The ROS wrapper exposes the gripper's functionalities through ROS. - -## Requirements - -The provided distribution is "humble." To install ROS2 and verify compatibility with your operating system, please refer to the following link: -[ROS2 Installation Guide](https://docs.ros.org/en/humble/Installation.html) - -Following C++ libraries are required: -- [libcurl](https://curl.se/libcurl/) -- [nlohmann/json](https://github.com/nlohmann/json) - -'nlohmann/json' is included in the project. You don't need to download it separately. +We use the _curl_ library for the _HTTP_-based communication to the devices. Install that system-wide with +```bash +sudo apt install curl libcurl4-openssl-dev +``` -## Build +## Build and install Clone the GitLab repository into your workspace: ``` git clone https://gitlab-test.cloud.schunk.com/technology-factory/students/ros-gripper/ros2_schunk_driver.git diff --git a/src/schunk_gripper/CMakeLists.txt b/src/schunk_gripper/CMakeLists.txt index a7b7576..2e2fb9b 100644 --- a/src/schunk_gripper/CMakeLists.txt +++ b/src/schunk_gripper/CMakeLists.txt @@ -89,7 +89,6 @@ target_compile_definitions(schunk_gripper_driver # Link libraries to schunk_gripper_driver target_link_libraries(schunk_gripper_driver ${CURL_LIBRARIES} - -lcurl ) # Add dependencies for schunk_gripper_driver @@ -104,7 +103,6 @@ rclcpp_components_register_nodes(schunk_gripper_driver "SchunkGripperNode") # Link libraries to schunk_gripper_driver target_link_libraries(schunk_gripper_driver ${CURL_LIBRARIES} - -lcurl ) # Install schunk_gripper_example executable