Skip to content

Commit

Permalink
Declare speckle filter params writeable
Browse files Browse the repository at this point in the history
  • Loading branch information
jonbinney committed Sep 10, 2024
1 parent ed29567 commit eb7708e
Show file tree
Hide file tree
Showing 20 changed files with 114 additions and 0 deletions.
12 changes: 12 additions & 0 deletions include/laser_filters/speckle_filter.h
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,18 @@ class LaserScanSpeckleFilter : public filters::FilterBase<sensor_msgs::msg::Lase

///////////////////////////////////////////////////////////////
bool configure(){

#ifdef RCLCPP_SUPPORTS_POST_SET_PARAMS_CALLBACK
// Declare parameters as writeable. Otherwise, the first time we call FilterBase::getParam() for each one,
// it will get declared as write only.
rcl_interfaces::msg::ParameterDescriptor desc;
desc.read_only = true;
params_interface_->declare_parameter("filter_type", rclcpp::ParameterType::PARAMETER_INTEGER, desc);
params_interface_->declare_parameter("max_range", rclcpp::ParameterType::PARAMETER_DOUBLE, desc);
params_interface_->declare_parameter("max_range_difference", rclcpp::ParameterType::PARAMETER_DOUBLE, desc);
params_interface_->declare_parameter("filter_window", rclcpp::ParameterType::PARAMETER_INTEGER, desc);
#endif

// get params
if (!filters::FilterBase<sensor_msgs::msg::LaserScan>::getParam(std::string("filter_type"), filter_type))
{
Expand Down
1 change: 1 addition & 0 deletions install/.colcon_install_layout
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
isolated
Empty file added log/COLCON_IGNORE
Empty file.
1 change: 1 addition & 0 deletions log/latest
1 change: 1 addition & 0 deletions log/latest_test
1 change: 1 addition & 0 deletions log/latest_test-result
4 changes: 4 additions & 0 deletions log/test-result_2024-08-20_23-21-03/logger_all.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[0.062s] DEBUG:colcon:Command line arguments: ['/usr/bin/colcon', 'test-result', '--all']
[0.063s] DEBUG:colcon:Parsed command line arguments: Namespace(log_base=None, log_level=None, verb_name='test-result', test_result_base='build', all=True, result_files_only=False, verbose=False, delete=False, delete_yes=False, mixin_files=None, mixin=None, verb_parser=<colcon_mixin.mixin.mixin_argument.MixinArgumentDecorator object at 0x750eb0da6750>, verb_extension=<colcon_test_result.verb.test_result.TestResultVerb object at 0x750eb0eb8290>, main=<bound method TestResultVerb.main of <colcon_test_result.verb.test_result.TestResultVerb object at 0x750eb0eb8290>>, mixin_verb=('test-result',))
[0.064s] Level 1:colcon.colcon_test_result.test_result:get_test_results(ctest)
[0.065s] Level 1:colcon.colcon_test_result.test_result:get_test_results(xunit)
6 changes: 6 additions & 0 deletions log/test_2024-08-20_23-21-03/events.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[0.000000] (-) TimerEvent: {}
[0.000491] (laser_filters) JobQueued: {'identifier': 'laser_filters', 'dependencies': OrderedDict({'laser_filters': '/ws/src/src/laser_filters/install/laser_filters'})}
[0.000550] (laser_filters) JobStarted: {'identifier': 'laser_filters'}
[0.015442] (laser_filters) StderrLine: {'line': b'Traceback (most recent call last):\n File "/usr/lib/python3/dist-packages/colcon_core/executor/__init__.py", line 91, in __call__\n rc = await self.task(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File "/usr/lib/python3/dist-packages/colcon_core/task/__init__.py", line 93, in __call__\n return await task_method(*args, **kwargs)\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n File "/usr/lib/python3/dist-packages/colcon_ros/task/ament_cmake/test.py", line 29, in test\n return await extension.test()\n ^^^^^^^^^^^^^^^^^^^^^^\n File "/usr/lib/python3/dist-packages/colcon_cmake/task/cmake/test.py", line 45, in test\n assert os.path.exists(args.build_base), \\\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\nAssertionError: Has this package been built before?\n'}
[0.015812] (laser_filters) JobEnded: {'identifier': 'laser_filters', 'rc': 1}
[0.025687] (-) EventReactorShutdown: {}
Empty file.
14 changes: 14 additions & 0 deletions log/test_2024-08-20_23-21-03/laser_filters/stderr.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/colcon_core/executor/__init__.py", line 91, in __call__
rc = await self.task(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_core/task/__init__.py", line 93, in __call__
return await task_method(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_ros/task/ament_cmake/test.py", line 29, in test
return await extension.test()
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_cmake/task/cmake/test.py", line 45, in test
assert os.path.exists(args.build_base), \
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: Has this package been built before?
Empty file.
14 changes: 14 additions & 0 deletions log/test_2024-08-20_23-21-03/laser_filters/stdout_stderr.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/colcon_core/executor/__init__.py", line 91, in __call__
rc = await self.task(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_core/task/__init__.py", line 93, in __call__
return await task_method(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_ros/task/ament_cmake/test.py", line 29, in test
return await extension.test()
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_cmake/task/cmake/test.py", line 45, in test
assert os.path.exists(args.build_base), \
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: Has this package been built before?
14 changes: 14 additions & 0 deletions log/test_2024-08-20_23-21-03/laser_filters/streams.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
[0.015s] Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/colcon_core/executor/__init__.py", line 91, in __call__
rc = await self.task(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_core/task/__init__.py", line 93, in __call__
return await task_method(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_ros/task/ament_cmake/test.py", line 29, in test
return await extension.test()
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/colcon_cmake/task/cmake/test.py", line 45, in test
assert os.path.exists(args.build_base), \
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: Has this package been built before?
46 changes: 46 additions & 0 deletions log/test_2024-08-20_23-21-03/logger_all.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
[0.128s] DEBUG:colcon:Command line arguments: ['/usr/bin/colcon', 'test', '--retest-until-fail=100', '--packages-select', 'laser_filters', '--event-handlers=console_cohesion+', '--ctest-args', '--output-on-failure']
[0.129s] DEBUG:colcon:Parsed command line arguments: Namespace(log_base=None, log_level=None, verb_name='test', build_base='build', install_base='install', merge_install=False, test_result_base=None, retest_until_fail=100, retest_until_pass=0, abort_on_error=False, return_code_on_test_failure=False, executor='parallel', parallel_workers=24, event_handlers=['console_cohesion+'], ignore_user_meta=False, metas=['./colcon.meta'], base_paths=['.'], packages_ignore=None, packages_ignore_regex=None, paths=None, packages_up_to=None, packages_up_to_regex=None, packages_above=None, packages_above_and_dependencies=None, packages_above_depth=None, packages_select_by_dep=None, packages_skip_by_dep=None, packages_skip_up_to=None, packages_select_build_failed=False, packages_skip_build_finished=False, packages_select_test_failures=False, packages_skip_test_passed=False, packages_select=['laser_filters'], packages_skip=None, packages_select_regex=None, packages_skip_regex=None, packages_start=None, packages_end=None, ctest_args=['--output-on-failure'], python_testing=None, pytest_args=None, pytest_with_coverage=False, unittest_args=None, mixin_files=None, mixin=None, verb_parser=<colcon_mixin.mixin.mixin_argument.MixinArgumentDecorator object at 0x708226bc2120>, verb_extension=<colcon_core.verb.test.TestVerb object at 0x708226bc15e0>, main=<bound method TestVerb.main of <colcon_core.verb.test.TestVerb object at 0x708226bc15e0>>, mixin_verb=('test',))
[0.156s] Level 1:colcon.colcon_core.package_discovery:discover_packages(colcon_meta) check parameters
[0.156s] Level 1:colcon.colcon_core.package_discovery:discover_packages(recursive) check parameters
[0.156s] Level 1:colcon.colcon_core.package_discovery:discover_packages(ignore) check parameters
[0.156s] Level 1:colcon.colcon_core.package_discovery:discover_packages(path) check parameters
[0.156s] Level 1:colcon.colcon_core.package_discovery:discover_packages(colcon_meta) discover
[0.156s] Level 1:colcon.colcon_core.package_discovery:discover_packages(recursive) discover
[0.156s] INFO:colcon.colcon_core.package_discovery:Crawling recursively for packages in '/ws/src/src/laser_filters'
[0.156s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extensions ['ignore', 'ignore_ament_install']
[0.156s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extension 'ignore'
[0.156s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extension 'ignore_ament_install'
[0.156s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extensions ['colcon_pkg']
[0.156s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extension 'colcon_pkg'
[0.157s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extensions ['colcon_meta']
[0.157s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extension 'colcon_meta'
[0.157s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extensions ['ros']
[0.157s] Level 1:colcon.colcon_core.package_identification:_identify(.) by extension 'ros'
[0.176s] DEBUG:colcon.colcon_core.package_identification:Package '.' with type 'ros.ament_cmake' and name 'laser_filters'
[0.176s] Level 1:colcon.colcon_core.package_discovery:discover_packages(recursive) using defaults
[0.176s] Level 1:colcon.colcon_core.package_discovery:discover_packages(ignore) discover
[0.176s] Level 1:colcon.colcon_core.package_discovery:discover_packages(ignore) using defaults
[0.176s] Level 1:colcon.colcon_core.package_discovery:discover_packages(path) discover
[0.176s] Level 1:colcon.colcon_core.package_discovery:discover_packages(path) using defaults
[0.178s] Level 5:colcon.colcon_core.verb:set package 'laser_filters' test argument 'ctest_args' from command line to '['--output-on-failure']'
[0.178s] Level 5:colcon.colcon_core.verb:set package 'laser_filters' test argument 'python_testing' from command line to 'None'
[0.178s] Level 5:colcon.colcon_core.verb:set package 'laser_filters' test argument 'pytest_args' from command line to 'None'
[0.178s] Level 5:colcon.colcon_core.verb:set package 'laser_filters' test argument 'pytest_with_coverage' from command line to 'False'
[0.178s] Level 5:colcon.colcon_core.verb:set package 'laser_filters' test argument 'unittest_args' from command line to 'None'
[0.178s] Level 5:colcon.colcon_core.verb:set package 'laser_filters' test argument 'retest_until_pass' from command line to '0'
[0.178s] Level 5:colcon.colcon_core.verb:set package 'laser_filters' test argument 'retest_until_fail' from command line to '100'
[0.178s] DEBUG:colcon.colcon_core.verb.test:Testing package 'laser_filters' with the following arguments: {'build_base': '/ws/src/src/laser_filters/build/laser_filters', 'ctest_args': ['--output-on-failure'], 'install_base': '/ws/src/src/laser_filters/install/laser_filters', 'path': '/ws/src/src/laser_filters', 'pytest_args': None, 'pytest_with_coverage': False, 'python_testing': None, 'retest_until_fail': 100, 'retest_until_pass': 0, 'test_result_base': None, 'unittest_args': None}
[0.178s] INFO:colcon.colcon_core.executor:Executing jobs using 'parallel' executor
[0.179s] DEBUG:colcon.colcon_parallel_executor.executor.parallel:run_until_complete
[0.179s] INFO:colcon.colcon_ros.task.ament_cmake.test:Testing ROS package in '/ws/src/src/laser_filters' with build type 'ament_cmake'
[0.179s] INFO:colcon.colcon_cmake.task.cmake.test:Testing CMake package in '/ws/src/src/laser_filters'
[0.204s] DEBUG:colcon.colcon_parallel_executor.executor.parallel:closing loop
[0.204s] DEBUG:colcon.colcon_parallel_executor.executor.parallel:loop closed
[0.204s] DEBUG:colcon.colcon_parallel_executor.executor.parallel:run_until_complete finished with 'Has this package been built before?'
[0.204s] DEBUG:colcon.colcon_core.event_reactor:joining thread
[0.210s] INFO:colcon.colcon_core.plugin_system:Skipping extension 'colcon_notification.desktop_notification.notify_send': Could not find 'notify-send'
[0.211s] INFO:colcon.colcon_core.plugin_system:Skipping extension 'colcon_notification.desktop_notification.terminal_notifier': Not used on non-Darwin systems
[0.211s] INFO:colcon.colcon_core.plugin_system:Skipping extension 'colcon_notification.desktop_notification.win32': Not used on non-Windows systems
[0.211s] INFO:colcon.colcon_notification.desktop_notification:Sending desktop notification using 'notify2'
[0.211s] DEBUG:colcon.colcon_notification.desktop_notification.notify2:Failed to initialize notify2: org.freedesktop.DBus.Error.InvalidFileContent: D-Bus library appears to be incorrectly set up: see the manual page for dbus-uuidgen to correct this issue. (Failed to open "/var/lib/dbus/machine-id": No such file or directory; UUID file '/etc/machine-id' should contain a hex string of length 32, not length 0, with no other text)
[0.211s] DEBUG:colcon.colcon_core.event_reactor:joined thread
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 comments on commit eb7708e

Please sign in to comment.