All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Public Attributes | Private Member Functions | List of all members
SurgSim::Device::LabJackScaffold::DeviceData Struct Reference

The per-device data. More...

Collaboration diagram for SurgSim::Device::LabJackScaffold::DeviceData:
Collaboration graph
[legend]

Public Member Functions

 DeviceData (LabJackDevice *device, std::unique_ptr< Handle > &&handle)
 Initialize the data, creating a thread. More...
 
 ~DeviceData ()
 
 DeviceData (LabJackDevice *device, std::unique_ptr< Handle > &&handle)
 Initialize the data, creating a thread. More...
 
 ~DeviceData ()
 

Public Attributes

LabJackDevice *const deviceObject
 The corresponding device object. More...
 
std::unique_ptr< LabJackThreadthread
 Processing thread. More...
 
std::unique_ptr< HandledeviceHandle
 Device handle to read from. More...
 
const std::unordered_set< int > digitalInputChannels
 The channels read for digital inputs. More...
 
const std::unordered_set< int > digitalOutputChannels
 The channels set for digital outputs. More...
 
const std::unordered_set< int > timerInputChannels
 The timer channels that provide inputs. More...
 
const std::unordered_set< int > timerOutputChannels
 The timer channels set for timer outputs (e.g., PWM outputs). More...
 
const std::unordered_map< int,
LabJack::AnalogInputSettings
analogInputs
 The analog inputs. More...
 
const std::unordered_set< int > analogOutputChannels
 The channels set for analog outputs. More...
 
std::unordered_map< int, int > digitalOutputIndices
 The DataGroup indices for the digital outputs. More...
 
std::unordered_map< int, int > digitalInputIndices
 The DataGroup indices for the digital inputs. More...
 
std::unordered_map< int, int > timerOutputIndices
 The DataGroup indices for the timer outputs. More...
 
std::unordered_map< int, int > timerInputIndices
 The DataGroup indices for the timer inputs. More...
 
std::unordered_map< int, int > analogOutputIndices
 The DataGroup indices for the analog outputs. More...
 
std::unordered_map< int, int > analogInputIndices
 The DataGroup indices for the analog inputs. More...
 
bool cachedOutputIndices
 True if the output indices have been cached. More...
 
double calibration [40]
 

Private Member Functions

const std::unordered_set< int > getTimerInputChannels (const std::unordered_map< int, LabJack::TimerSettings > &timers) const
 Given all the timers, return just the ones that provide inputs. More...
 
const std::unordered_set< int > getTimerOutputChannels (const std::unordered_map< int, LabJack::TimerSettings > &timers) const
 Given all the timers, return just the ones that take outputs. More...
 
 DeviceData (const DeviceData &)
 
DeviceDataoperator= (const DeviceData &)
 
const std::unordered_set< int > getTimerInputChannels (const std::unordered_map< int, LabJack::TimerSettings > &timers) const
 Given all the timers, return just the ones that provide inputs. More...
 
const std::unordered_set< int > getTimerOutputChannels (const std::unordered_map< int, LabJack::TimerSettings > &timers) const
 Given all the timers, return just the ones that take outputs. More...
 
 DeviceData (const DeviceData &)
 
DeviceDataoperator= (const DeviceData &)
 

Detailed Description

The per-device data.

Constructor & Destructor Documentation

SurgSim::Device::LabJackScaffold::DeviceData::DeviceData ( LabJackDevice device,
std::unique_ptr< Handle > &&  handle 
)
inline

Initialize the data, creating a thread.

SurgSim::Device::LabJackScaffold::DeviceData::~DeviceData ( )
inline
SurgSim::Device::LabJackScaffold::DeviceData::DeviceData ( const DeviceData )
private
SurgSim::Device::LabJackScaffold::DeviceData::DeviceData ( LabJackDevice device,
std::unique_ptr< Handle > &&  handle 
)
inline

Initialize the data, creating a thread.

SurgSim::Device::LabJackScaffold::DeviceData::~DeviceData ( )
inline
SurgSim::Device::LabJackScaffold::DeviceData::DeviceData ( const DeviceData )
private

