From deb4860b441c54881214a8d01a60bea94d056ae0 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Sat, 18 Jan 2025 17:38:28 +0900 Subject: [PATCH 01/10] feat(bluetooth_monitor): apply `autoware_` prefix (see below): * In this commit, I did not organize a folder structure. The folder structure will be organized in the next some commits. * The changes will follow the Autoware's guideline as below: - https://autowarefoundation.github.io/autoware-documentation/main/contributing/coding-guidelines/ros-nodes/directory-structure/#package-folder Signed-off-by: Junya Sasaki --- system/bluetooth_monitor/CMakeLists.txt | 12 ++++++------ .../include/bluetooth_monitor/bluetooth_monitor.hpp | 13 +++++++++---- .../include/bluetooth_monitor/service/l2ping.hpp | 13 +++++++++---- .../bluetooth_monitor/service/l2ping_interface.hpp | 13 +++++++++---- .../bluetooth_monitor/service/l2ping_service.hpp | 13 +++++++++---- .../launch/bluetooth_monitor.launch.xml | 4 ++-- system/bluetooth_monitor/package.xml | 3 ++- system/bluetooth_monitor/service/l2ping.cpp | 8 +++++++- system/bluetooth_monitor/service/l2ping_service.cpp | 8 +++++++- system/bluetooth_monitor/service/main.cpp | 7 ++++--- system/bluetooth_monitor/src/bluetooth_monitor.cpp | 9 +++++++-- 11 files changed, 71 insertions(+), 32 deletions(-) diff --git a/system/bluetooth_monitor/CMakeLists.txt b/system/bluetooth_monitor/CMakeLists.txt index ea91d77abeeb8..042f0ab9ada1b 100644 --- a/system/bluetooth_monitor/CMakeLists.txt +++ b/system/bluetooth_monitor/CMakeLists.txt @@ -1,11 +1,11 @@ cmake_minimum_required(VERSION 3.5) -project(bluetooth_monitor) +project(autoware_bluetooth_monitor) ### Dependencies find_package(autoware_cmake REQUIRED) autoware_package() -ament_auto_add_library(bluetooth_monitor_lib SHARED +ament_auto_add_library(${PROJECT_NAME} SHARED src/bluetooth_monitor.cpp ) @@ -21,12 +21,12 @@ find_package(Boost REQUIRED COMPONENTS ) ## Specify libraries to link a library or executable target against -target_link_libraries(bluetooth_monitor_lib ${Boost_LIBRARIES}) +target_link_libraries(${PROJECT_NAME} ${Boost_LIBRARIES}) target_link_libraries(l2ping_service ${Boost_LIBRARIES}) -rclcpp_components_register_node(bluetooth_monitor_lib - PLUGIN "BluetoothMonitor" - EXECUTABLE bluetooth_monitor +rclcpp_components_register_node(${PROJECT_NAME} + PLUGIN "autoware::bluetooth_monitor::BluetoothMonitor" + EXECUTABLE ${PROJECT_NAME}_node ) ament_auto_package(INSTALL_TO_SHARE diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/bluetooth_monitor.hpp b/system/bluetooth_monitor/include/bluetooth_monitor/bluetooth_monitor.hpp index 6ebca9b4189d5..14673b47dbfcc 100644 --- a/system/bluetooth_monitor/include/bluetooth_monitor/bluetooth_monitor.hpp +++ b/system/bluetooth_monitor/include/bluetooth_monitor/bluetooth_monitor.hpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -#ifndef BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ -#define BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ +#ifndef AUTOWARE__BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ +#define AUTOWARE__BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ #include "bluetooth_monitor/service/l2ping_interface.hpp" @@ -24,6 +24,9 @@ #include #include +namespace autoware::bluetooth_monitor +{ + class BluetoothMonitor : public rclcpp::Node { public: @@ -109,4 +112,6 @@ class BluetoothMonitor : public rclcpp::Node {StatusCode::FUNCTION_ERROR, DiagStatus::ERROR}}; }; -#endif // BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ +} // namespace autoware::bluetooth_monitor + +#endif // AUTOWARE__BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping.hpp b/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping.hpp index 8d7777f78f743..40bfd0efb5380 100644 --- a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping.hpp +++ b/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping.hpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -#ifndef BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ -#define BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ +#ifndef AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ +#define AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ #include "bluetooth_monitor/service/l2ping_interface.hpp" @@ -22,6 +22,9 @@ #include #include +namespace autoware::bluetooth_monitor +{ + class L2ping { public: @@ -92,4 +95,6 @@ class L2ping bool stop_; //!< @brief Flag to stop thread }; -#endif // BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ +} // namespace autoware::bluetooth_monitor + +#endif // AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_interface.hpp b/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_interface.hpp index 26abc5c4b2ac4..b475377cee9fa 100644 --- a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_interface.hpp +++ b/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_interface.hpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -#ifndef BLUETOOTH_MONITOR__SERVICE__L2PING_INTERFACE_HPP_ -#define BLUETOOTH_MONITOR__SERVICE__L2PING_INTERFACE_HPP_ +#ifndef AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_INTERFACE_HPP_ +#define AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_INTERFACE_HPP_ #include #include @@ -23,6 +23,9 @@ #include #include +namespace autoware::bluetooth_monitor +{ + // 7634-7647 Unassigned static constexpr int DEFAULT_PORT = 7640; static constexpr int DEFAULT_DELAY = 1; @@ -171,4 +174,6 @@ struct L2pingStatus */ typedef std::vector L2pingStatusList; -#endif // BLUETOOTH_MONITOR__SERVICE__L2PING_INTERFACE_HPP_ +} // namespace autoware::bluetooth_monitor + +#endif // AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_INTERFACE_HPP_ diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_service.hpp b/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_service.hpp index 2511311e8ba52..8426796d29f75 100644 --- a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_service.hpp +++ b/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_service.hpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -#ifndef BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ -#define BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ +#ifndef AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ +#define AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ #include "bluetooth_monitor/service/l2ping.hpp" #include "bluetooth_monitor/service/l2ping_interface.hpp" @@ -24,6 +24,9 @@ #include #include +namespace autoware::bluetooth_monitor +{ + class L2pingService { public: @@ -85,4 +88,6 @@ class L2pingService L2pingStatusList status_list_; //!< @brief List of l2ping status }; -#endif // BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ +} // namespace autoware::bluetooth_monitor + +#endif // AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ diff --git a/system/bluetooth_monitor/launch/bluetooth_monitor.launch.xml b/system/bluetooth_monitor/launch/bluetooth_monitor.launch.xml index 7dd98572e544b..d23e7b44d3a32 100644 --- a/system/bluetooth_monitor/launch/bluetooth_monitor.launch.xml +++ b/system/bluetooth_monitor/launch/bluetooth_monitor.launch.xml @@ -1,6 +1,6 @@ - - + + diff --git a/system/bluetooth_monitor/package.xml b/system/bluetooth_monitor/package.xml index f43db39e987b7..8f5c8d2d6ab77 100644 --- a/system/bluetooth_monitor/package.xml +++ b/system/bluetooth_monitor/package.xml @@ -1,10 +1,11 @@ - bluetooth_monitor + autoware_bluetooth_monitor 0.40.0 Bluetooth alive monitoring Fumihito Ito + Junya Sasaki Apache License 2.0 ament_cmake_auto diff --git a/system/bluetooth_monitor/service/l2ping.cpp b/system/bluetooth_monitor/service/l2ping.cpp index 6499f3a2b9612..fd6eabe66fc8a 100644 --- a/system/bluetooth_monitor/service/l2ping.cpp +++ b/system/bluetooth_monitor/service/l2ping.cpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -25,6 +25,10 @@ #define FMT_HEADER_ONLY #include + +namespace autoware::bluetooth_monitor +{ + namespace bp = boost::process; L2ping::L2ping(const std::string & address, const L2pingConfig & config) @@ -189,3 +193,5 @@ const std::string & L2ping::getAddress() const { return status_.address; } + +} // namespace autoware::bluetooth_monitor diff --git a/system/bluetooth_monitor/service/l2ping_service.cpp b/system/bluetooth_monitor/service/l2ping_service.cpp index 827a7e3060acc..8e773de4a2ff0 100644 --- a/system/bluetooth_monitor/service/l2ping_service.cpp +++ b/system/bluetooth_monitor/service/l2ping_service.cpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -30,6 +30,10 @@ #define FMT_HEADER_ONLY #include + +namespace autoware::bluetooth_monitor +{ + namespace bp = boost::process; L2pingService::L2pingService(const int port) : port_(port), socket_(-1) @@ -252,3 +256,5 @@ bool L2pingService::buildDeviceList() return true; } + +} // namespace autoware::bluetooth_monitor diff --git a/system/bluetooth_monitor/service/main.cpp b/system/bluetooth_monitor/service/main.cpp index d3aef2c0696dd..f29baab0ddb09 100644 --- a/system/bluetooth_monitor/service/main.cpp +++ b/system/bluetooth_monitor/service/main.cpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -22,6 +22,7 @@ #include + /** * @brief print usage */ @@ -47,7 +48,7 @@ int main(int argc, char ** argv) // Parse command-line options int c = 0; int option_index = 0; - int port = DEFAULT_PORT; + int port = autoware::bluetooth_monitor::DEFAULT_PORT; while ((c = getopt_long(argc, argv, "hp:", long_options, &option_index)) != -1) { switch (c) { case 'h': @@ -78,7 +79,7 @@ int main(int argc, char ** argv) openlog(nullptr, LOG_PID, LOG_DAEMON); // Initialize l2ping service - L2pingService service(port); + autoware::bluetooth_monitor::L2pingService service(port); if (!service.initialize()) { service.shutdown(); diff --git a/system/bluetooth_monitor/src/bluetooth_monitor.cpp b/system/bluetooth_monitor/src/bluetooth_monitor.cpp index b9c74870c558d..b5f34f51d96eb 100644 --- a/system/bluetooth_monitor/src/bluetooth_monitor.cpp +++ b/system/bluetooth_monitor/src/bluetooth_monitor.cpp @@ -1,4 +1,4 @@ -// Copyright 2022 The Autoware Contributors +// Copyright 2025 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -28,6 +28,9 @@ #define FMT_HEADER_ONLY #include +namespace autoware::bluetooth_monitor +{ + BluetoothMonitor::BluetoothMonitor(const rclcpp::NodeOptions & options) : Node("bluetooth_monitor", options), updater_(this), @@ -199,5 +202,7 @@ void BluetoothMonitor::checkConnection(diagnostic_updater::DiagnosticStatusWrapp setErrorLevel(stat); } +} // namespace autoware::bluetooth_monitor + #include -RCLCPP_COMPONENTS_REGISTER_NODE(BluetoothMonitor) +RCLCPP_COMPONENTS_REGISTER_NODE(autoware::bluetooth_monitor::BluetoothMonitor) From 6ea1e55799ea88bbaa9dd52b11e6c47776321da8 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Sat, 18 Jan 2025 17:43:18 +0900 Subject: [PATCH 02/10] rename(bluetooth_monitor): move headers under `include/autoware`: * Fixes due to this changes for .hpp/.cpp files will be applied in the next commit Signed-off-by: Junya Sasaki --- .../{ => autoware}/bluetooth_monitor/bluetooth_monitor.hpp | 0 .../include/{ => autoware}/bluetooth_monitor/service/l2ping.hpp | 0 .../{ => autoware}/bluetooth_monitor/service/l2ping_interface.hpp | 0 .../{ => autoware}/bluetooth_monitor/service/l2ping_service.hpp | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename system/bluetooth_monitor/include/{ => autoware}/bluetooth_monitor/bluetooth_monitor.hpp (100%) rename system/bluetooth_monitor/include/{ => autoware}/bluetooth_monitor/service/l2ping.hpp (100%) rename system/bluetooth_monitor/include/{ => autoware}/bluetooth_monitor/service/l2ping_interface.hpp (100%) rename system/bluetooth_monitor/include/{ => autoware}/bluetooth_monitor/service/l2ping_service.hpp (100%) diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/bluetooth_monitor.hpp b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp similarity index 100% rename from system/bluetooth_monitor/include/bluetooth_monitor/bluetooth_monitor.hpp rename to system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping.hpp b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp similarity index 100% rename from system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping.hpp rename to system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_interface.hpp b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp similarity index 100% rename from system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_interface.hpp rename to system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp diff --git a/system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_service.hpp b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp similarity index 100% rename from system/bluetooth_monitor/include/bluetooth_monitor/service/l2ping_service.hpp rename to system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp From 8de6ee26c112fe5092e51e9a59817e275b1fd465 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Sat, 18 Jan 2025 17:52:30 +0900 Subject: [PATCH 03/10] fix(bluetooth_monitor): fix include paths * To follow the previous commit Signed-off-by: Junya Sasaki --- .../include/autoware/bluetooth_monitor/bluetooth_monitor.hpp | 2 +- .../include/autoware/bluetooth_monitor/service/l2ping.hpp | 2 +- .../autoware/bluetooth_monitor/service/l2ping_service.hpp | 4 ++-- system/bluetooth_monitor/service/l2ping.cpp | 2 +- system/bluetooth_monitor/service/l2ping_service.cpp | 2 +- system/bluetooth_monitor/service/main.cpp | 4 ++-- system/bluetooth_monitor/src/bluetooth_monitor.cpp | 2 +- 7 files changed, 9 insertions(+), 9 deletions(-) diff --git a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp index 14673b47dbfcc..0f448574befba 100644 --- a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp +++ b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp @@ -15,7 +15,7 @@ #ifndef AUTOWARE__BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ #define AUTOWARE__BLUETOOTH_MONITOR__BLUETOOTH_MONITOR_HPP_ -#include "bluetooth_monitor/service/l2ping_interface.hpp" +#include "autoware/bluetooth_monitor/service/l2ping_interface.hpp" #include #include diff --git a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp index 40bfd0efb5380..307830f2cc8e8 100644 --- a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp +++ b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp @@ -15,7 +15,7 @@ #ifndef AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ #define AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_HPP_ -#include "bluetooth_monitor/service/l2ping_interface.hpp" +#include "autoware/bluetooth_monitor/service/l2ping_interface.hpp" #include #include diff --git a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp index 8426796d29f75..90d57679117aa 100644 --- a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp +++ b/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp @@ -15,8 +15,8 @@ #ifndef AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ #define AUTOWARE__BLUETOOTH_MONITOR__SERVICE__L2PING_SERVICE_HPP_ -#include "bluetooth_monitor/service/l2ping.hpp" -#include "bluetooth_monitor/service/l2ping_interface.hpp" +#include "autoware/bluetooth_monitor/service/l2ping.hpp" +#include "autoware/bluetooth_monitor/service/l2ping_interface.hpp" #include #include diff --git a/system/bluetooth_monitor/service/l2ping.cpp b/system/bluetooth_monitor/service/l2ping.cpp index fd6eabe66fc8a..5cae56ea2fd46 100644 --- a/system/bluetooth_monitor/service/l2ping.cpp +++ b/system/bluetooth_monitor/service/l2ping.cpp @@ -13,7 +13,7 @@ // limitations under the License. // -#include "bluetooth_monitor/service/l2ping.hpp" +#include "autoware/bluetooth_monitor/service/l2ping.hpp" #include diff --git a/system/bluetooth_monitor/service/l2ping_service.cpp b/system/bluetooth_monitor/service/l2ping_service.cpp index 8e773de4a2ff0..32771cb02a2eb 100644 --- a/system/bluetooth_monitor/service/l2ping_service.cpp +++ b/system/bluetooth_monitor/service/l2ping_service.cpp @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "bluetooth_monitor/service/l2ping_service.hpp" +#include "autoware/bluetooth_monitor/service/l2ping_service.hpp" #include #include diff --git a/system/bluetooth_monitor/service/main.cpp b/system/bluetooth_monitor/service/main.cpp index f29baab0ddb09..98f7d2e2f18aa 100644 --- a/system/bluetooth_monitor/service/main.cpp +++ b/system/bluetooth_monitor/service/main.cpp @@ -12,8 +12,8 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "bluetooth_monitor/service/l2ping_interface.hpp" -#include "bluetooth_monitor/service/l2ping_service.hpp" +#include "autoware/bluetooth_monitor/service/l2ping_interface.hpp" +#include "autoware/bluetooth_monitor/service/l2ping_service.hpp" #include diff --git a/system/bluetooth_monitor/src/bluetooth_monitor.cpp b/system/bluetooth_monitor/src/bluetooth_monitor.cpp index b5f34f51d96eb..8436d3f17f608 100644 --- a/system/bluetooth_monitor/src/bluetooth_monitor.cpp +++ b/system/bluetooth_monitor/src/bluetooth_monitor.cpp @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -#include "bluetooth_monitor/bluetooth_monitor.hpp" +#include "autoware/bluetooth_monitor/bluetooth_monitor.hpp" #include #include From ce35adfee1625f3774b102f6d71cf559234432d0 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Sat, 18 Jan 2025 17:53:50 +0900 Subject: [PATCH 04/10] bug(bluetooth_monitor): fix a missing prefix bug Signed-off-by: Junya Sasaki --- system/bluetooth_monitor/src/bluetooth_monitor.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/system/bluetooth_monitor/src/bluetooth_monitor.cpp b/system/bluetooth_monitor/src/bluetooth_monitor.cpp index 8436d3f17f608..eff4a118689bc 100644 --- a/system/bluetooth_monitor/src/bluetooth_monitor.cpp +++ b/system/bluetooth_monitor/src/bluetooth_monitor.cpp @@ -32,7 +32,7 @@ namespace autoware::bluetooth_monitor { BluetoothMonitor::BluetoothMonitor(const rclcpp::NodeOptions & options) -: Node("bluetooth_monitor", options), +: Node("autoware_bluetooth_monitor", options), updater_(this), socket_(-1), port_(declare_parameter("port")) From 55675960f5befcda5c1b9488d766f8363a21add4 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Sat, 18 Jan 2025 17:58:12 +0900 Subject: [PATCH 05/10] rename: `bluetooth_monitor` => `autoware_bluetooth_monitor` Signed-off-by: Junya Sasaki --- .../CHANGELOG.rst | 0 .../CMakeLists.txt | 0 .../{bluetooth_monitor => autoware_bluetooth_monitor}/README.md | 0 .../config/bluetooth_monitor.param.yaml | 0 .../docs/block_diagram.drawio.svg | 0 .../include/autoware/bluetooth_monitor/bluetooth_monitor.hpp | 0 .../include/autoware/bluetooth_monitor/service/l2ping.hpp | 0 .../autoware/bluetooth_monitor/service/l2ping_interface.hpp | 0 .../include/autoware/bluetooth_monitor/service/l2ping_service.hpp | 0 .../launch/bluetooth_monitor.launch.xml | 0 .../{bluetooth_monitor => autoware_bluetooth_monitor}/package.xml | 0 .../schema/bluetooth_monitor.schema.json | 0 .../service/l2ping.cpp | 0 .../service/l2ping_service.cpp | 0 .../service/main.cpp | 0 .../src/bluetooth_monitor.cpp | 0 16 files changed, 0 insertions(+), 0 deletions(-) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/CHANGELOG.rst (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/CMakeLists.txt (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/README.md (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/config/bluetooth_monitor.param.yaml (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/docs/block_diagram.drawio.svg (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/include/autoware/bluetooth_monitor/service/l2ping.hpp (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/include/autoware/bluetooth_monitor/service/l2ping_service.hpp (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/launch/bluetooth_monitor.launch.xml (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/package.xml (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/schema/bluetooth_monitor.schema.json (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/service/l2ping.cpp (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/service/l2ping_service.cpp (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/service/main.cpp (100%) rename system/{bluetooth_monitor => autoware_bluetooth_monitor}/src/bluetooth_monitor.cpp (100%) diff --git a/system/bluetooth_monitor/CHANGELOG.rst b/system/autoware_bluetooth_monitor/CHANGELOG.rst similarity index 100% rename from system/bluetooth_monitor/CHANGELOG.rst rename to system/autoware_bluetooth_monitor/CHANGELOG.rst diff --git a/system/bluetooth_monitor/CMakeLists.txt b/system/autoware_bluetooth_monitor/CMakeLists.txt similarity index 100% rename from system/bluetooth_monitor/CMakeLists.txt rename to system/autoware_bluetooth_monitor/CMakeLists.txt diff --git a/system/bluetooth_monitor/README.md b/system/autoware_bluetooth_monitor/README.md similarity index 100% rename from system/bluetooth_monitor/README.md rename to system/autoware_bluetooth_monitor/README.md diff --git a/system/bluetooth_monitor/config/bluetooth_monitor.param.yaml b/system/autoware_bluetooth_monitor/config/bluetooth_monitor.param.yaml similarity index 100% rename from system/bluetooth_monitor/config/bluetooth_monitor.param.yaml rename to system/autoware_bluetooth_monitor/config/bluetooth_monitor.param.yaml diff --git a/system/bluetooth_monitor/docs/block_diagram.drawio.svg b/system/autoware_bluetooth_monitor/docs/block_diagram.drawio.svg similarity index 100% rename from system/bluetooth_monitor/docs/block_diagram.drawio.svg rename to system/autoware_bluetooth_monitor/docs/block_diagram.drawio.svg diff --git a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp similarity index 100% rename from system/bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp rename to system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp diff --git a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp similarity index 100% rename from system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp rename to system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp diff --git a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp similarity index 100% rename from system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp rename to system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp diff --git a/system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp similarity index 100% rename from system/bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp rename to system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp diff --git a/system/bluetooth_monitor/launch/bluetooth_monitor.launch.xml b/system/autoware_bluetooth_monitor/launch/bluetooth_monitor.launch.xml similarity index 100% rename from system/bluetooth_monitor/launch/bluetooth_monitor.launch.xml rename to system/autoware_bluetooth_monitor/launch/bluetooth_monitor.launch.xml diff --git a/system/bluetooth_monitor/package.xml b/system/autoware_bluetooth_monitor/package.xml similarity index 100% rename from system/bluetooth_monitor/package.xml rename to system/autoware_bluetooth_monitor/package.xml diff --git a/system/bluetooth_monitor/schema/bluetooth_monitor.schema.json b/system/autoware_bluetooth_monitor/schema/bluetooth_monitor.schema.json similarity index 100% rename from system/bluetooth_monitor/schema/bluetooth_monitor.schema.json rename to system/autoware_bluetooth_monitor/schema/bluetooth_monitor.schema.json diff --git a/system/bluetooth_monitor/service/l2ping.cpp b/system/autoware_bluetooth_monitor/service/l2ping.cpp similarity index 100% rename from system/bluetooth_monitor/service/l2ping.cpp rename to system/autoware_bluetooth_monitor/service/l2ping.cpp diff --git a/system/bluetooth_monitor/service/l2ping_service.cpp b/system/autoware_bluetooth_monitor/service/l2ping_service.cpp similarity index 100% rename from system/bluetooth_monitor/service/l2ping_service.cpp rename to system/autoware_bluetooth_monitor/service/l2ping_service.cpp diff --git a/system/bluetooth_monitor/service/main.cpp b/system/autoware_bluetooth_monitor/service/main.cpp similarity index 100% rename from system/bluetooth_monitor/service/main.cpp rename to system/autoware_bluetooth_monitor/service/main.cpp diff --git a/system/bluetooth_monitor/src/bluetooth_monitor.cpp b/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp similarity index 100% rename from system/bluetooth_monitor/src/bluetooth_monitor.cpp rename to system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp From ca6495e2ec1159210cb3d71f5d96d62a5f29a3a0 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 18 Jan 2025 09:03:47 +0000 Subject: [PATCH 06/10] style(pre-commit): autofix --- system/autoware_bluetooth_monitor/service/l2ping.cpp | 1 - system/autoware_bluetooth_monitor/service/l2ping_service.cpp | 1 - system/autoware_bluetooth_monitor/service/main.cpp | 1 - 3 files changed, 3 deletions(-) diff --git a/system/autoware_bluetooth_monitor/service/l2ping.cpp b/system/autoware_bluetooth_monitor/service/l2ping.cpp index 5cae56ea2fd46..69bf5eecfcbc2 100644 --- a/system/autoware_bluetooth_monitor/service/l2ping.cpp +++ b/system/autoware_bluetooth_monitor/service/l2ping.cpp @@ -25,7 +25,6 @@ #define FMT_HEADER_ONLY #include - namespace autoware::bluetooth_monitor { diff --git a/system/autoware_bluetooth_monitor/service/l2ping_service.cpp b/system/autoware_bluetooth_monitor/service/l2ping_service.cpp index 32771cb02a2eb..f967d5559ad27 100644 --- a/system/autoware_bluetooth_monitor/service/l2ping_service.cpp +++ b/system/autoware_bluetooth_monitor/service/l2ping_service.cpp @@ -30,7 +30,6 @@ #define FMT_HEADER_ONLY #include - namespace autoware::bluetooth_monitor { diff --git a/system/autoware_bluetooth_monitor/service/main.cpp b/system/autoware_bluetooth_monitor/service/main.cpp index 98f7d2e2f18aa..cf8b7ff4f1110 100644 --- a/system/autoware_bluetooth_monitor/service/main.cpp +++ b/system/autoware_bluetooth_monitor/service/main.cpp @@ -22,7 +22,6 @@ #include - /** * @brief print usage */ From ba2500503a8cf1f872ef1df01da03db6c9eec6b6 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Tue, 21 Jan 2025 21:03:48 +0900 Subject: [PATCH 07/10] bug(autoware_bluetooth_monitor): revert wrongly updated copyrights Signed-off-by: Junya Sasaki --- .../include/autoware/bluetooth_monitor/bluetooth_monitor.hpp | 2 +- .../include/autoware/bluetooth_monitor/service/l2ping.hpp | 2 +- .../autoware/bluetooth_monitor/service/l2ping_interface.hpp | 2 +- .../autoware/bluetooth_monitor/service/l2ping_service.hpp | 2 +- system/autoware_bluetooth_monitor/service/l2ping.cpp | 2 +- system/autoware_bluetooth_monitor/service/l2ping_service.cpp | 2 +- system/autoware_bluetooth_monitor/service/main.cpp | 2 +- system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp index 0f448574befba..60f6ec1adc648 100644 --- a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp +++ b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/bluetooth_monitor.hpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp index 307830f2cc8e8..5ff24f687f465 100644 --- a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp +++ b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping.hpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp index b475377cee9fa..f02f2cec12d27 100644 --- a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp +++ b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_interface.hpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp index 90d57679117aa..21a42718093b2 100644 --- a/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp +++ b/system/autoware_bluetooth_monitor/include/autoware/bluetooth_monitor/service/l2ping_service.hpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/system/autoware_bluetooth_monitor/service/l2ping.cpp b/system/autoware_bluetooth_monitor/service/l2ping.cpp index 69bf5eecfcbc2..4911825e5bf04 100644 --- a/system/autoware_bluetooth_monitor/service/l2ping.cpp +++ b/system/autoware_bluetooth_monitor/service/l2ping.cpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/system/autoware_bluetooth_monitor/service/l2ping_service.cpp b/system/autoware_bluetooth_monitor/service/l2ping_service.cpp index f967d5559ad27..20bb6104692af 100644 --- a/system/autoware_bluetooth_monitor/service/l2ping_service.cpp +++ b/system/autoware_bluetooth_monitor/service/l2ping_service.cpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/system/autoware_bluetooth_monitor/service/main.cpp b/system/autoware_bluetooth_monitor/service/main.cpp index cf8b7ff4f1110..eb2bd5f3d5cc0 100644 --- a/system/autoware_bluetooth_monitor/service/main.cpp +++ b/system/autoware_bluetooth_monitor/service/main.cpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp b/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp index eff4a118689bc..001c95b832c4a 100644 --- a/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp +++ b/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp @@ -1,4 +1,4 @@ -// Copyright 2025 The Autoware Contributors +// Copyright 2022 The Autoware Contributors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. From 6eb6bcd3f1cf9d8656c2345d353672ad9ad15986 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Tue, 21 Jan 2025 21:05:04 +0900 Subject: [PATCH 08/10] bug(autoware_bluetooth_monitor): `autoware_` prefix is not needed here Signed-off-by: Junya Sasaki --- system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp b/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp index 001c95b832c4a..e9fcb56d41622 100644 --- a/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp +++ b/system/autoware_bluetooth_monitor/src/bluetooth_monitor.cpp @@ -32,7 +32,7 @@ namespace autoware::bluetooth_monitor { BluetoothMonitor::BluetoothMonitor(const rclcpp::NodeOptions & options) -: Node("autoware_bluetooth_monitor", options), +: Node("bluetooth_monitor", options), updater_(this), socket_(-1), port_(declare_parameter("port")) From 1e3cc9fcee5e564a8cbbf8925d7ee042b601bbd5 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Tue, 21 Jan 2025 21:08:48 +0900 Subject: [PATCH 09/10] update: `CODEOWNERS` Signed-off-by: Junya Sasaki --- .github/CODEOWNERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 526467d0e5e4f..ca8ad6349d12a 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -210,7 +210,7 @@ simulator/vehicle_door_simulator/** isamu.takagi@tier4.jp system/autoware_component_monitor/** baris@leodrive.ai memin@leodrive.ai yavuz@leodrive.ai system/autoware_default_adapi/** isamu.takagi@tier4.jp ryohsuke.mitsudome@tier4.jp yukihiro.saito@tier4.jp system/autoware_processing_time_checker/** kosuke.takeuchi@tier4.jp takayuki.murooka@tier4.jp -system/bluetooth_monitor/** fumihito.ito@tier4.jp +system/autoware_bluetooth_monitor/** fumihito.ito@tier4.jp junya.sasaki@tier4.jp system/component_state_monitor/** isamu.takagi@tier4.jp system/default_ad_api_helpers/ad_api_adaptors/** isamu.takagi@tier4.jp ryohsuke.mitsudome@tier4.jp yukihiro.saito@tier4.jp system/default_ad_api_helpers/ad_api_visualizers/** isamu.takagi@tier4.jp ryohsuke.mitsudome@tier4.jp yukihiro.saito@tier4.jp From b9c07c8f80cb445332536739a9e17d36964696a8 Mon Sep 17 00:00:00 2001 From: Junya Sasaki Date: Tue, 21 Jan 2025 21:09:08 +0900 Subject: [PATCH 10/10] update(autoware_bluetooth_monitor): `README.md` Signed-off-by: Junya Sasaki --- system/autoware_bluetooth_monitor/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/system/autoware_bluetooth_monitor/README.md b/system/autoware_bluetooth_monitor/README.md index c0f9c3aecca98..a32069624e113 100644 --- a/system/autoware_bluetooth_monitor/README.md +++ b/system/autoware_bluetooth_monitor/README.md @@ -46,7 +46,7 @@ L2ping is only allowed for root by default, so this package provides the followi ## Parameters -{{ json_to_markdown("system/bluetooth_monitor/schema/bluetooth_monitor.schema.json") }} +{{ json_to_markdown("system/autoware_bluetooth_monitor/schema/bluetooth_monitor.schema.json") }} - `rtt_warn` @@ -71,7 +71,7 @@ L2ping is only allowed for root by default, so this package provides the followi ```sh ./build/bluetooth_monitor/l2ping_service - ros2 launch bluetooth_monitor bluetooth_monitor.launch.xml + ros2 launch autoware_bluetooth_monitor bluetooth_monitor.launch.xml ``` ## Known limitations and issues