Quad-SDK
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | Private Attributes | List of all members
gazebo::ContactPlugin Class Reference

An example plugin for a contact sensor. More...

#include <contact_plugin.h>

Inheritance diagram for gazebo::ContactPlugin:
Inheritance graph
[legend]
Collaboration diagram for gazebo::ContactPlugin:
Collaboration graph
[legend]

Public Member Functions

 ContactPlugin ()
 Constructor.
 
virtual ~ContactPlugin ()
 Destructor.
 
virtual void Load (sensors::SensorPtr _sensor, sdf::ElementPtr _sdf)
 Load the sensor plugin.
 

Private Member Functions

virtual void OnUpdate ()
 Callback that receives the contact sensor's update signal.
 

Private Attributes

std::unique_ptr< ros::NodeHandle > rosNode
 
ros::Publisher contact_publisher
 
sensors::ContactSensorPtr parentSensor
 Pointer to the contact sensor.
 
event::ConnectionPtr updateConnection
 Connection that maintains a link between the contact sensor's updated signal and the OnUpdate callback.
 

Detailed Description

An example plugin for a contact sensor.

Member Function Documentation

◆ Load()

void ContactPlugin::Load ( sensors::SensorPtr  _sensor,
sdf::ElementPtr  _sdf 
)
virtual

Load the sensor plugin.

Parameters
[in]_sensorPointer to the sensor that loaded this plugin.
[in]_sdfSDF element that describes the plugin.

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