Member Function Documentation

const std::unordered_set<int> SurgSim::Device::LabJackScaffold::DeviceData::getTimerInputChannels ( const std::unordered_map< int, LabJack::TimerSettings > &  timers) const
inlineprivate

Given all the timers, return just the ones that provide inputs.

Parameters
timersThe timers.
Returns
The timers that provide inputs.
const std::unordered_set<int> SurgSim::Device::LabJackScaffold::DeviceData::getTimerInputChannels ( const std::unordered_map< int, LabJack::TimerSettings > &  timers) const
inlineprivate

Given all the timers, return just the ones that provide inputs.

Parameters
timersThe timers.
Returns
The timers that provide inputs.
const std::unordered_set<int> SurgSim::Device::LabJackScaffold::DeviceData::getTimerOutputChannels ( const std::unordered_map< int, LabJack::TimerSettings > &  timers) const
inlineprivate

Given all the timers, return just the ones that take outputs.

Parameters
timersThe timers.
Returns
The timers that take outputs.
const std::unordered_set<int> SurgSim::Device::LabJackScaffold::DeviceData::getTimerOutputChannels ( const std::unordered_map< int, LabJack::TimerSettings > &  timers) const
inlineprivate

Given all the timers, return just the ones that take outputs.

Parameters
timersThe timers.
Returns
The timers that take outputs.
DeviceData& SurgSim::Device::LabJackScaffold::DeviceData::operator= ( const DeviceData )
private
DeviceData& SurgSim::Device::LabJackScaffold::DeviceData::operator= ( const DeviceData )
private

Member Data Documentation

std::unordered_map< int, int > SurgSim::Device::LabJackScaffold::DeviceData::analogInputIndices

The DataGroup indices for the analog inputs.

const std::unordered_map< int, LabJack::AnalogInputSettings > SurgSim::Device::LabJackScaffold::DeviceData::analogInputs

The analog inputs.

const std::unordered_set< int > SurgSim::Device::LabJackScaffold::DeviceData::analogOutputChannels

The channels set for analog outputs.

std::unordered_map< int, int > SurgSim::Device::LabJackScaffold::DeviceData::analogOutputIndices

The DataGroup indices for the analog outputs.

bool SurgSim::Device::LabJackScaffold::DeviceData::cachedOutputIndices

True if the output indices have been cached.

double SurgSim::Device::LabJackScaffold::DeviceData::calibration[40]
std::unique_ptr< Handle > SurgSim::Device::LabJackScaffold::DeviceData::deviceHandle

Device handle to read from.

LabJackDevice *const SurgSim::Device::LabJackScaffold::DeviceData::deviceObject

The corresponding device object.

const std::unordered_set< int > SurgSim::Device::LabJackScaffold::DeviceData::digitalInputChannels

The channels read for digital inputs.

std::unordered_map< int, int > SurgSim::Device::LabJackScaffold::DeviceData::digitalInputIndices

The DataGroup indices for the digital inputs.

const std::unordered_set< int > SurgSim::Device::LabJackScaffold::DeviceData::digitalOutputChannels

The channels set for digital outputs.

std::unordered_map< int, int > SurgSim::Device::LabJackScaffold::DeviceData::digitalOutputIndices

The DataGroup indices for the digital outputs.

std::unique_ptr< LabJackThread > SurgSim::Device::LabJackScaffold::DeviceData::thread

Processing thread.

const std::unordered_set< int > SurgSim::Device::LabJackScaffold::DeviceData::timerInputChannels

The timer channels that provide inputs.

std::unordered_map< int, int > SurgSim::Device::LabJackScaffold::DeviceData::timerInputIndices

The DataGroup indices for the timer inputs.

const std::unordered_set< int > SurgSim::Device::LabJackScaffold::DeviceData::timerOutputChannels

The timer channels set for timer outputs (e.g., PWM outputs).

std::unordered_map< int, int > SurgSim::Device::LabJackScaffold::DeviceData::timerOutputIndices

The DataGroup indices for the timer outputs.


The documentation for this struct was generated from the following file: