From 4acf74a3f7f965ced94655d1c453294c431a9128 Mon Sep 17 00:00:00 2001 From: Shuhei Kozasa Date: Wed, 25 Jan 2023 10:06:29 +0900 Subject: [PATCH] =?UTF-8?q?Humble=E5=AF=BE=E5=BF=9C=20(#48)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Adds namespace * Adds Humble to industrial ci * Changes the order of the libraries * Removes the Foxy distribution from the CI * Updates link * Removes the icon and link. Will replace after the packages gets released * Update GitHub Actions settings (#47) * Updates build farm information and requirements Co-authored-by: Daisuke Sato --- .github/workflows/add-tag.yml | 2 +- .github/workflows/industrial_ci.yml | 4 ++-- README.md | 9 +++++---- raspimouse/include/raspimouse/raspimouse_component.hpp | 8 +++++--- raspimouse/launch/raspimouse.launch.py | 1 + raspimouse/src/raspimouse.cpp | 6 +++--- raspimouse/src/raspimouse_component.cpp | 4 +++- 7 files changed, 20 insertions(+), 14 deletions(-) diff --git a/.github/workflows/add-tag.yml b/.github/workflows/add-tag.yml index ea49f2d..1b087c3 100644 --- a/.github/workflows/add-tag.yml +++ b/.github/workflows/add-tag.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest steps: - name: checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Add tag if: startsWith(github.event.pull_request.title, 'Release') && github.event.pull_request.merged == true env: diff --git a/.github/workflows/industrial_ci.yml b/.github/workflows/industrial_ci.yml index d034fc7..068adc4 100644 --- a/.github/workflows/industrial_ci.yml +++ b/.github/workflows/industrial_ci.yml @@ -17,9 +17,9 @@ jobs: strategy: matrix: env: - - { ROS_DISTRO: foxy, ROS_REPO: ros } + - { ROS_DISTRO: humble, ROS_REPO: ros } runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: "ros-industrial/industrial_ci@master" env: ${{ matrix.env }} diff --git a/README.md b/README.md index b151090..c07bc01 100644 --- a/README.md +++ b/README.md @@ -11,11 +11,11 @@ ROS 2 node for the Raspberry Pi Mouse. [![industrial_ci](https://github.com/rt-net/raspimouse2/workflows/industrial_ci/badge.svg?branch=master)](https://github.com/rt-net/raspimouse2/actions?query=workflow%3Aindustrial_ci+branch%3Amaster) ### Source Build Status on ROS2 Buildfarm -#### Foxy + Focal ([`foxy-devel`](https://github.com/rt-net/raspimouse2/tree/foxy-devel)) -| raspimouse | raspimouse_msgs | -|:---:|:---:| -| [![Build Status](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse__ubuntu_focal__source/badge/icon)](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse__ubuntu_focal__source/) | [![Build Status](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse_msgs__ubuntu_focal__source/badge/icon)](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse_msgs__ubuntu_focal__source/) | +| ROS 2 + Ubuntu | raspimouse | raspimouse_msgs | +|:---:|:---:|:---:| +| Foxy + Focal ([`foxy-devel`](https://github.com/rt-net/raspimouse2/tree/foxy-devel)) | [![Build Status](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse__ubuntu_focal__source/badge/icon)](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse__ubuntu_focal__source/) | [![Build Status](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse_msgs__ubuntu_focal__source/badge/icon)](https://build.ros2.org/view/Fsrc_uF/job/Fsrc_uF__raspimouse_msgs__ubuntu_focal__source/) | +| Humble + Jammy ([`humble-devel`](https://github.com/rt-net/raspimouse2/tree/humble-devel)) | **TODO** | **TODO** | ## Requirements @@ -29,6 +29,7 @@ ROS 2 node for the Raspberry Pi Mouse. - [rt-net/RaspberryPiMouse](https://github.com/rt-net/RaspberryPiMouse) - ROS - [Foxy Fitzroy](https://index.ros.org/doc/ros2/Installation/Foxy/Linux-Install-Debians/) + - [Humble Hawksbill](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html) ## Installation diff --git a/raspimouse/include/raspimouse/raspimouse_component.hpp b/raspimouse/include/raspimouse/raspimouse_component.hpp index 462042a..1abd2d6 100644 --- a/raspimouse/include/raspimouse/raspimouse_component.hpp +++ b/raspimouse/include/raspimouse/raspimouse_component.hpp @@ -53,6 +53,11 @@ extern "C" { } // extern "C" #endif +#include +#include + +#include + #include #include #include @@ -60,14 +65,11 @@ extern "C" { #include #include #include -#include -#include #include #include #include -#include namespace raspimouse { diff --git a/raspimouse/launch/raspimouse.launch.py b/raspimouse/launch/raspimouse.launch.py index 3ba83b4..74f6d05 100644 --- a/raspimouse/launch/raspimouse.launch.py +++ b/raspimouse/launch/raspimouse.launch.py @@ -28,6 +28,7 @@ def generate_launch_description(): mouse_node = LifecycleNode( + namespace='', name='raspimouse', package='raspimouse', executable='raspimouse', output='screen', parameters=[os.path.join(get_package_share_directory( diff --git a/raspimouse/src/raspimouse.cpp b/raspimouse/src/raspimouse.cpp index 0989a12..46b2e5a 100644 --- a/raspimouse/src/raspimouse.cpp +++ b/raspimouse/src/raspimouse.cpp @@ -12,11 +12,11 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include -#include - #include "raspimouse/raspimouse_component.hpp" +#include +#include + int main(int argc, char * argv[]) { rclcpp::init(argc, argv); diff --git a/raspimouse/src/raspimouse_component.cpp b/raspimouse/src/raspimouse_component.cpp index 39a93e9..12092c6 100644 --- a/raspimouse/src/raspimouse_component.cpp +++ b/raspimouse/src/raspimouse_component.cpp @@ -14,7 +14,6 @@ #include "raspimouse/raspimouse_component.hpp" -#define _USE_MATH_DEFINES #include #include #include @@ -22,10 +21,13 @@ #include #include #include + #include "rclcpp/rclcpp.hpp" #include "rosidl_runtime_cpp/message_initialization.hpp" #include "lifecycle_msgs/msg/transition.hpp" +#define _USE_MATH_DEFINES + using namespace std::chrono_literals; using CallbackReturn = rclcpp_lifecycle::node_interfaces::LifecycleNodeInterface::CallbackReturn;