NASA Astrobee Robot Software  0.19.1
Flight software for the Astrobee robots operating inside the International Space Station.
rapid_ekf_ros_ekf.h
Go to the documentation of this file.
1 /* Copyright (c) 2017, United States Government, as represented by the
2  * Administrator of the National Aeronautics and Space Administration.
3  *
4  * All rights reserved.
5  *
6  * The Astrobee platform is licensed under the Apache License, Version 2.0
7  * (the "License"); you may not use this file except in compliance with the
8  * License. You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
14  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
15  * License for the specific language governing permissions and limitations
16  * under the License.
17  */
18 
19 #ifndef DDS_ROS_BRIDGE_RAPID_EKF_ROS_EKF_H_
20 #define DDS_ROS_BRIDGE_RAPID_EKF_ROS_EKF_H_
21 
22 #include <stdint.h>
23 
24 #include <ros/assert.h>
25 
26 #include <string>
27 #include <cstring>
28 #include <vector>
29 
30 #include "dds_ros_bridge/rapid_sub_ros_pub.h"
31 #include "dds_ros_bridge/util.h"
32 
33 #include "ff_msgs/EkfState.h"
34 
35 #include "dds_msgs/AstrobeeConstants.h"
36 
37 #include "knDds/DdsTypedSupplier.h"
38 
39 #include "dds_msgs/EkfStateSupport.h"
40 
41 #include "rapidDds/RapidConstants.h"
42 
43 #include "rapidUtil/RapidHelper.h"
44 
45 namespace ff {
46 
47 class RapidEkfToRos : public RapidSubRosPub {
48  public:
49  RapidEkfToRos(const std::string& subscribe_topic,
50  const std::string& subscribe_partition,
51  const std::string& pub_topic,
52  const ros::NodeHandle &nh,
53  const unsigned int queue_size = 10);
54  void CopyTransform3D(const rapid::Transform3D& transform,
55  geometry_msgs::Pose& pose);
56  void CopyVec3D(const rapid::Vec3d& vec_in, geometry_msgs::Vector3& vec_out);
57 
61  void operator() (rapid::ext::astrobee::EkfState const* ekf_sample);
62 
63  private:
64  std::string subscriber_partition_;
65 };
66 
67 } // end namespace ff
68 
69 #endif // DDS_ROS_BRIDGE_RAPID_EKF_ROS_EKF_H_
ff::RapidEkfToRos::CopyTransform3D
void CopyTransform3D(const rapid::Transform3D &transform, geometry_msgs::Pose &pose)
Definition: rapid_ekf_ros_ekf.cc:58
ff::RapidEkfToRos::RapidEkfToRos
RapidEkfToRos(const std::string &subscribe_topic, const std::string &subscribe_partition, const std::string &pub_topic, const ros::NodeHandle &nh, const unsigned int queue_size=10)
Definition: rapid_ekf_ros_ekf.cc:23
ff::RapidEkfToRos::operator()
void operator()(rapid::ext::astrobee::EkfState const *ekf_sample)
Definition: rapid_ekf_ros_ekf.cc:77
ff
Definition: generic_rapid_msg_ros_pub.h:36
ff::RapidSubRosPub
base class for rapid subscriber to ros publisher
Definition: rapid_sub_ros_pub.h:42
ff::RapidEkfToRos::CopyVec3D
void CopyVec3D(const rapid::Vec3d &vec_in, geometry_msgs::Vector3 &vec_out)
Definition: rapid_ekf_ros_ekf.cc:70
ff::RapidEkfToRos
Definition: rapid_ekf_ros_ekf.h:47