Privacy
An open-source, flexible 3D physical simulation framework
mars::sim::NodeContactSensor Class Reference

#include <NodeContactSensor.h>

Public Member Functions

 NodeContactSensor (interfaces::ControlCenter *control, IDListConfig config)
 
 ~NodeContactSensor (void)
 
virtual int getAsciiData (char *data) const
 
virtual int getSensorData (interfaces::sReal **data) const
 
virtual void receiveData (const data_broker::DataInfo &info, const data_broker::DataPackage &package, int callbackParam)
 The DataBroker will call this method to notify the receiver of whenever the condition for which the receiver registered occur. More...
 
virtual configmaps::ConfigMap createConfig () const
 
- Public Member Functions inherited from mars::interfaces::SensorInterface
 SensorInterface (ControlCenter *center)
 
virtual ~SensorInterface ()
 
- Public Member Functions inherited from mars::interfaces::BaseNodeSensor
 BaseNodeSensor (unsigned long id, std::string name)
 
virtual ~BaseNodeSensor ()
 
utils::Quaternion getOrientation () const
 
unsigned long getAttachedNode ()
 
- Public Member Functions inherited from mars::interfaces::BaseSensor
 BaseSensor ()
 
virtual ~BaseSensor ()
 
 BaseSensor (unsigned long id, std::string name)
 
unsigned long getID () const
 
const std::string getName () const
 
void getCoreExchange (core_objects_exchange *obj) const
 
- Public Member Functions inherited from mars::data_broker::ReceiverInterface
 ReceiverInterface ()
 
virtual ~ReceiverInterface ()
 

Static Public Member Functions

static interfaces::BaseConfigparseConfig (interfaces::ControlCenter *control, configmaps::ConfigMap *config)
 
static interfaces::BaseSensorinstanciate (interfaces::ControlCenter *control, interfaces::BaseConfig *config)
 
- Static Public Member Functions inherited from mars::interfaces::BaseSensor
static BaseConfigparseConfig (ControlCenter *control, configmaps::ConfigMap *config)
 

Private Attributes

std::string typeName
 
IDListConfig config
 
std::vector< bool > values
 
long contactIndex
 
int countIDs
 
int groundContactIndex
 

Additional Inherited Members

- Public Attributes inherited from mars::interfaces::BaseSensor
unsigned long id
 
std::string name
 
unsigned long updateRate
 
- Protected Attributes inherited from mars::interfaces::SensorInterface
ControlCentercontrol
 
- Protected Attributes inherited from mars::interfaces::BaseNodeSensor
unsigned long attached_node
 
bool calcAcceletaion
 
bool calcSpeed
 
bool calcPosition
 
bool calcRotationSpeed
 
bool calcOrientation
 
utils::Vector acceleration
 
utils::Vector speed
 
utils::Vector position
 
utils::Vector rotationSpeed
 
utils::Quaternion orientation
 

Detailed Description

Definition at line 44 of file NodeContactSensor.h.

Constructor & Destructor Documentation

◆ NodeContactSensor()

mars::sim::NodeContactSensor::NodeContactSensor ( interfaces::ControlCenter control,
IDListConfig  config 
)

Definition at line 73 of file NodeContactSensor.cpp.

◆ ~NodeContactSensor()

mars::sim::NodeContactSensor::~NodeContactSensor ( void  )

Definition at line 96 of file NodeContactSensor.cpp.

Member Function Documentation

◆ createConfig()

ConfigMap mars::sim::NodeContactSensor::createConfig ( ) const
virtual

Reimplemented from mars::interfaces::BaseSensor.

Definition at line 57 of file NodeContactSensor.cpp.

◆ getAsciiData()

int mars::sim::NodeContactSensor::getAsciiData ( char *  data) const
virtual

Reimplemented from mars::interfaces::BaseSensor.

Definition at line 102 of file NodeContactSensor.cpp.

◆ getSensorData()

int mars::sim::NodeContactSensor::getSensorData ( interfaces::sReal **  data) const
virtual

Reimplemented from mars::interfaces::BaseSensor.

Definition at line 113 of file NodeContactSensor.cpp.

◆ instanciate()

BaseSensor * mars::sim::NodeContactSensor::instanciate ( interfaces::ControlCenter control,
interfaces::BaseConfig config 
)
static

Definition at line 42 of file NodeContactSensor.cpp.

◆ parseConfig()

BaseConfig * mars::sim::NodeContactSensor::parseConfig ( interfaces::ControlCenter control,
configmaps::ConfigMap config 
)
static

Definition at line 50 of file NodeContactSensor.cpp.

◆ receiveData()

void mars::sim::NodeContactSensor::receiveData ( const data_broker::DataInfo info,
const data_broker::DataPackage dataPackage,
int  callbackParam 
)
virtual

The DataBroker will call this method to notify the receiver of whenever the condition for which the receiver registered occur.

Parameters
infoInformation about the DataPackage.
dataPackageThe DataPackage containing all the data.
callbackParamThe int the receiver passed during registration. The default (the receiver didn't provide a callbackParam) is 0. This can be used to easily distinguish different registrations.

Implements mars::data_broker::ReceiverInterface.

Definition at line 126 of file NodeContactSensor.cpp.

Member Data Documentation

◆ config

IDListConfig mars::sim::NodeContactSensor::config
private

Definition at line 66 of file NodeContactSensor.h.

◆ contactIndex

long mars::sim::NodeContactSensor::contactIndex
private

Definition at line 68 of file NodeContactSensor.h.

◆ countIDs

int mars::sim::NodeContactSensor::countIDs
private

Definition at line 69 of file NodeContactSensor.h.

◆ groundContactIndex

int mars::sim::NodeContactSensor::groundContactIndex
private

Definition at line 70 of file NodeContactSensor.h.

◆ typeName

std::string mars::sim::NodeContactSensor::typeName
private

Definition at line 65 of file NodeContactSensor.h.

◆ values

std::vector<bool> mars::sim::NodeContactSensor::values
private

Definition at line 67 of file NodeContactSensor.h.


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