kinematics-dynamics
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
roboticslab::XTrainerDevice Class Reference

Represents an XTrainer-compatible device.

#include <XTrainerDevice.hpp>

Inheritance diagram for roboticslab::XTrainerDevice:
roboticslab::StreamingDevice

Public Member Functions

 XTrainerDevice (yarp::os::Searchable &config)
 
bool acquireInterfaces () override
 Acquires plugin interfaces.
 
bool initialize (const ICartesianControl::config_map_t &params) override
 Perform any custom initialization needed. This method is called after the successful creation of the device and once all interface handles are acquired.
 
bool acquireData () override
 Acquires data from remote device.
 
bool transformData (double scaling) override
 Performs required operations on stored data.
 
ICartesianControl::Actuator getActuatorState () override
 If actuator command data is available, return its current state.
 
void sendMovementCommand (double timestamp) override
 Sends movement command to the cartesian controller.
 
- Public Member Functions inherited from roboticslab::StreamingDevice
 StreamingDevice (yarp::os::Searchable &config)
 Constructor.
 
virtual ~StreamingDevice ()
 Destructor.
 
virtual bool hasValidMovementData () const
 Checks whether the device may forward acquired and processed data to the controller.
 
virtual void stopMotion ()
 Sends a movement command that would stop motion.
 
void setCartesianControllerHandle (ICartesianControl *iCartesianControl)
 Stores handle to an ICartesianControl instance.
 

Private Attributes

yarp::dev::IJoypadController * iJoypadController {nullptr}
 
ICartesianSolver * iCartesianSolver {nullptr}
 
yarp::dev::PolyDriver solverDevice
 
std::string kinematics
 
std::vector< double > initialTcpOffset
 
std::vector< double > initialDeviceOffset
 
KDL::Frame H_base_device
 
KDL::Frame H_ee_device
 
KDL::Frame H_device_ee
 
bool buttonClose {false}
 
bool buttonOpen {false}
 

Additional Inherited Members

- Protected Attributes inherited from roboticslab::StreamingDevice
ICartesianControl * iCartesianControl {nullptr}
 
std::vector< double > data
 
std::vector< bool > fixedAxes
 
ICartesianControl::Actuator actuatorState
 

Member Function Documentation

◆ acquireData()

bool XTrainerDevice::acquireData ( )
overridevirtual
Returns
true on success, false otherwise

Implements roboticslab::StreamingDevice.

◆ acquireInterfaces()

bool XTrainerDevice::acquireInterfaces ( )
overridevirtual
Returns
true on success, false otherwise

Implements roboticslab::StreamingDevice.

◆ getActuatorState()

ICartesianControl::Actuator XTrainerDevice::getActuatorState ( )
overridevirtual
Returns
integer value describing current actuator state

Reimplemented from roboticslab::StreamingDevice.

◆ initialize()

bool XTrainerDevice::initialize ( const ICartesianControl::config_map_t &  params)
overridevirtual
Parameters
paramsConfiguration parameters for the cartesian controller.
Returns
true on success, false otherwise

Reimplemented from roboticslab::StreamingDevice.

◆ sendMovementCommand()

void XTrainerDevice::sendMovementCommand ( double  timestamp)
overridevirtual
Parameters
timestampCurrent timestamp.

Implements roboticslab::StreamingDevice.

◆ transformData()

bool XTrainerDevice::transformData ( double  scaling)
overridevirtual
Parameters
scalingScaling factor applied to each data value.
Returns
true on success, false otherwise

Reimplemented from roboticslab::StreamingDevice.


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