Public Member Functions | Protected Member Functions | Protected Attributes
Sensor Class Reference

Base class for sensors. More...

#include <Sensor.hh>

Inheritance diagram for Sensor:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 Sensor ()
 Constructor.
virtual ~Sensor ()
 Destructor.
virtual void Load (sdf::ElementPtr &_sdf)
 Load the sensor with SDF parameters.
virtual void Load ()
 Load the sensor with default parameters.
virtual void Init ()
 Initialize the sensor.
virtual void SetParent (const std::string &_name)
 Set the parent of the sensor.
std::string GetParentName () const
void Update (bool _force)
 Update the sensor.
void SetUpdateRate (double _hz)
 Set the update rate of the sensor.
virtual void Fini ()
 Finalize the sensor.
std::string GetName () const
 Get name.
virtual math::Pose GetPose () const
 Get the current pose.
virtual void SetActive (bool value)
 Set whether the sensor is active or not.
bool IsActive ()
std::string GetType () const
 Get sensor type.
common::Time GetLastUpdateTime ()
 return last update time
bool GetVisualize () const
std::string GetTopic () const
void FillMsg (msgs::Sensor &_msg)

Protected Member Functions

virtual void UpdateImpl (bool)

Protected Attributes

bool active
 True if active.
sdf::ElementPtr sdf
math::Pose pose
std::vector< event::ConnectionPtr > connections
transport::NodePtr node
transport::SubscriberPtr poseSub
std::string parentName
std::vector< SensorPluginPtr > plugins
gazebo::physics::WorldPtr world
common::Time updatePeriod
common::Time lastUpdateTime

Detailed Description

Base class for sensors.


Member Function Documentation

virtual void Load ( sdf::ElementPtr &  _sdf) [virtual]

Load the sensor with SDF parameters.

Parameters:
_sdfSDF Sensor parameteres

Reimplemented in RaySensor, ContactSensor, CameraSensor, and DepthCameraSensor.


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