CARLA
Public Member Functions | Private Attributes | List of all members
carla::ros2::CarlaIMUPublisher Class Reference

#include <CarlaIMUPublisher.h>

+ Inheritance diagram for carla::ros2::CarlaIMUPublisher:
+ Collaboration diagram for carla::ros2::CarlaIMUPublisher:

Public Member Functions

 CarlaIMUPublisher (const char *ros_name="", const char *parent="")
 
 CarlaIMUPublisher (const CarlaIMUPublisher &)
 
 CarlaIMUPublisher (CarlaIMUPublisher &&)
 
bool Init ()
 
CarlaIMUPublisheroperator= (const CarlaIMUPublisher &)
 
CarlaIMUPublisheroperator= (CarlaIMUPublisher &&)
 
bool Publish ()
 
void SetData (int32_t seconds, uint32_t nanoseconds, float *accelerometer, float *gyroscope, float compass)
 
const char * type () const override
 
 ~CarlaIMUPublisher ()
 
- Public Member Functions inherited from carla::ros2::CarlaPublisher
 CarlaPublisher ()=default
 
const std::string & frame_id () const
 
void frame_id (std::string &&frame_id)
 
const std::string & name () const
 
void name (std::string &&name)
 
const std::string & parent () const
 
void parent (std::string &&parent)
 
virtual ~CarlaPublisher ()=default
 

Private Attributes

std::shared_ptr< CarlaIMUPublisherImpl_impl
 

Additional Inherited Members

- Protected Attributes inherited from carla::ros2::CarlaPublisher
std::string _frame_id = ""
 
std::string _name = ""
 
std::string _parent = ""
 

Detailed Description

Definition at line 17 of file CarlaIMUPublisher.h.

Constructor & Destructor Documentation

◆ CarlaIMUPublisher() [1/3]

carla::ros2::CarlaIMUPublisher::CarlaIMUPublisher ( const char *  ros_name = "",
const char *  parent = "" 
)

Definition at line 199 of file CarlaIMUPublisher.cpp.

References carla::ros2::CarlaPublisher::_name, carla::ros2::CarlaPublisher::_parent, and carla::ros2::CarlaPublisher::parent().

+ Here is the call graph for this function:

◆ ~CarlaIMUPublisher()

carla::ros2::CarlaIMUPublisher::~CarlaIMUPublisher ( )

Definition at line 205 of file CarlaIMUPublisher.cpp.

References _impl.

◆ CarlaIMUPublisher() [2/3]

carla::ros2::CarlaIMUPublisher::CarlaIMUPublisher ( const CarlaIMUPublisher other)

◆ CarlaIMUPublisher() [3/3]

carla::ros2::CarlaIMUPublisher::CarlaIMUPublisher ( CarlaIMUPublisher &&  other)

Member Function Documentation

◆ Init()

bool carla::ros2::CarlaIMUPublisher::Init ( )

Definition at line 42 of file CarlaIMUPublisher.cpp.

◆ operator=() [1/2]

CarlaIMUPublisher & carla::ros2::CarlaIMUPublisher::operator= ( const CarlaIMUPublisher other)

◆ operator=() [2/2]

CarlaIMUPublisher & carla::ros2::CarlaIMUPublisher::operator= ( CarlaIMUPublisher &&  other)

◆ Publish()

bool carla::ros2::CarlaIMUPublisher::Publish ( )

Definition at line 89 of file CarlaIMUPublisher.cpp.

◆ SetData()

void carla::ros2::CarlaIMUPublisher::SetData ( int32_t  seconds,
uint32_t  nanoseconds,
float *  accelerometer,
float *  gyroscope,
float  compass 
)

Definition at line 151 of file CarlaIMUPublisher.cpp.

References std_msgs::msg::Header::frame_id(), builtin_interfaces::msg::Time::nanosec(), builtin_interfaces::msg::Time::sec(), std_msgs::msg::Header::stamp(), geometry_msgs::msg::Quaternion::w(), geometry_msgs::msg::Quaternion::x(), geometry_msgs::msg::Vector3::x(), geometry_msgs::msg::Quaternion::y(), geometry_msgs::msg::Vector3::y(), geometry_msgs::msg::Quaternion::z(), and geometry_msgs::msg::Vector3::z().

Referenced by carla::ros2::ROS2::ProcessDataFromIMU().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ type()

const char* carla::ros2::CarlaIMUPublisher::type ( ) const
inlineoverridevirtual

Implements carla::ros2::CarlaPublisher.

Definition at line 29 of file CarlaIMUPublisher.h.

Member Data Documentation

◆ _impl

std::shared_ptr<CarlaIMUPublisherImpl> carla::ros2::CarlaIMUPublisher::_impl
private

Definition at line 32 of file CarlaIMUPublisher.h.

Referenced by CarlaIMUPublisher(), operator=(), and ~CarlaIMUPublisher().


The documentation for this class was generated from the following files: