Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F68739809
SupervisorL4.h
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Jun 28, 17:48
Size
1 KB
Mime Type
text/x-c++
Expires
Sun, Jun 30, 17:48 (2 d)
Engine
blob
Format
Raw Data
Handle
18626638
Attached To
R6624 liboncilla Webots Interface
SupervisorL4.h
View Options
/**
* \file SupervisorL4.h
*
* \date Jan 22, 2013
* \author tuleu
*/
#ifndef LIBONCILLA_WEBOTS_SUPERVISORL4_H_
#define LIBONCILLA_WEBOTS_SUPERVISORL4_H_
#include <liboncilla/nodes/SupervisorL4.h>
#include "NodeAdapter.h"
#include <liboncilla-webots/Common.h>
#include <libwebots/plugin/modules/contact/contact.pb.h>
#include <webots/Supervisor.hpp>
#include <liboncilla-webots/Config.h>
namespace liboncilla {
namespace webots {
class SupervisorL4 : public rci::oncilla::SupervisorL4,
public NodeAdapter {
public:
SupervisorL4(const std::string & name,
::webots::Supervisor & supervisor,
const liboncilla::webots::config::ContactSection & config,
const std::string & footNodeName);
virtual ~SupervisorL4();
void PreStep(double ts);
void PostStep(double ts);
private :
class ContactManager {
public :
typedef ::libwebots::plugin::modules::messages::contact::Monitor MonitorMessage;
ContactManager();
~ContactManager();
void Handler(MonitorMessage const & m);
void RegisterNewContact(const std::string & name,
const liboncilla::webots::config::ContactSection & config,
liboncilla::webots::SupervisorL4 * node);
void Unregister(liboncilla::webots::SupervisorL4 * node);
static const char * GROUND_NAME;
private :
typedef std::map<std::string,liboncilla::webots::SupervisorL4 * > NodeByName;
typedef std::map<liboncilla::webots::SupervisorL4 *, std::string > NameByNode;
NodeByName d_nodes;
NameByNode d_names;
};
friend class ContactManager;
static ContactManager * s_contactManager;
::webots::Node * d_node;
Eigen::Vector3d d_force;
};
} /* namespace webots */
} /* namespace liboncilla */
#endif /* LIBONCILLA_WEBOTS_SUPERVISORL4_H_ */
Event Timeline
Log In to Comment