|
| LabJackToPoseFilter (const std::string &name, int firstTimerForQuadrature, int plusX, int minusX, double translationPerUpdate, int positiveAnalogDifferential, int analogSingleEnded, int xOut, int loopbackOut) |
|
virtual | ~LabJackToPoseFilter () |
|
bool | initialize () |
| Fully initialize the device. More...
|
|
bool | finalize () |
| Finalize (de-initialize) the device. More...
|
|
void | initializeInput (const std::string &device, const DataGroup &inputData) |
| Set the initial input data group. More...
|
|
void | handleInput (const std::string &device, const DataGroup &inputData) |
| Notifies the consumer that the application input coming from the device has been updated. More...
|
|
bool | requestOutput (const std::string &device, DataGroup *outputData) |
| Asks the producer to provide output state to the device. More...
|
|
void | inputFilter (const DataGroup &dataToFilter, DataGroup *result) |
|
void | outputFilter (const DataGroup &dataToFilter, DataGroup *result) |
|
| CommonDevice (const std::string &name) |
| Constructor. More...
|
|
| CommonDevice (const std::string &name, const SurgSim::DataStructures::DataGroup &inputData) |
| Constructor. More...
|
|
| CommonDevice (const std::string &name, SurgSim::DataStructures::DataGroup &&inputData) |
| Constructor. More...
|
|
virtual | ~CommonDevice () |
| Destructor. More...
|
|
virtual std::string | getName () const override |
| Return a (hopefully unique) device name. More...
|
|
void | setNameForCallback (const std::string &name) |
| Set the name used for calling the input consumers and output producer. More...
|
|
std::string | getNameForCallback () const |
| Get the name used for calling the input consumers and output producer. More...
|
|
virtual bool | addInputConsumer (std::shared_ptr< InputConsumerInterface > inputConsumer) override |
| Connect this device to an InputConsumerInterface, which will receive the data that comes from this device. More...
|
|
virtual bool | removeInputConsumer (std::shared_ptr< InputConsumerInterface > inputConsumer) override |
| Disconnect this device from an InputConsumerInterface, which will no longer receive data from this device. More...
|
|
virtual bool | setOutputProducer (std::shared_ptr< OutputProducerInterface > outputProducer) override |
| Connect this device to an OutputProducerInterface, which will send data to this device. More...
|
|
virtual bool | removeOutputProducer (std::shared_ptr< OutputProducerInterface > outputProducer) override |
| Disconnect this device from an OutputProducerInterface, which will no longer send data to this device. More...
|
|
virtual bool | hasOutputProducer () override |
| Getter for whether or not this device is connected with an OutputProducerInterface. More...
|
|
virtual | ~DeviceInterface () |
| Virtual destructor (empty). More...
|
|
virtual | ~InputConsumerInterface () |
| Virtual destructor (empty). More...
|
|
virtual | ~OutputProducerInterface () |
| Virtual destructor (empty). More...
|
|
bool LabJackToPoseFilter::requestOutput |
( |
const std::string & |
device, |
|
|
DataGroup * |
outputData |
|
) |
| |
|
inlinevirtual |
Asks the producer to provide output state to the device.
Note that devices may never call this method, e.g. because the device doesn't actually have any output capability.
Typical output data contents (but note that individual devices may do things differently):
type | name | |
vector | "force" | Commanded force for the device (units are newtons). |
vector | "torque" | Commanded torque for the device (units are newton-meters). |
bool | "isEnabled" | Safety switch input. |
Other possible contents includes:
type | name | |
bool | "led0" | Desired state for LED 0. |
bool | "led1" | Desired state for LED 1. |
string | "toolId" | Calibration ID to use, e.g. for camera devices. |
- Parameters
-
| device | The name of the device that is requesting the output. This should only be used to identify the device (e.g. if the producer is listening to several devices at once). |
[out] | outputData | The application output state being fed into the device. |
- Returns
- true if the producer has provided some output, false if it refuses to do so. A producer that returns false should leave outputData unmodified.
Implements SurgSim::Input::OutputProducerInterface.