File tree 1 file changed +3
-2
lines changed
common/tier4_autoware_utils/include/tier4_autoware_utils/ros
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -30,15 +30,16 @@ class InterProcessPollingSubscriber
30
30
std::optional<T> data_;
31
31
32
32
public:
33
- explicit InterProcessPollingSubscriber (rclcpp::Node * node, const std::string & topic_name)
33
+ explicit InterProcessPollingSubscriber (
34
+ rclcpp::Node * node, const std::string & topic_name, const rclcpp::QoS & qos = rclcpp::QoS{1 })
34
35
{
35
36
auto noexec_callback_group =
36
37
node->create_callback_group (rclcpp::CallbackGroupType::MutuallyExclusive, false );
37
38
auto noexec_subscription_options = rclcpp::SubscriptionOptions ();
38
39
noexec_subscription_options.callback_group = noexec_callback_group;
39
40
40
41
subscriber_ = node->create_subscription <T>(
41
- topic_name, rclcpp::QoS{ 1 } ,
42
+ topic_name, qos ,
42
43
[node]([[maybe_unused]] const typename T::ConstSharedPtr msg) { assert (false ); },
43
44
noexec_subscription_options);
44
45
};
You can’t perform that action at this time.
0 commit comments