Transient Recorder Framework
Public Member Functions | Public Attributes | List of all members
TRBaseConfig Class Reference

Construction parameters for TRBaseDriver. More...

#include <TRBaseConfig.h>

Public Member Functions

 TRBaseConfig ()
 Constructor which sets default values. More...
 
template<typename ParamType >
TRBaseConfigset (ParamType TRBaseConfig::*param, ParamType const &value)
 Helper function for setting parameters using chaining. More...
 

Public Attributes

std::string port_name
 Name for the base asyn port. More...
 
int num_channels
 Number of channels supported. More...
 
int num_config_params
 Number of configuration parameters (TRConfigParam) defined by the derived class. More...
 
int num_asyn_params
 Number of asyn parameters defined by the derived class. More...
 
int interface_mask
 Mask of asyn interface types for asyn parameters of the derived class. More...
 
int interrupt_mask
 Mask of asyn interface types for asyn parameters of the derived class which might use asynchronous notification. More...
 
int read_thread_prio
 Priority for the read thread, in EPICS units. More...
 
int read_thread_stack_size
 Stack size for the read thread. More...
 
int max_ad_buffers
 Maximum number of allocated NDArrays of the channels port. More...
 
size_t max_ad_memory
 Maximum memory used by NDArrays of the channels port. More...
 
bool supports_pre_samples
 Whether the driver supports samples before the trigger event. More...
 
bool update_arrays
 Whether copies of submitted NDArrays are kept in the TRChannelsDriver. More...
 

Detailed Description

Construction parameters for TRBaseDriver.

This class is used as a parameter to the TRBaseDriver::TRBaseDriver constructor.

Constructor & Destructor Documentation

TRBaseConfig::TRBaseConfig ( )
inline

Constructor which sets default values.

This is designed with backward compatibility in mind, so that new parameters can be added to the framework which are initialized to default values.

Member Function Documentation

template<typename ParamType >
TRBaseConfig& TRBaseConfig::set ( ParamType TRBaseConfig::*  param,
ParamType const &  value 
)
inline

Helper function for setting parameters using chaining.

Example:

.set(&TRBaseConfig::port_name, std::string("foo"))
.set(&TRBaseConfig::num_config_params, NUM_DRIVER_CONFIG_PARAMS)
Parameters
paramPointer to member variable to set.
valueValue to set the variable to.
Returns
*this

Member Data Documentation

std::string TRBaseConfig::port_name

Name for the base asyn port.

The names of associated ports (channels, time array) will use this as a prefix. This parameter is mandatory.

int TRBaseConfig::num_channels

Number of channels supported.

This parameter is mandatory and must be positive.

int TRBaseConfig::num_config_params

Number of configuration parameters (TRConfigParam) defined by the derived class.

This MUST be greater than or equal to the number of TRConfigParam that will be initiaized by the derived class.

int TRBaseConfig::num_asyn_params

Number of asyn parameters defined by the derived class.

This MUST be greater than or equal to the number of asyn parameters that will be initiaized by the derived class (not including asyn parameters which the framework will initialize for TRConfigParam).

int TRBaseConfig::interface_mask

Mask of asyn interface types for asyn parameters of the derived class.

This is OR'd with the types needed by TRBaseDriver and forwarded to the asynPortDriver constructor.

int TRBaseConfig::interrupt_mask

Mask of asyn interface types for asyn parameters of the derived class which might use asynchronous notification.

This is OR'd with the types needed by TRBaseDriver and forwarded to the asynPortDriver constructor.

int TRBaseConfig::read_thread_prio

Priority for the read thread, in EPICS units.

The default is 0.

int TRBaseConfig::read_thread_stack_size

Stack size for the read thread.

If left at the default value 0, the stack size will be epicsThreadGetStackSize(epicsThreadStackMedium).

int TRBaseConfig::max_ad_buffers

Maximum number of allocated NDArrays of the channels port.

This is just forwarded to the epicsNDArrayDriver constructor.

size_t TRBaseConfig::max_ad_memory

Maximum memory used by NDArrays of the channels port.

This is just forwarded to the epicsNDArrayDriver constructor.

bool TRBaseConfig::supports_pre_samples

Whether the driver supports samples before the trigger event.

The default is false.

bool TRBaseConfig::update_arrays

Whether copies of submitted NDArrays are kept in the TRChannelsDriver.

This is used as the initial value of the UPDATE_ARRAYS parameters in TRChannelsDriver for all channels (port addresses). The default is true.


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