Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F71140323
L1L2.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
Tue, Jul 9, 21:44
Size
1 KB
Mime Type
text/x-c++
Expires
Thu, Jul 11, 21:44 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
18910588
Attached To
R6622 liboncilla
L1L2.h
View Options
#pragma once
#include <boost/shared_ptr.hpp>
#include <rci/dto/JointAngles.h>
#include <rci/ResourceNode.h>
#include <rci/Controlled.h>
#include <rci/Sensing.h>
namespace rci{
namespace oncilla{
class Synchronizer;
class L1L2;
/**
* Node class, representing the hip node of the quadruped robot.
*
* @todo In case of simulation, this node can also sense the power consumption.
*/
class L1L2: public rci::ResourceNode,
public rci::Controlled,
public rci::Sensing,
public rci::PositionControlled,
public rci::PositionSensing, // Two encoder values
public rci::VelocityControlled,
public rci::TorqueControlled,
public rci::ImpedanceControlled {
public:
typedef boost::shared_ptr<L1L2> Ptr;
const static unsigned int MotorAxisIndex = 0;
const static unsigned int MagneticEncoderIndex = 1;
/**
* Special constructor to also link to webots
*/
L1L2(rci::oncilla::Synchronizer & s,
const std::string & name = "Oncilla Hip");
virtual ~L1L2();
virtual void setControlMode(ControlModePtr controlMode);
bool setJointImpedance(JointImpedancePtr );
bool isConverged() const;
/**
* Print
*/
std::string print() const;
protected :
void unsafeSetCommand(double value);
double unsafeGetCommand() const;
double unsafeGetMotorAxisPosition() const;
double unsafeGetMagneticEncoderPosition() const;
void unsafeUpdateMotorAxisPosition(double value);
void unsafeUpdateMagneticEncoderPosition(double value);
private:
/**
* Reference to OncillaSynchronizer
* @todo This is a dangerous reference which will become invalid as soon as
* OncillaSynchronizer gets deleted outside.
*/
rci::oncilla::Synchronizer & d_synchronizer;
};
typedef L1L2 L1;
typedef L1L2 L2;
}
}
Event Timeline
Log In to Comment