From f43d0bb26e1960e77a8ad0d350d1345cf82a9e8b Mon Sep 17 00:00:00 2001 From: HannesSommer Date: Mon, 22 May 2017 14:08:33 +0200 Subject: [PATCH 1/2] Make cuckoo_time_translator depend on rosconsole_bridge This should redirect the console_bridge logging from the algorithms to the rosconsole. --- cuckoo_time_translator/package.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/cuckoo_time_translator/package.xml b/cuckoo_time_translator/package.xml index c3e1b40..a1dccea 100644 --- a/cuckoo_time_translator/package.xml +++ b/cuckoo_time_translator/package.xml @@ -20,6 +20,7 @@ message_runtime cuckoo_time_translator_algorithms + rosconsole_bridge rostest From 06e1372109dece864740eb46c39dd56c6e5463ad Mon Sep 17 00:00:00 2001 From: HannesSommer Date: Thu, 13 Jul 2017 16:07:31 +0200 Subject: [PATCH 2/2] Actually activate rosconsole_bridge using REGISTER_ROSCONSOLE_BRIDGE This seems to be necessary. It is wrong to do it in this library. But the right thing would probably be to do it in rosconsole_bridge itself. --- cuckoo_time_translator/CMakeLists.txt | 1 + cuckoo_time_translator/src/MockCuckooDeviceDriver.cpp | 4 ++-- cuckoo_time_translator/src/RosConsoleBridgeActivator.cpp | 3 +++ cuckoo_time_translator_algorithms/package.xml | 1 + 4 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 cuckoo_time_translator/src/RosConsoleBridgeActivator.cpp diff --git a/cuckoo_time_translator/CMakeLists.txt b/cuckoo_time_translator/CMakeLists.txt index affa6a9..fdd1d1b 100644 --- a/cuckoo_time_translator/CMakeLists.txt +++ b/cuckoo_time_translator/CMakeLists.txt @@ -24,6 +24,7 @@ endif () cs_add_library(${PROJECT_NAME} src/DeviceTimeTranslator.cpp + src/RosConsoleBridgeActivator.cpp ) cs_add_executable(mock_cuckoo_device_driver diff --git a/cuckoo_time_translator/src/MockCuckooDeviceDriver.cpp b/cuckoo_time_translator/src/MockCuckooDeviceDriver.cpp index 7f2b5a1..343350a 100644 --- a/cuckoo_time_translator/src/MockCuckooDeviceDriver.cpp +++ b/cuckoo_time_translator/src/MockCuckooDeviceDriver.cpp @@ -1,11 +1,11 @@ +#include "MockCuckooDeviceDriver.h" + #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wunused-parameter" #include "ros/ros.h" #include "std_msgs/String.h" #pragma GCC diagnostic pop -#include "MockCuckooDeviceDriver.h" - namespace cuckoo_time_translator { constexpr uint32_t MockCuckooDeviceDriver::kWrappingNumber; constexpr double MockCuckooDeviceDriver::kFreq; diff --git a/cuckoo_time_translator/src/RosConsoleBridgeActivator.cpp b/cuckoo_time_translator/src/RosConsoleBridgeActivator.cpp new file mode 100644 index 0000000..411cf62 --- /dev/null +++ b/cuckoo_time_translator/src/RosConsoleBridgeActivator.cpp @@ -0,0 +1,3 @@ +#include + +REGISTER_ROSCONSOLE_BRIDGE; diff --git a/cuckoo_time_translator_algorithms/package.xml b/cuckoo_time_translator_algorithms/package.xml index ed374e0..82c1260 100644 --- a/cuckoo_time_translator_algorithms/package.xml +++ b/cuckoo_time_translator_algorithms/package.xml @@ -16,6 +16,7 @@ roscpp cmake_modules + rosconsole_bridge gtest