|
YARP
Yet Another Robot Platform
|
|
Go to the documentation of this file.
14 #define M_PI (3.14159265358979323846)
23 ok &= m_poly->
view(m_iOrientationSensors);
24 ok &= m_poly->view(m_iPositionSensors);
25 m_iPositionSensors->getPositionSensorFrameName(m_sens_index, m_framename);
45 vecrpy[0] = vecrpy[0] *
M_PI / 180.0;
46 vecrpy[1] = vecrpy[1] *
M_PI / 180.0;
47 vecrpy[2] = vecrpy[2] *
M_PI / 180.0;
yarp::os::Publisher< yarp::rosmsg::geometry_msgs::PoseStamped > m_publisher
void fromRotationMatrix(const yarp::sig::Matrix &R)
Converts a rotation matrix to a quaternion.
yarp::rosmsg::geometry_msgs::Point position
#define YARP_LOG_COMPONENT(name,...)
contains the definition of a Matrix type
bool view(T *&x)
Get an interface to the device driver.
yarp::rosmsg::geometry_msgs::Quaternion orientation
yarp::sig::Matrix rpy2dcm(const yarp::sig::Vector &rpy)
Converts roll-pitch-yaw angles in the corresponding dcm (direction cosine matrix) rotation matrix (de...
virtual bool getPositionSensorMeasure(size_t sens_index, yarp::sig::Vector &xyz, double ×tamp) const =0
Get the last reading of the position sensor as x y z.
yarp::rosmsg::std_msgs::Header header
const size_t m_sens_index
void write(bool forceStrict=false)
Write the current object being returned by Publisher::prepare.
PoseStampedRosPublisher: This wrapper connects to a device and publishes a ROS topic of type geometry...
void run() override
Loop function.
Port & asPort() override
Get the concrete Port being used for communication.
const yarp::os::LogComponent & GENERICSENSORROSPUBLISHER()
virtual bool getOrientationSensorMeasureAsRollPitchYaw(size_t sens_index, yarp::sig::Vector &rpy, double ×tamp) const =0
Get the last reading of the orientation sensor as roll pitch yaw.
yarp::rosmsg::geometry_msgs::Pose pose
T & prepare()
Access the object which will be transmitted by the next call to yarp::os::Publisher::write.
bool isOpen() const
Check if the port has been opened.