TimedElasticBands.h
Go to the documentation of this file.
1/**
2 * This file is part of ArmarX.
3 *
4 * ArmarX is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 *
8 * ArmarX is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * @author Fabian Reister ( fabian dot reister at kit dot edu )
17 * @author Christian R. G. Dreher ( c dot dreher at kit dot edu )
18 * @date 2021
19 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
20 * GNU General Public License
21 */
22
23#pragma once
24
25#include <optional>
26#include <string>
27
33#include <armarx/navigation/local_planning/aron/TimedElasticBands.aron.generated.h>
34
35#include <teb_local_planner/homotopy_class_planner.h>
36#include <teb_local_planner/teb_config.h>
37
39{
40 class TimedElasticBands : virtual public LocalPlanner
41 {
42 public:
44
47 const core::Scene& scene);
48 ~TimedElasticBands() override = default;
49
50 void init(const core::GlobalTrajectory& initialTrajectory);
51
52 std::optional<LocalPlannerResult> plan(const core::GlobalTrajectory& goal) override;
53
54 private:
55 void readConfig(arondto::TimedElasticBandsParams& target, const std::string& robotName);
56 void fillObstacles();
57 void setTebCostmap();
58
59 protected:
61
62 private:
63 teb_local_planner::TebConfig cfg_;
64 teb_local_planner::ObstContainer teb_obstacles;
65 TebObstacleManager obstManager;
66 teb_local_planner::PoseSequence teb_globalPath;
67 std::optional<teb_local_planner::Costmap> teb_costmap;
68 std::unique_ptr<teb_local_planner::HomotopyClassPlanner> hcp_{nullptr};
69
70
71 std::optional<core::LocalTrajectory> lastTrajectory;
72 };
73} // namespace armarx::navigation::local_planning
LocalPlanner(const core::Scene &context, const core::GeneralConfig &generalConfig)
TimedElasticBands(const Params &params, const core::GeneralConfig &generalConfig, const core::Scene &scene)
void init(const core::GlobalTrajectory &initialTrajectory)
std::optional< LocalPlannerResult > plan(const core::GlobalTrajectory &goal) override
This file is part of ArmarX.
Definition fwd.h:36