Easy Navigation
Loading...
Searching...
No Matches
DummyLocalizer.hpp
Go to the documentation of this file.
1// Copyright 2025 Intelligent Robotics Lab
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
17
18#ifndef EASYNAV_LOCALIZER__DUMMYLOCALIZER_HPP_
19#define EASYNAV_LOCALIZER__DUMMYLOCALIZER_HPP_
20
21#include "nav_msgs/msg/odometry.hpp"
22#include "easynav_core/LocalizerMethodBase.hpp"
23#include "tf2_ros/transform_broadcaster.hpp"
24
25namespace easynav
26{
27
35class DummyLocalizer : public easynav::LocalizerMethodBase
36{
37public:
39 DummyLocalizer() = default;
40
42 ~DummyLocalizer() = default;
43
47 virtual void on_initialize() override;
48
56 virtual void update_rt(NavState & nav_state) override;
57
65 virtual void update(NavState & nav_state) override;
66
67private:
69 nav_msgs::msg::Odometry robot_pose_;
70
71 std::unique_ptr<tf2_ros::TransformBroadcaster> tf_broadcaster_;
72
73 double cycle_time_rt_ {0.0};
74 double cycle_time_nort_ {0.0};
75};
76
77} // namespace easynav
78
79#endif // EASYNAV_LOCALIZER__DUMMYLOCALIZER_HPP_
virtual void update(NavState &nav_state) override
Update the localization using the current navigation state.
Definition DummyLocalizer.cpp:59
DummyLocalizer()=default
Default constructor.
virtual void update_rt(NavState &nav_state) override
Update the localization using the current navigation state.
Definition DummyLocalizer.cpp:38
virtual void on_initialize() override
Plugin-specific initialization logic.
Definition DummyLocalizer.cpp:25
~DummyLocalizer()=default
Default destructor.
A generic, type-safe, thread-safe blackboard to hold runtime state.
Definition NavState.hpp:82
Definition CircularBuffer.hpp:23