From e4e682f959aef7dc71e79490824abc2f22b17d5a Mon Sep 17 00:00:00 2001 From: Junichiro Sugihara Date: Thu, 4 Jan 2024 13:03:27 +0900 Subject: [PATCH] [Ninja][Model][WIP] create another robot model instance to treat the networked structure --- robots/ninja/include/ninja/model/ninja_robot_model.h | 7 +++++++ robots/ninja/src/model/ninja_robot_model.cpp | 9 +++++++++ 2 files changed, 16 insertions(+) diff --git a/robots/ninja/include/ninja/model/ninja_robot_model.h b/robots/ninja/include/ninja/model/ninja_robot_model.h index 89b5ed282..30b9adfbf 100644 --- a/robots/ninja/include/ninja/model/ninja_robot_model.h +++ b/robots/ninja/include/ninja/model/ninja_robot_model.h @@ -17,5 +17,12 @@ class NinjaRobotModel : public BeetleRobotModel{ double epsilon = 10); virtual ~NinjaRobotModel() = default; + void calcCenterOfMoving() override; + +private: + boost::shared_ptr networked_robot_model_; + +protected: + virtual void updateRobotModelImpl(const KDL::JntArray& joint_positions) override; }; diff --git a/robots/ninja/src/model/ninja_robot_model.cpp b/robots/ninja/src/model/ninja_robot_model.cpp index c4060e32a..8ecc47eb5 100644 --- a/robots/ninja/src/model/ninja_robot_model.cpp +++ b/robots/ninja/src/model/ninja_robot_model.cpp @@ -3,6 +3,15 @@ NinjaRobotModel::NinjaRobotModel(bool init_with_rosparam, bool verbose, double fc_t_min_thre, double epsilon) : BeetleRobotModel(init_with_rosparam, verbose, fc_t_min_thre, epsilon) { + networked_robot_model_ = boost::make_shared(); +} + +void NinjaRobotModel::updateRobotModelImpl(){ + BeetleRobotModel::updateRobotModelImpl(); +} + +void NinjaRobotModel::calcCenterOfMoving(const KDL::JntArray& joint_positions){ + BeetleRobotModel::calcCenterOfMoving(joint_positions); } /* plugin registration */